Unity MCP: Game Dev With an AI Agent
Unity has deprecated the MCP server in its AI Assistant package and points you to the Unity CLI, which has its own MCP mode and direct Editor commands. What each option is, how to set up Claude Code or Cursor today, where community servers fit, and how to keep an agent’s changes to your project reviewable.
7 min read
Unity MCP connects an AI agent such as Claude Code, Cursor or Windsurf to the Unity Editor, so the agent can read the console, manage scenes and GameObjects, edit scripts and run tests in your project. As of September 30, 2026, Unity’s own route has changed. The MCP server that shipped inside the AI Assistant package (com.unity.ai.assistant) is deprecated, and Unity tells you to use the Unity CLI instead: it has its own MCP mode, plus direct Editor commands that Unity says are faster and use fewer tokens. The CLI itself is labeled experimental. Community servers such as MCP for Unity are not affected by the deprecation and still work, but they are not made by Unity.
Unity’s MCP options today
- Unity CLI in MCP mode.
unity mcpstarts an MCP server for AI agents, built on the Unity Pipeline package, andunity mcp configurewrites the config for your client. Unity says this mode is not part of the deprecation and remains fully supported. - Unity CLI direct commands.
unity commandandunity evaldrive a running Editor without MCP in between. Unity recommends them when your agent can run shell commands reliably. - The in-Editor MCP server (deprecated). The bridge inside the AI Assistant package, reached through a relay binary. Existing setups still start, but Unity’s docs for it now open with a deprecation notice.
- Community servers. Packages installed from GitHub, such as MCP for Unity by Coplay. Unity’s deprecation page lists them as unaffected.
Unity’s page on replacing the MCP server with the Unity CLI (opens in a new tab) is the one to read first. It also says the CLI is free and separate from Unity AI, so installing it needs no Unity AI subscription, and that the local pipeline server accepts connections on localhost only.
Set up the Unity CLI route
You need Unity 6.0 or later to drive a running Editor. The CLI runs on Windows 10 21H1 or newer, macOS 14 or newer, and recent Linux releases, according to Unity’s guide to using the CLI (opens in a new tab). The Unity Hub now installs it automatically; otherwise use the install script, Homebrew (brew install --cask unity-cli) or winget (winget install Unity.CLI).
- Install the CLI and run
unity --versionto check it is on your PATH. Close and reopen the terminal afterward. - Open your project in the Unity Editor.
- Run
unity auth login, thenunity pipeline installfrom the project folder to add the Unity Pipeline package. Let the Editor recompile, then rununity pipeline listand look for Pipeline: Installed. - Run
unity mcp configurewith your client’s name, for exampleclaude,cursor,vscodeorwindsurf. This rewrites that client’s config to use the CLI’s MCP server.unity mcp configure --listshows every supported client and whether it is set up. - Run
unity skill installwith your agent’s name to add the Unity CLI agent skill, which teaches the agent how to use the commands.
curl -fsSL https://unity.com/install.sh | bash unity --version cd ~/Projects/MyGame unity auth login unity pipeline install unity pipeline list unity mcp configure claude unity mcp configure --list unity skill install claude
The Unity Pipeline package page (opens in a new tab) covers the Editor side: the package exposes the Editor through a local HTTP API, unity command discovers the project from the current folder, and unity command --project-path=<path> picks one when several Editors are open.
MCP mode or direct commands
Unity’s advice is specific. If your agent can run shell commands, as Claude Code, Codex and Cursor’s agent can, the unity command and unity eval commands are faster and cheaper in tokens than MCP. MCP mode is there for agents and harnesses that cannot run arbitrary shell commands, and for models that do not compose command lines reliably. That matches the general trade-off in MCP vs CLI: a CLI costs nothing until it is called, while an MCP server’s tool definitions take up room in the agent’s context. The skill you installed in step 5 is what makes the direct commands usable, much like any other agent skill.
If you already use the in-Editor server
The deprecated server works like this, per Unity’s getting started page for it (opens in a new tab): it needs Unity 6 (6000.0) or later with the AI Assistant package; the bridge starts with the Editor and shows Running under Edit, then Project Settings, then AI, then Unity MCP Server; and Unity installs a relay binary to ~/.unity/relay/ that your client launches with the --mcp flag. The first time a client connects, you approve it under Pending Connections. Tools appear with names such as Unity.ManageScene and Unity.ManageGameObject.
{
"mcpServers": {
"unity-mcp": {
"command": "<HOME_ABSOLUTE_PATH>/.unity/relay/relay_mac_arm64.app/Contents/MacOS/relay_mac_arm64",
"args": ["--mcp"]
}
}
}To move off it, follow the CLI steps above; unity mcp configure replaces this entry for you. Unity also says versions 2.13 and later of the AI Assistant package fix a conflict with the CLI, so update the package if your project is on an older one. The in-Editor AI Assistant itself is not what is deprecated; only its MCP server component is.
Community servers
The best-known community option is MCP for Unity (opens in a new tab), maintained by Coplay and MIT-licensed. Its README lists Unity 2021.3 LTS through 6.x, which matters if you are not on Unity 6 yet, and Python 3.10 or newer through uv. You add it in the Package Manager from its git URL, then use Window, MCP for Unity, Configure All Detected Clients. It says it is not affiliated with Unity Technologies.
A community package runs inside your Editor with your permissions, so treat it like any dependency: read what the tools do, pin a release tag rather than tracking the main branch, and update on purpose. The checklist in MCP security best practices applies here unchanged.
A game dev loop with an agent
- Start with reads. “Read the Unity console and summarize any warnings or errors” is Unity’s own first test prompt, and it tells you quickly whether the connection works.
- Then small edits. “Create a cube at the origin and add a Rigidbody.” Check the result in the Scene view before asking for the next change.
- Scripts with a check. Ask for a C# change, then ask the agent to wait for compilation and read the console again, so a compile error does not sit unnoticed.
- Tests and builds. The CLI can run test suites and headless builds, which lets the agent prove a change instead of describing it.
- Assets from elsewhere. Models made in Blender come in as FBX or GLB; the Blender MCP guide covers the modeling side.
Keep the project in version control and commit before each agent session, so you can review what changed in scenes, prefabs and scripts and roll back a bad run. An agent that edits a scene can touch many files at once, and a diff is the only reliable record of what it did.
Tracking playtest bugs on a board
Console errors and playtest notes turn into work, and that work needs somewhere to live between sessions. With fenbs connected as a second MCP server at https://fenbs.ai/api/mcp, you can say: “Read the console, and for each distinct error file a bug in fenbs with the script and line in the note. Search the board first and comment on an existing bug instead of filing a duplicate.” The bugs land in To Do with a priority from 1 to 10, where 1 is the most urgent. When the agent picks one up, it moves it to In Progress, writes its plan into the task, and sets the test status when it is done, and the history shows which assistant made each change.
fenbs is a plain task board, not a game production tool. It has no sprints, no due dates and no settable assignee, so a milestone or a tester’s name goes into the note. Project-wide rules, such as “never edit files under Assets/ThirdParty”, belong on the Decisions and rules page, which every connected assistant reads before it starts. How that rhythm works in practice is in the Claude Code task tracking workflow.
Related
The modeling side of the pipeline: Blender MCP. Setting the board up beside Unity: Claude Code, Cursor and the MCP docs. Before an agent touches a shared project: how to keep an AI agent from wrecking your board.