Skip to main content
MCP server CX Codex

XcodeBuildMCP — Claude Code MCP server: what it does, how to install

Compiles Xcode projects, handles simulator runs, and executes test suites directly through AI coding agents.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env INCREMENTAL_BUILDS_ENABLED=<INCREMENTAL_BUILDS_ENABLED> --env XCODEBUILDMCP_ENABLED_WORKFLOWS=<XCODEBUILDMCP_ENABLED_WORKFLOWS> --env XCODEBUILDMCP_SENTRY_DISABLED=<XCODEBUILDMCP_SENTRY_DISABLED> --env XCODEBUILDMCP_DEBUG=<XCODEBUILDMCP_DEBUG> --transport stdio xcodebuildmcp -- npx -y xcodebuildmcp
Open on GitHub

What XcodeBuildMCP does

This package delivers both a CLI tool and an MCP server for agents targeting iOS and macOS applications. It allows the model to run scheme builds, output portable .xctestproducts files, and execute test bundles on target simulators. The server tells xcodebuild to bypass macro validation so builds using Swift Macros run cleanly.

A per-workspace background daemon manages persistent tasks like log capturing and debugging sessions. It auto-starts when needed. Working with physical hardware requires valid code signing profiles already set up in Xcode.

The server requires macOS 14.5 or later alongside Xcode 16.x. Internal error telemetry sends reports to Sentry by default, though you can turn it off by setting XCODEBUILDMCP_SENTRY_DISABLED.

What it helps with

  • build iOS or macOS projects for a designated simulator
  • prepare portable test products without executing tests immediately
  • run test suites from artifacts on simulated Apple hardware
  • capture stateful logs and debug info via a local workspace daemon

Example prompts for the agent

  • Build the MyApp scheme for iPhone 17 using xcodebuildmcp
  • Generate test products for MyApp.xcodeproj with build-for-testing
  • Execute test runs using the MyApp.xctestproducts bundle

How to install XcodeBuildMCP

Platform CLI

claude mcp add --env INCREMENTAL_BUILDS_ENABLED=<INCREMENTAL_BUILDS_ENABLED> --env XCODEBUILDMCP_ENABLED_WORKFLOWS=<XCODEBUILDMCP_ENABLED_WORKFLOWS> --env XCODEBUILDMCP_SENTRY_DISABLED=<XCODEBUILDMCP_SENTRY_DISABLED> --env XCODEBUILDMCP_DEBUG=<XCODEBUILDMCP_DEBUG> --transport stdio xcodebuildmcp -- npx -y xcodebuildmcp

Replace <…> with your own values

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about XcodeBuildMCP

How to install XcodeBuildMCP in Claude Code?

Run claude mcp add xcodebuildmcp -- npx -y xcodebuildmcp in your terminal. You can pass runtime flags and disable telemetry using the --env options.

What are the environment requirements?

You need macOS 14.5 or later and Xcode 16.x or newer. Installing via npm also requires Node.js 18.x or later.

Does running on physical devices require special setup?

Yes. Device-oriented tools fail without active code signing configured inside your Xcode project settings.

Similar MCP servers

Everything for Mobile →

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor