Back to Home
akiojin icon

unity-mcp-server

by akiojin

Overview

A server to enable AI agents or automated scripts to interact with and control the Unity Editor, performing tasks such as scene management, GameObject manipulation, asset management, input simulation, code editing, and extracting editor state.

Installation

Run Command
docker compose up

Environment Variables

  • GITHUB_TOKEN
  • UNITY_MCP_MCP_HOST
  • UNITY_MCP_PORT
  • UNITY_PROJECT_ROOT
  • MAX_MCP_OUTPUT_TOKENS
  • ENABLE_BACKGROUND_TASKS
  • FORCE_AUTO_BACKGROUND_TASKS
  • UNITY_MCP_TOOLS_ROOT
  • UNITY_MCP_LOG_LEVEL
  • UNITY_MCP_HTTP_ENABLED
  • UNITY_MCP_HTTP_PORT
  • UNITY_MCP_TELEMETRY_ENABLED
  • UNITY_MCP_LSP_REQUEST_TIMEOUT_MS

Security Notes

The server downloads and executes C# Language Server Protocol (LSP) binaries from GitHub releases, relying on SHA256 checksums for integrity. A compromised GitHub release or manifest could lead to arbitrary code execution (supply-chain risk). It directly manipulates C# source files and can execute Unity Editor menu items, including file system operations and potentially sensitive actions. While some handlers implement safety checks (e.g., menu item blacklist, settings confirmation, C# syntax/LSP validation), the broad control over the Unity Editor presents a high-privilege attack surface if exploited. Communication is over TCP (local) and optionally HTTP. Running untrusted code is inherently risky.

Similar Servers

Stats

Interest Score33
Security Score5
Cost ClassMedium
Avg Tokens3000
Stars6
Forks1
Last Update2026-01-07

Tags

UnityGame DevelopmentAutomationEditor ExtensionC#ScriptingToolingAI Agent