user-guide

A usage guide for connecting an Xcode MCP Server to an AI assistant and working with Xcode projects.

In plain words
What is it for?
Use it to start the server, connect a compatible assistant, set the projects directory, find Xcode workspaces or Swift Package Manager projects, and view the active project.
Why use it?
It explains the setup and the questions you can ask, so the assistant can find projects and identify the active one without guessing the workflow.

Cursor rule for Cursor

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add rules/r-huijts/xcode-mcp-server/user-guide
Clone the repo
git clone --depth 1 https://github.com/r-huijts/xcode-mcp-server

Made for: Cursor.

Per session 2,979 This file is loaded in full into every session.
When invoked 2,979 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.02979 $0.02979
Opus 5 $0.01489 $0.01489
Sonnet 5 $0.00596 $0.00596
Haiku 4.5 $0.00298 $0.00298

Measured 2d ago against content hash 1f357e053669, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

user-guide scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/user-guide.mdc · 671 lines

How it starts

The opening of the file, as written. The whole thing — 671 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Xcode MCP Server User Guide

This guide provides detailed instructions on how to effectively use the Xcode MCP Server with AI assistants. It covers common workflows, example prompts, and best practices.

Getting Started

After installing the server, you can start using it with any MCP-compatible AI assistant. This guide focuses on using it with Claude Desktop and Cursor, but the concepts apply to any MCP client.

Basic Workflow

  1. Start the server using npm start
  2. Connect your AI assistant to the server
  3. Interact with your Xcode projects through the AI

Working with Projects

Setting Your Projects Directory

If you didn't set a projects directory during setup, you can do it through the AI:

Set my Xcode projects directory to /Users/username/Documents/XcodeProjects

The server will acknowledge the change and attempt to detect any projects in that directory.

Finding Projects

You can ask the AI to find Xcode projects in your directory:

Find all Xcode projects in my projects directory, including workspaces and Swift Package Manager projects

Viewing Active Project

You can ask about the currently active project:

What's my current active project? Show me its detailed information including configurations, targets, and schemes.

Setting Active Project

If the automatic project detection doesn't find your project, you can set it manually:

Set the active project to /Users/username/Documents/XcodeProjects/MyApp.xcodeproj

The server now supports different project types:

Set the active project to /Users/username/Documents/XcodeProjects/MyApp.xcworkspace

Or for Swift Package Manager projects:

Set the active project to /Users/username/Documents/SwiftPackages/MyPackage

Directory Navigation

The server now has improved directory navigation. You can change directories:

Change directory to Sources/Models

Push directories onto a stack for easy navigation:

Read the full file on GitHub · 671 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 671 lines · 2,979 tokens per session scan A 1f357e053669

Subscribe to this mod's changes

user-guide is a cursor rule published in the GitHub repository r-huijts/xcode-mcp-server (385 stars, last pushed 7mo ago), licensed MIT. It adds 2,979 tokens to every session, about $0.0149 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.