Simulator MCP
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Simulator MCPtake a screenshot of the currently running simulator"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Simulator MCP
Allows AI to control iOS simulators via the MCP protocol — launch devices, take screenshots, tap, input text, capture network traffic, and mock interfaces.
Feature Overview
Category | Tool | Description |
Device Management |
| List all simulators (status, UDID, runtime) |
| Boot / Shutdown simulator | |
| Install .app package | |
| Launch APP (supports | |
| Open URL or deep link (automatically selects a booted simulator) | |
Screenshots |
| Take a screenshot and return it to AI as a base64 image (supports visual analysis) |
UI Interaction |
| Tap specific iOS coordinates (supports long press via |
| Swipe from start point to end point | |
| Input text into the currently focused input field | |
| Press hardware buttons ( | |
| Get UI accessibility tree (JSON format) | |
| Match element by text and tap its center coordinates | |
Network Interception |
| Start mitmproxy (default port 8080) |
| Stop proxy | |
| View captured traffic (supports URL and method filtering) | |
| Add mock rule (URL regex matching) | |
| Remove mock rule |
A total of 18 tools, covering device management, UI automation, and network interception scenarios.
Related MCP server: Shotter
Prerequisites
Dependency | Purpose | Installation |
Xcode | Provides | Mac App Store |
idb-companion | Native daemon for fb-idb (UI automation) |
|
Python >= 3.11 | Runtime |
|
uv (Recommended) | Package management |
|
The
proxy-dylib/libproxy_inject.dylibincluded in this repository is anarm64pre-compiled artifact; Intel Mac users need to recompile forx86_64or a universal version themselves.
Installation
cd simulator-mcp
# 方式一:uv(推荐)
uv venv && uv pip install -e .
# 方式二:pip
python -m venv .venv && source .venv/bin/activate && pip install -e .Python dependencies (auto-installed):
mcp >= 1.0— MCP protocol SDK (stdio JSON-RPC)mitmproxy >= 10.0— HTTP(S) proxyfb-idb— iOS simulator UI automation
Configure for Claude Code
Add to mcpServers in ~/.claude.json:
{
"mcpServers": {
"simulator": {
"command": "/path/to/simulator-mcp/.venv/bin/simulator-mcp"
}
}
}Configure for Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"simulator": {
"command": "/path/to/simulator-mcp/.venv/bin/simulator-mcp"
}
}
}Replace
/path/to/simulator-mcpwith the actual absolute path to the project.
Usage Example
Once configured, AI can directly control the simulator:
用户: 打开模拟器,截图看看当前页面
AI: 调用 list_devices → boot_device → take_screenshot
"当前页面显示的是 iOS 主屏幕..."
用户: 打开微博,点击注册按钮
AI: 调用 launch_app → take_screenshot → tap_element(text="注册")
"已点击注册按钮,进入了注册页面"
用户: 抓包看看注册接口返回了什么
AI: 调用 start_network_proxy → launch_app(proxy=true) → get_network_log(url_pattern="register")
"注册接口返回了 200,响应体是..."
用户: Mock 掉登录接口,返回自定义数据
AI: 调用 add_mock_rule(url_pattern="api/login", response_body='{"token":"fake"}')
"已添加 Mock 规则 mock_1"Network Capture Guide
Workflow
Start Proxy:
start_network_proxy(port=8080)Automatically starts mitmproxy in a background thread
If a simulator is currently booted, it will attempt to install the mitmproxy CA certificate first
Launch APP with Proxy:
launch_app(udid="xxx", bundle_id="com.example.app", proxy=true)Injects
libproxy_inject.dylibviaDYLD_INSERT_LIBRARIESSwizzles
NSURLSessionConfigurationto forward all HTTP(S) traffic to the proxyRe-installs the CA certificate on the target simulator to prevent HTTPS capture failure when the proxy starts after the simulator
View/Mock Requests:
get_network_log(url_pattern="api/user")— Filter by URL substringadd_mock_rule(url_pattern="api/login", response_body="...")— URL regex matching
Technical Principles
App 启动 → dylib 注入 → swizzle NSURLSessionConfiguration
→ 所有 NSURLSession 流量 → mitmproxy (127.0.0.1:8080)
→ MockEngine 检查规则 → 命中则返回假数据 / 未命中则转发真实服务器
→ NetworkLog 记录请求/响应(内存环形缓冲,最多 1000 条)
→ 同时落盘:
- `/tmp/proxy_requests.log`:摘要日志
- `/tmp/proxy_requests.jsonl`:结构化明细日志
- `/tmp/proxy_request_bodies/`:超大 body 的分流文件Project Structure
simulator-mcp/
├── pyproject.toml # 项目配置、依赖、入口定义
├── README.md # 本文件
├── ARCHITECTURE.md # 技术架构详细文档
├── diagrams/ # Mermaid 源文件 + PNG 架构图
├── proxy-dylib/
│ ├── proxy_inject.m # DYLD 注入源码 (Objective-C, 95 行)
│ └── libproxy_inject.dylib # 编译产物 (当前为 arm64)
└── src/simulator_mcp/
├── __init__.py # 入口: main() → asyncio.run(server.main())
├── __main__.py # python -m simulator_mcp 入口
├── server.py # MCP Server: 18 个工具注册 + call_tool 分发
├── simulator/
│ ├── simctl.py # xcrun simctl 异步封装 (设备管理 + 截图)
│ └── idb_client.py # fb-idb 异步封装 (UI 交互 + tap_element)
├── tools/
│ ├── device.py # 设备管理工具 (参数解析 + proxy 注入逻辑)
│ ├── screenshot.py # 截图工具 (PNG → base64)
│ ├── ui.py # UI 交互工具 (参数解析 → idb_client)
│ └── network.py # 网络工具 (参数解析 → proxy_server)
└── proxy/
├── proxy_server.py # mitmproxy 生命周期 + ProxyAddon + CA 证书安装
├── network_log.py # 请求日志: 内存环形缓冲 + 结构化落盘
└── mock_engine.py # Mock 规则引擎: 正则匹配, 首条命中Recompiling dylib (Optional)
If you modify proxy_inject.m:
cd proxy-dylib
clang -dynamiclib -framework Foundation \
-arch arm64 -arch x86_64 \
-o libproxy_inject.dylib \
proxy_inject.mArchitecture Documentation
Detailed technical architecture design can be found in ARCHITECTURE.md.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityAmaintenanceEnables interaction with iOS simulators by providing tools to inspect UI elements, control UI interactions, and manage simulators through natural language commands.179,7002,136MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI assistants to automate iOS Simulator interactions including device management, UI element interaction (tap, swipe, type), screenshot capture, and execution of YAML-defined navigation workflows.2MIT
- AlicenseNot gradedqualityDmaintenanceEnables comprehensive control of iOS simulators and real devices through AI assistants, supporting app management, UI automation, screenshots, media operations, and location simulation for iOS development and testing workflows.5MIT
- AlicenseNot gradedqualityFmaintenanceAn MCP server that provides comprehensive tools for managing iOS simulators, including device control, app lifecycle management, and UI automation. It enables developers to boot devices, install apps, capture screenshots, and simulate user interactions through natural language commands.3MIT
Related MCP Connectors
MCP connector that lets ChatGPT list, search, and run your Apple Shortcuts via a local Mac agent
Live browser debugging for AI assistants — DOM, console, network via MCP.
OCR, transcription, file extraction, and image generation for AI agents via MCP.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/992429169/simulator-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server