I
Iphone MCP
作者 @Lakr233
A Model Context Protocol (MCP) server for automating iPhone tasks with Appium. Supports app control, UI interactions, and screenshot capture via streamable HTTP.
创建于 9/1/2025
更新于 4 months ago
README
Repository documentation and setup instructions
iPhone MCP Server
A Model Context Protocol (MCP) server for automating iPhone tasks with Appium. Supports app control, UI interactions, and screenshot capture via streamable HTTP.

We recommend Cherry Studio as an MCP client for iPhone automation.
Features
- Retrieve device info and list installed apps
- Capture screenshots (JPEG, around 500KB)
- List UI elements and perform touch operations
- Launch or switch apps using bundle IDs
- Optimized XML output to minimize token usage
Installation
Prerequisites
- Python 3.8 or later
- Node.js and npm
- iPhone with UDID
- Xcode
Steps
- Clone the repo:
git clone https://github.com/Lakr233/iphone-mcp.git && cd iphone-mcp - Set up virtual environment:
python -m venv .venv && source .venv/bin/activate - Install dependencies:
pip install -r requirements.txt - Install Appium:
npm install -g appium && appium driver install xcuitest - Set up WebDriver Agent: Follow the WebDriver Agent Guide
- Configure: Edit
start.shwith yourDEVICE_UDID
Usage
Run ./start.sh to start Appium and the MCP server. Access it at http://127.0.0.1:8765/mcp with default settings.
Tools
iphone_device_info: Get device detailsiphone_device_apps: List installed appsiphone_interface_snapshot: Capture screenshot and XMLiphone_interface_elements: List UI elementsiphone_operate_click: Perform tapiphone_operate_swipe: Perform swipeiphone_operate_text_input: Input textiphone_operate_app_launch: Launch appiphone_operate_get_current_bundle_id: Get current bundle ID
Configuration
Set environment variables in start.sh (defaults in src/utils.py):
DEVICE_UDID(required)APPIUM_HOST/PORTSERVER_HOST/PORT/PATHLOG_LEVEL
Development
- Run tests:
pytest - Code style: Python 3.8+ with type hints
Contributing
Fork the repo, create a branch, and submit a pull request. Report bugs or suggest features via issues.
License
MIT
快速设置
此服务器的安装指南
安装包 (如果需要)
uvx iphone-mcp
Cursor 配置 (mcp.json)
{
"mcpServers": {
"lakr233-iphone-mcp": {
"command": "uvx",
"args": [
"iphone-mcp"
]
}
}
}
作者服务器
其他服务器由 Lakr233