unity
Union ♾️ - The Unity MCP Server
claude mcp add --transport stdio nurture-tech-unity-mcp-server npx -y @nurture-tech/unity-mcp-runner -unityPath <path to unity editor> -projectPath <path to unity project>
How to use
This MCP server runs as a Unity-focused model context provider. It exposes tools and capabilities to interact with Unity projects through the MCP protocol, including multimodal vision to inspect scenes and assets, a powerful search across assets and hierarchy, and code analysis by leveraging Unity's own compiler. Use the unity server entry in your mcp.json to start the runner; the server will automatically install the required Unity MCP package into your project. Once running, you can issue MCP requests to perform tasks such as listing assets, opening scenes, taking screenshots of the scene focus, running editor commands, and invoking your project-specific tools that you expose via the MCP SDK. The included tool catalog covers assets, prefabs, scenes, scripting, search, editor state, and vision operations, enabling an agent to query and manipulate Unity content programmatically. Practical workflows include indexing a project, querying for assets by type, opening a scene in isolation, and running code generation or edits within the Unity editor via the provided tool set.
How to install
Prerequisites:
- Node.js installed on your machine (npx is included with Node.js).
- A Unity project you want to connect to and a Unity Editor installed.
Step-by-step:
- Create a working directory for your MCP configuration.
- Create a file named mcp.json with the Unity server configuration:
{
"mcpServers": {
"unity": {
"command": "npx",
"args": ["-y", "@nurture-tech/unity-mcp-runner", "-unityPath", "<path to unity editor>", "-projectPath", "<path to unity project>"]
}
}
}
- Ensure Node.js is installed and accessible from your environment.
- Start the MCP server by executing the mcp.json-based startup (the runner will install the Unity MCP package into your project automatically). For example:
# From the directory containing mcp.json
npx -y @nurture-tech/unity-mcp-runner -unityPath "<path to unity editor>" -projectPath "<path to unity project>"
- Verify the server is reachable by sending a minimal MCP init request or by using your MCP client that points at the server.
Notes:
- The Unity runner will modify your Unity project to include is.nurture.mcp, so commit those changes if you use version control.
- Replace the placeholder paths with actual Unity Editor and project paths before starting.
Additional notes
Tips:
- If you run into Unity startup hangs on Windows due to external dependencies, ensure you are using a supported Unity version and consider launching with the Unity Hub path if required by your environment.
- The included toolset covers assets, scenes, scripting, search, and editor state. You can extend or customize by adding your own static tool classes annotated for MCP.
- When using vision tools, be mindful of performance: large scenes or many assets can impact response times; consider focusing queries to specific namespaces or asset types when possible.
- Environment variables can configure Unity paths or plugin behavior in your CI/CD pipelines; document any required VARNAME placeholders in your deployment docs.
Related MCP Servers
uLoopMCP
Your Unity project's AI autopilot. Compile, test, debug, repeat—until it just works.
Mcp.Net
A fully featured C# implementation of Anthropic's Model Context Protocol (MCP)
RimSearcher
A Model Context Protocol (MCP) server for fast searching and retrieval of RimWorld source code.
Unity-AI-Tools-Template
Unity MCP Tool template project
unity -template
Simple template project for controlling Unity via MCP
mcpapp-colorpicker
A Model Context Protocol (MCP) App built with .NET that provides an interactive color picker with a rich UI