What is XcodeMCP?
XcodeMCP is a Model Context Protocol (MCP) server and standalone CLI that controls Xcode directly through JavaScript for Automation (JXA). It provides tools for building, running, testing, debugging, parsing build logs, analyzing XCResult files, and validating the environment. It can run alongside Apple’s official Xcode MCP server in sidekick mode to offer complementary tools.
How to use XcodeMCP?
Install via npx -y xcodemcp@latest or globally with npm install -g xcodemcp. Use it as an MCP server by adding a JSON configuration to MCP clients (Claude Desktop, VS Code, etc.) or as a CLI tool with the xcodecontrol command. For side-by-side use with Apple’s official Xcode MCP, start with --sidekick-only to exclude build/run/test/debug tools. Optional but recommended: install XCLogParser via brew install xclogparser. Requirements: macOS with Xcode and Node.js 18+.
Key features of XcodeMCP
- Controls Xcode directly through JXA (not xcodebuild CLI)
- XCResult analysis with screenshot extraction and UI hierarchy
- Build log parsing with XCLogParser for precise error locations
- Comprehensive health checks and environment validation
- Sidekick mode to complement Apple’s official Xcode MCP
- Full‑featured CLI with 100% MCP server feature parity
Use cases of XcodeMCP
- Build and run Xcode projects from an AI coding assistant
- Run tests, browse results, and extract debug attachments
- Manage project schemes and workspaces programmatically
- Debug sessions and stop current operations
- Analyze test failures with console logs and UI hierarchy snapshots
Comments