# Minecraft MCP

> Minecraft MCP is an open-source MCP server for games and play. MCP server giving AI clients a simulated Minecraft world to read, edit and fill. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** API, CLI, Self-hosted
- **Website:** https://projects.lzimul.com/minecraft-mcp
- **Repository:** https://github.com/lzimul/minecraft-mcp
- **MCP Registry name:** io.github.lZiMUl/minecraft-mcp
- **Categories:** [games and play](https://ai-powered.com/categories/games-and-play)
- **Listing updated:** 2026-11-28

## About

Minecraft MCP runs a simulated Minecraft world that AI clients can inspect and change through the Model Context Protocol. Tools cover placing and querying blocks across the Overworld, Nether and End, filling bounded boxes, and creating, moving and deleting entities and players. Each entity and player carries a 9-slot hotbar and a 27-slot backpack that can be read and edited.

World state is held per dimension and saved as JSON files, so changes survive restarts. A WebSocket fan-out service can broadcast every tool call and full world snapshots to connected viewers, and it is disabled by default. The registry of Minecraft blocks, items and entity types is exposed as MCP resources with their properties.

It suits developers building Minecraft-style tooling, agent experiments that need a sandboxed block world, or anyone who wants to script structures and test inventory logic without running a real game. Requires Node.js 22 or newer.

## Features

- **Block placement and queries:** Place, read and page through blocks in each simulated dimension, including block states.
- **Bounded area fills:** Fill or clear a box of blocks in one request, with overwrite control and change counts.
- **Entity and player control:** Create, move, reposition and delete entities and named players in a dimension.
- **Inventory management:** Read, set, swap and clear the hotbar and backpack slots of any entity or player.
- **Persistent worlds:** Each dimension is stored as its own JSON snapshot and reloads after a restart.
- **Registry resources:** Browse Minecraft block, item and entity type properties as MCP resources.
- **Optional live broadcast:** A WebSocket service can stream tool calls and world snapshots to connected clients.

## Good for

- Scripting block structures in a simulated Minecraft world from an AI assistant
- Testing inventory or entity logic without running a Minecraft client
- Prototyping agent behaviour in a sandboxed block world with persistent state
- Looking up Minecraft block, item and entity properties from an MCP client

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add minecraft-mcp -- npx -y @lzimul/minecraft-mcp
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add minecraft-mcp -- npx -y @lzimul/minecraft-mcp
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.minecraft-mcp]
command = "npx"
args = ["-y", "@lzimul/minecraft-mcp"]
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user minecraft-mcp npx -- -y @lzimul/minecraft-mcp

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "minecraft-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@lzimul/minecraft-mcp"
      ]
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 1 of 21 tools deletes data and 6 change data; 3 names don't say. From the server's own tool labels and tool names; not verified by us.

- `getBlock` (name suggests: reads): Get the block (and its states) at coordinates in a dimension (defaults to overworld)
- `setBlock` (name suggests: changes): Place a block with optional states in a dimension and return the replaced block
- `getDimension` (name suggests: reads): Get dimension metadata, block count, entity count and player count
- `getDimensionBlocks` (name suggests: reads): Page through every placed (non-air) block in a dimension, sorted by coordinates
- `getBlocksInArea` (name suggests: reads): Page through placed blocks inside a box, with an optional block and states filter
- `fillBlocks`: Fill a box with one block, optionally replacing existing blocks; air clears the box
- `getDimensionEntities` (name suggests: reads): List every entity and player in a dimension with type, name and position
- `getDimensionRawFile` (name suggests: reads): Return the raw dimension JSON snapshot, including blocks and entities
- `getItem` (name suggests: reads): Look up item properties by id (minecraft:diamond_sword or diamond_sword)
- `createEntity` (name suggests: changes): Create a non-player entity with an empty hotbar and backpack
- `getEntity` (name suggests: reads): Get an entity by UUID, including position, dimension and full inventory
- `deleteEntity` (name suggests: deletes): Delete an entity or player by UUID or player name and discard its inventory
- `moveEntity` (name suggests: changes): Move an entity one block forward, back, left, right, up or down
- `getEntityPosition` (name suggests: reads): Get an entity UUID, type, name and exact x/y/z position
- `setEntityPosition` (name suggests: changes): Set an entity UUID to an exact x/y/z position
- `createPlayer` (name suggests: changes): Create a uniquely named player with an empty hotbar and backpack
- `getPlayer` (name suggests: reads): Get a player by name (case-insensitive), including position, dimension and full inventory
- `getInventory` (name suggests: reads): Read the 9 hotbar slots and 27 backpack slots of an entity or player
- `clearInventory`: Remove every item from an entity or player inventory
- `swapInventorySlots`: Swap any two hotbar or backpack slots of an entity or player
- `setInventory` (name suggests: changes): Set or clear one hotbar/backpack slot of an entity or player

## FAQ

### What Node.js version is required?

Node.js 22 or newer.

### Does world state survive a restart?

Yes. World state is saved per dimension as JSON and reloaded at startup.

### How many blocks can a dimension hold?

Up to 250,000 placed blocks and 10,000 entities and players combined per dimension.

### Is the WebSocket broadcast enabled by default?

No. It is disabled by default and should be enabled only with access controls.

### Is Minecraft MCP free?

Yes. Minecraft MCP is open source, so you can use and self-host it for free.

### How do I add Minecraft MCP to Claude Code?

Run this command in your terminal: claude mcp add minecraft-mcp -- npx -y @lzimul/minecraft-mcp

### What are the best alternatives to Minecraft MCP?

The closest alternatives to Minecraft MCP are MCP Fabric (Minecraft), Minecraft, Nodepal MCP, Awesome Mineflayer MCP and Bind Alias MCP.

## Where this comes from

- Description: written from the project's README, the project's website and its MCP Registry entry.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [MCP Fabric (Minecraft)](https://ai-powered.com/mcp/mcp-fabric-minecraft): MCP Fabric (Minecraft) is a free MCP server for games and play.
- [Minecraft](https://ai-powered.com/mcp/minecraft): Minecraft is a free MCP server for games and play.
- [Nodepal MCP](https://ai-powered.com/mcp/nodepal-mcp): Nodepal MCP is an MCP server for games and play.
- [Awesome Mineflayer MCP](https://ai-powered.com/mcp/awesome-mineflayer-mcp): Awesome Mineflayer MCP is an open-source MCP server for games and play.
- [Bind Alias MCP](https://ai-powered.com/mcp/bind-alias-mcp): Bind Alias MCP is an open-source MCP server for games and play.
- [truetick-gg](https://ai-powered.com/mcp/truetick-gg): truetick-gg is an MCP server for games and play.
- [Tacyon MC](https://ai-powered.com/mcp/tacyon-mc): Tacyon MC is an MCP server for games and play.
- [genMC – AI Minecraft studio](https://ai-powered.com/mcp/genmc-ai-minecraft-studio): genMC – AI Minecraft studio is a free MCP server for games and play.

---
Source: https://ai-powered.com/mcp/minecraft-mcp-2
