phonectl-mcp
Enables AI agents to see and control a real iPhone running iOS 27 or later over USB, including screenshots, on-screen text extraction with positions, taps, long presses, swipes, typing, key/chord and hardware button presses, app launching and listing, clipboard access, and status checks.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
An MCP server for screenshots, on-screen text, taps, swipes, typing, buttons, apps and the clipboard on an iPhone connected to your Mac. Nothing to install on the phone, no Xcode, no jailbreak. Several agents and scripts can use it at once: they take turns, and none taps on another's screen.
Requirements
A Mac with uv
An iPhone on iOS 27 or later, with Developer Mode on
A USB data cable for the first setup. After that, Wi-Fi works too
Tested on an iPhone 17 Pro with iOS 27.2 and macOS 27.
Related MCP server: iphone-use
Install
uv tool install phonectl-mcp
phonectl install-service # runs the server at login on http://127.0.0.1:47321/mcp
phonectl doctor # checks cable, trust, Developer Mode, disk image and server
phonectl setup claude-code # or: codex, gemini (the desktop app), deepseek-harnessReload the agent as setup says, then ask it for a screenshot of the phone. setup adds the server and its token to the agent's MCP config, the phonectl-scripts skill, and, for Claude Code, Codex and Gemini, a hook that frees the phone when the agent's turn ends (Codex asks you to approve it once). It backs up each file it changes as <file>.phonectl.bak.
Or paste this to your coding agent:
Install phonectl-mcp by following https://github.com/jiefeng-ai/phonectl-mcp#install and connect yourself with
phonectl setup. Runphonectl doctoruntil it passes. When I need to do something on the phone, tell me step by step and wait for me. Finally, tell me how to restart you so the phone tools load.
Add the server by hand. The agent gets the phone but not the skill, so scripts it writes will not know to yield the phone to other agents.
{
"mcpServers": {
"phone": {
"url": "http://127.0.0.1:47321/mcp",
"headers": { "Authorization": "Bearer <contents of ~/.config/phonectl/token>" }
}
}
}Tools
Coordinates are iOS points, the same as the pixels of the returned screenshot.
Tool | What it does |
| Captures the screen |
| Text on screen with positions, as JSON. Much cheaper than an image |
| Tap text found on screen; wait until text appears or goes away |
| Touch. To scroll down, swipe upward |
| Types into the focused field by pasting, so the phone's input method cannot change it; submit with |
| A key or chord, such as |
|
|
| Opens apps (with |
| The phone's clipboard |
| The server, the phone link, and who is using the phone |
Tools that act on the phone return a screenshot taken afterwards (screenshot=False skips it). Taps are not confirmed, so check that screenshot.
Scripts. A fixed sequence of steps runs faster and cheaper as a script than as one model round trip per step. A script is one more MCP client of the same server (same URL, same token); never connect to the phone directly. Agents connected with phonectl setup get the full rules in the phonectl-scripts skill.
phonectl hold 30m keeps agents off the phone while you use it; phonectl hold off ends that.
How it works
The server drives the phone through Apple's developer services, using pymobiledevice3. Taps and keys take the same path as Xcode's device mirroring, which is why it needs iOS 27. read_text reads the screen on the Mac with Apple's Vision framework. The only thing put on the phone is Apple's developer disk image, which the server mounts by itself: no WebDriverAgent, no app, no jailbreak.
Troubleshooting
Run phonectl doctor first. It tells you which link is broken.
Symptom | Fix |
No iPhone found | Use a data cable, unlock the phone, replug |
"Mac is not trusted" | Unlock the phone, replug, tap Trust |
No Developer Mode switch | Run |
Disk image install fails | The server installs the developer disk image on first connect and downloads it from GitHub; check the network or proxy, then |
Taps do nothing | Needs iOS 27+; keep the screen on and unlocked |
Wi-Fi link drops | A locked phone leaves the network for up to minutes at a time. Unlock it and wait a few seconds |
Clients cannot connect |
|
Security
The server listens only on
127.0.0.1and rejects requests without the token.An agent can do anything your finger can: send messages, pay, delete. Keep its instructions narrow and watch the screen. Use at your own risk; automating third-party apps may break their terms.
Settings
Variable | Default | Meaning |
| first connected iPhone | Which phone to use when several are connected |
|
| HTTP port (127.0.0.1 only) |
|
| Where the token is kept |
|
| Pixels per point; 2 on iPhone SE, XR, 11. Only affects screenshot size |
|
|
|
|
| Seconds to wait before the screenshot after an action; |
|
| Idle seconds before the input stream closes (reopening takes ~0.6 s) |
|
| Seconds without a key before the virtual keyboard detaches, so the on-screen keyboard comes back |
|
| Seconds to wait for the phone, on top of the gesture time |
|
| Seconds without a call after which a client that has not said it is done counts as done, if someone waits |
|
| Seconds a call waits in line before it ends with |
|
| After holding the phone this long, a client lets a waiting one go first |
|
| Log level ( |
Update and uninstall
uv tool upgrade phonectl-mcp && phonectl restart && phonectl updateWhat changed in each version: Releases.
To uninstall, run phonectl setup --remove <agent> for each agent you connected, then:
phonectl uninstall-service
uv tool uninstall phonectl-mcp
rm -r ~/.config/phonectlLicense
MIT
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Let your AI agent control real iPhones: screenshots, tap, swipe, type and open apps.
Let your AI use a real iPhone: see the screen, tap, type, open apps, run saved workflows.
iMessage for AI agents, from your iPhone. No Mac needed, and you choose which chats they read.
AI agents on your own iPhone or Android: run tasks in real apps, read the screen, tap and type.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to control real iPhones and simulators on macOS, allowing for UI interaction, testing, and automation.64 npm98MIT
- FlicenseAqualityAmaintenanceControl a real iPhone or iOS Simulator through a macOS daemon and XCTest runner over USB or Wi-Fi: read screen text, tap, type, swipe, inspect logs and replay flows with explicit outcomes. Browser sandbox: use readonly to inspect 12 preloaded flows without a phone. Reuse an existing sandbox from MCP Deployments, or delete it before starting another. Device control needs your Mac and iPhone.43531-
- AlicenseNot gradedqualityBmaintenanceEnables AI agents to operate a real iPhone from a Mac by reading the screen over USB and sending taps, swipes, typing, and app launches over Bluetooth, with every action returning a fresh screenshot so the agent can verify its work. Runs as a local MCP server, so agents can test iOS apps on physical devices and automate everyday phone tasks.38 npm10MIT
- AlicenseAqualityAmaintenanceLet AI agents operate a real USB-connected iPhone from Linux — no Mac, no jailbreak, no paid developer account. Screenshots, taps, swipes, text input, element tree and app control via WebDriverAgent, with CoreDevice HID fallback.17198MIT