# Unity Plugin Setup

The Unity Plugin Setup guide is the full deep-dive for installing AI Game Developer (Unity-MCP) into a Unity project: prerequisites, the three install paths (CLI, .unitypackage installer, OpenUPM), verifying the AI Game Developer window, wiring up your AI client, optional domain extensions, and troubleshooting.

_Last updated: 2026-06-17_

## Prerequisites

- Unity 2022.3 LTS or newer (Unity 6 / 6000.x recommended).
- An MCP-compatible AI client (Claude, Cursor, VS Code Copilot, Windsurf, Continue).
- Node.js (only for the CLI install path).

## Install paths

### Option A — CLI (recommended)

```bash
npm install -g unity-mcp-cli
unity-mcp-cli install-plugin ./MyUnityProject
unity-mcp-cli open ./MyUnityProject
```

### Option B — .unitypackage installer

Download AI-Game-Dev-Installer.unitypackage from the Unity-MCP GitHub releases, then in Unity choose Assets → Import Package → Custom Package… and pick the file.

### Option C — OpenUPM

```bash
openupm add com.ivanmurzak.unity.mcp
```

## Connect modes

### Cloud (default)

Connect through ai-game.dev using the device-code OAuth flow — no tokens to copy by hand. From the AI Game Developer window choose Cloud, click Authorize, and approve the device code in your browser. Works across firewalls and gives you usage analytics. This is the default and what we recommend for most users.

### Custom (self-hosted)

Prefer to run everything locally? Point the plugin at your own gamedev-mcp-server instance instead of the hosted endpoint. Your AI client then talks straight to your machine. Client-by-client config snippets live on the MCP endpoint page (/mcp-endpoint-info).

## Verify

Open Window → AI Game Developer, choose Cloud, click Authorize, and wait for the status pill to read Ready (green). Then connect your AI client and ask it to list MCP tools.

---

Source (HTML): https://ai-game.dev/docs/unity-plugin-setup
