---
title: "XcodeBuildMCP: Build and Run iOS Apps from an AI Agent"
url: "https://mcpshelf.co/servers/xcodebuildmcp"
description: "XcodeBuildMCP lets an AI agent build, run and test iOS and macOS projects, boot simulators and read logs. Config, macOS needs and our install test."
updated: "2026-10-27"
site: "MCP Shelf"
---

# XcodeBuildMCP

> Build, run and test iOS and macOS apps, and drive simulators, from an agent.

Source: https://mcpshelf.co/servers/xcodebuildmcp  
Markdown: https://mcpshelf.co/servers/xcodebuildmcp.md  
Generated: 2026-11-23T16:09:15.010Z

## Facts

- **Name:** XcodeBuildMCP
- **Tagline:** Build, run and test iOS and macOS apps, and drive simulators, from an agent.
- **Description:** XcodeBuildMCP, now called MobileBuildMCP, is Sentry's MCP server and CLI that lets AI agents build, test and run iOS and macOS apps and control simulators through Xcode.
- **Repository:** https://github.com/getsentry/MobileBuildMCP
- **Package:** mobilebuildmcp 2.7.1 (npm)
- **Install:** `claude mcp add MobileBuildMCP -- npx -y mobilebuildmcp@latest mcp`
- **Transport:** stdio (local)
- **Auth:** Needs `mobilebuildmcp mcp`
- **Tools exposed:** 24: `session_show_defaults`, `session_use_defaults_profile`, `session_set_defaults`, `session_clear_defaults`, `list_sims`, `boot_sim`, `open_sim`, `build_sim`, `build_run_sim`, `test_sim`, `get_sim_app_path`, `install_app_sim`, `launch_app_sim`, `stop_app_sim`, `record_sim_video`, `clean`, `discover_projs`, `list_schemes`, `show_build_settings`, `get_app_bundle_id`, `screenshot`, `snapshot_ui`, `get_coverage_report`, `get_file_coverage`
- **Category:** Developer tools (https://mcpshelf.co/categories/developer-tools)
- **Stats:** 6.5K GitHub stars, 51.9K downloads a week, last commit 27 Oct 2026, 1 upvote on MCP Shelf
- **Install check:** Package checked
- **Listed:** 2026-10-26
- **Page updated:** 2026-10-27

## Full description

### What is XcodeBuildMCP?

**XcodeBuildMCP, now called MobileBuildMCP, is Sentry's MCP server and CLI that lets AI agents build, test and run iOS and macOS apps and control simulators through Xcode.**

Agents are good at writing Swift and bad at knowing whether it compiles. XcodeBuildMCP closes that loop: it wraps xcodebuild and the simulator tools so the agent can build a scheme, read the errors, boot a simulator, install the app and capture logs.

The project now lives under Sentry and ships as MobileBuildMCP: a mobilebuildmcp package and command that work as both a CLI and an MCP server. The old xcodebuildmcp package stopped getting releases at 2.7.0.

|  |  |
| --- | --- |
| Made by | Sentry (started by Cameron Cooke) |
| GitHub | https://github.com/getsentry/MobileBuildMCP |
| Licence | MIT |
| npm package | [mobilebuildmcp](https://www.npmjs.com/package/mobilebuildmcp) 2.7.1 (23 Sept 2026) |
| GitHub stars | 6.5K |
| Downloads | 51.9K a week |
| Last commit | 27 Oct 2026 |
| Tools | 24 |
| Runs on | Your computer |
| Install check | Package checked |
| Category | [Developer tools](https://mcpshelf.co/categories/developer-tools) |
| Works with | Claude Code, Cursor, Claude Desktop, VS Code, Codex, Windsurf |
| Setup checked | 27 Oct 2026 |
| Page updated | 27 Oct 2026 |

**Our check:** The project renamed its npm package from xcodebuildmcp to mobilebuildmcp, which links back to getsentry/MobileBuildMCP; the config uses the new name.

#### Try asking XcodeBuildMCP

- "Build my app for the iPhone 16 simulator, run it and tell me about any build errors."
- "Run the unit tests for the main scheme and summarise the failures."
- "Which schemes and simulators are available for this project?"

#### MCP Shelf take

> We started XcodeBuildMCP on our own test machine on 26 Oct 2026 and it answered with 24 tools. 12 of the 24 only read; the other 12 can change things. Every tool comes with a useful description, all of them say whether they change things, and the tool list costs about 1,000 tokens of context before you ask a thing. It sits 9th of 24 in its category on our shelf by GitHub stars (6.5K, with 51.9K downloads a week).

— MCP Shelf tests (numbers from our own runs), tested on 26 Oct 2026

### What tools does XcodeBuildMCP have?

We listed 24 tools on 26 Oct 2026. 12 only read; the rest can change things or run commands.

| Tool | Kind | What it is for |
| --- | --- | --- |
| `session_show_defaults` | reads | Shows the remembered project, scheme and simulator. |
| `session_use_defaults_profile` | changes | Switches to a saved set of defaults, for repos with several apps. |
| `session_set_defaults` | changes | Remembers the project, scheme and simulator so later calls need fewer details. |
| `session_clear_defaults` | changes | Forgets the saved project, scheme and simulator choices. |
| `list_sims` | reads | Lists available simulators and whether they are running. |
| `boot_sim` | changes | Starts an iOS simulator. |
| `open_sim` | reads | Brings the Simulator app to the front. |
| `build_sim` | changes | Builds an iOS app for the simulator and reports any compiler errors. |
| `build_run_sim` | runs | Builds the app, installs it on a simulator and launches it in one step. |
| `test_sim` | changes | Runs the test suite on a simulator and returns the results. |
| `get_sim_app_path` | reads | Finds where the built .app sits for the simulator. |
| `install_app_sim` | changes | Installs a built app on a simulator. |
| `launch_app_sim` | changes | Opens an installed app on the simulator. |
| `stop_app_sim` | changes | Closes the running app on the simulator. |
| `record_sim_video` | changes | Records a video of the simulator screen. |
| `clean` | changes | Clears out old build products so the next build starts fresh. |
| `discover_projs` | reads | Finds the Xcode projects and workspaces in a folder. |
| `list_schemes` | reads | Lists the schemes a project or workspace can build. |
| `show_build_settings` | reads | Prints the Xcode build settings for a scheme. |
| `get_app_bundle_id` | reads | Reads an app's bundle identifier. |
| `screenshot` | reads | Captures the simulator screen so the agent can see the app. |
| `snapshot_ui` | reads | Describes what is on screen, element by element, with positions the agent can tap. |
| `get_coverage_report` | reads | Summarises code coverage after a test run. |
| `get_file_coverage` | reads | Shows which lines of one file the tests covered. |

#### How clearly it describes its tools

24 of 24 tools have a description and 24 of 24 say whether they change things. The tool list takes at least ~1,000 tokens of context. Every tool says whether it only reads or can change things, so a client can ask before the risky ones.

### How do I install XcodeBuildMCP?

#### Install steps from the XcodeBuildMCP README

Copied from the project's [README on GitHub](https://github.com/getsentry/MobileBuildMCP#readme) on 28 Oct 2026 under its MIT licence.

##### Installation

MobileBuildMCP ships as a single package with two modes: a **CLI** for direct terminal use and an **MCP server** for AI coding agents. Either install method gives you both.

###### Option A — Homebrew

```
brew tap getsentry/xcodebuildmcp
brew install mobilebuildmcp
```

###### Option B — npm (Node.js 18+)

```
npm install -g mobilebuildmcp@latest
```

Verify either install:

```
mobilebuildmcp --help
```

###### Connect your MCP client

Drop-in config snippets for Cursor, Claude Code, Codex, can be found in the official docs page [MCP Clients](https://github.com/getsentry/xcodebuildmcp.com/blob/main/app/docs/_content/clients.mdx). Most clients can also run the MCP server on demand via `npx -y mobilebuildmcp@latest mcp` without a global install.

#### What you need first

- macOS 14.5 or newer with Xcode 16 or newer
- Node.js 18 or newer, or Homebrew (brew install mobilebuildmcp)

#### Claude Code

Where: Your terminal

```bash
claude mcp add MobileBuildMCP -- npx -y mobilebuildmcp@latest mcp
```

If you installed it with Homebrew, use mobilebuildmcp mcp after the -- instead, which skips npx's download check each start.

#### Cursor

Where: ~/.cursor/mcp.json, or .cursor/mcp.json in a project

```json
{
  "mcpServers": {
    "xcodebuildmcp": {
      "command": "npx",
      "args": [
        "-y",
        "mobilebuildmcp@latest",
        "mcp"
      ]
    }
  }
}
```

With a Homebrew install, set command to mobilebuildmcp and args to ["mcp"].

#### Claude Desktop

Where: claude_desktop_config.json (Settings → Developer → Edit Config)

```json
{
  "mcpServers": {
    "xcodebuildmcp": {
      "command": "npx",
      "args": [
        "-y",
        "mobilebuildmcp@latest",
        "mcp"
      ]
    }
  }
}
```

With a Homebrew install, set command to mobilebuildmcp and args to ["mcp"]. If Claude cannot find npx, give the full path to it, since the app does not read your shell profile.

#### VS Code

Where: .vscode/mcp.json in your project

```json
{
  "servers": {
    "xcodebuildmcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "mobilebuildmcp@latest",
        "mcp"
      ]
    }
  }
}
```

#### Codex

Where: ~/.codex/config.toml, shared by the Codex CLI, IDE extension and ChatGPT desktop app

```
[mcp_servers.xcodebuildmcp]
command = "npx"
args = ["-y", "mobilebuildmcp@latest", "mcp"]
```

Or run: `codex mcp add xcodebuildmcp -- npx -y mobilebuildmcp@latest mcp`

#### Windsurf

Where: ~/.codeium/windsurf/mcp_config.json

```json
{
  "mcpServers": {
    "xcodebuildmcp": {
      "command": "npx",
      "args": [
        "-y",
        "mobilebuildmcp@latest",
        "mcp"
      ]
    }
  }
}
```

#### ChatGPT

Where: Not supported

ChatGPT on the web only connects to servers by URL. This one runs on your computer: the ChatGPT desktop app can start it from its MCP servers settings, with the same config as the Codex tab.

Checked against the project's own install docs on 27 Oct 2026: https://github.com/getsentry/MobileBuildMCP#readme, https://github.com/getsentry/xcodebuildmcp.com/blob/main/app/docs/_content/clients.mdx

### How do I configure XcodeBuildMCP?

| Setting | Kind | Required | What it does |
| --- | --- | --- | --- |
| `mobilebuildmcp mcp` | config | yes | The command your client runs to start the server after a Homebrew or npm install. Example: `"command": "mobilebuildmcp", "args": ["mcp"]` |
| `mobilebuildmcp init` | config | no | Installs the optional agent skills that teach your agent how to use the tools or the CLI. |
| `--scheme` | flag | no | Which scheme to build when you use the CLI directly. Example: `--scheme MyApp` |
| `--project-path` | flag | no | Path to the .xcodeproj or .xcworkspace for CLI builds. Example: `--project-path ./MyApp.xcodeproj` |

### What can XcodeBuildMCP read and change?

**It can read**

- Your Xcode projects, schemes and build settings
- Simulator screens, UI layout and logs
- Test results and coverage

**It can change**

- Build products in DerivedData
- Apps installed on simulators and, with signing set up, on devices
- Starts and stops simulators and apps

**Safer setup:** Everything stays on your Mac. Error reports go to Sentry; the project's privacy page explains how to switch that off.

### Good for

- Letting Claude Code or Cursor fix its own build errors
- Running a test target after each change
- Launching an app in a simulator and reading its logs

### XcodeBuildMCP not working? Common fixes

**Device builds fail with signing errors**
Set up code signing for the target in Xcode first. Simulator builds do not need it.

**Swift Macro validation errors**
The server already tells xcodebuild to skip macro validation. If you build by hand, add the same flag.

**Agent keeps asking which scheme to build**
Call session_set_defaults once with the project, scheme and simulator, and later calls reuse them.

### What are the alternatives to XcodeBuildMCP?

| Server | What it does | Tools | Runs on | Licence | Stars |
| --- | --- | --- | --- | --- | --- |
| [XcodeBuildMCP](https://mcpshelf.co/servers/xcodebuildmcp) | Build, run and test iOS and macOS apps, and drive simulators, from an agent. | 24 | Your computer | MIT | 6.5K |
| [Peekaboo](https://mcpshelf.co/servers/peekaboo) | Screenshots of any Mac app or screen, with optional questions about what is on it. | 4 groups | Your computer | MIT | 5.4K |
| [Kubernetes MCP Server](https://mcpshelf.co/servers/kubernetes) | Pods, logs, events and resources from your current kubeconfig context. | 14 | Your computer | Apache-2.0 | 2.2K |
| [IDA Pro MCP](https://mcpshelf.co/servers/ida-pro) | Lets an assistant read and annotate the binary you have open in IDA Pro. | 48 | Your computer | MIT | 13.2K |
| [GitMCP](https://mcpshelf.co/servers/gitmcp) | A hosted server that reads any public GitHub repo's docs and code on request. | 5 | Hosted | Apache-2.0 | 8.5K |
| [GhidraMCP](https://mcpshelf.co/servers/ghidra) | Decompile, cross-reference and rename inside Ghidra from a chat. | 30 | Your computer | Apache-2.0 | 11.6K |

### XcodeBuildMCP FAQ

#### How do I install XcodeBuildMCP in Claude Code?

Run claude mcp add MobileBuildMCP -- npx -y mobilebuildmcp@latest mcp on a Mac with Xcode. If you prefer a fixed install, brew tap getsentry/xcodebuildmcp and brew install mobilebuildmcp, then point the command at mobilebuildmcp mcp.

#### Is XcodeBuildMCP now MobileBuildMCP?

Yes. Sentry renamed it MobileBuildMCP and publishes it as the mobilebuildmcp package and command. The older xcodebuildmcp npm package stopped at 2.7.0, so update configs that still use the old name to get fixes.

#### What do I need to run XcodeBuildMCP?

A Mac on macOS 14.5 or later with Xcode 16 or later, plus Node.js 18 or later unless you install it with Homebrew. Building for a real device also needs code signing set up in Xcode.

#### Does XcodeBuildMCP work with Cursor and Codex?

Yes. Its docs give drop-in setup for Cursor, Codex, Claude Desktop, VS Code, Windsurf and the agents inside Xcode itself. It runs locally on your Mac, so ChatGPT on the web cannot use it.

#### Is XcodeBuildMCP free?

Yes, it is MIT licensed and free. It uses Sentry for runtime error telemetry about the tool itself, not your code; the project's Privacy and Telemetry page explains how to opt out.

#### Can I use XcodeBuildMCP without an AI agent?

Yes. The same package is a command line tool, so you can run builds, tests and simulator commands yourself with mobilebuildmcp, which is handy for checking what the agent will see.

#### Why does XcodeBuildMCP fail on device builds?

Usually code signing: device tools need a development team and provisioning set up in Xcode once, and the project's device signing guide walks through it. Swift Macro validation is already handled, since it asks xcodebuild to skip that check for agent builds.

#### Is it safe to let an agent run xcodebuild?

Everything runs on your Mac with your user account: it builds, installs and launches apps and can erase simulators, but it does not push code or ship to the App Store. Keep the project in git so you can review what the agent changed.

#### Can I use XcodeBuildMCP in VS Code?

Yes, through GitHub Copilot. In .vscode/mcp.json, add a server named xcodebuildmcp with type stdio that runs npx -y mobilebuildmcp@latest mcp. Then switch Copilot Chat to Agent mode to use its tools.

Full docs on GitHub: https://github.com/getsentry/MobileBuildMCP

## Notes for agents

Fetch these instead of parsing the HTML page:

- llms.txt: https://mcpshelf.co/llms.txt
- llms-full.txt: https://mcpshelf.co/llms-full.txt
- ai.txt: https://mcpshelf.co/ai.txt
- Full catalog (.md): https://mcpshelf.co/catalog.md
- API spec: https://mcpshelf.co/openapi.json
- MCP server: https://mcpshelf.co/mcp
- MCP manifest: https://mcpshelf.co/.well-known/mcp.json
- Developer docs: https://mcpshelf.co/developers

MCP endpoint (Streamable HTTP, no key): https://mcpshelf.co/mcp. REST API: https://mcpshelf.co/api/v1.

