From safe-engineering
Mobile device automation using Mobile MCP server for iOS and Android. This skill should be used when interacting with mobile apps on simulators, emulators, or physical devices - tapping, swiping, typing, taking screenshots, launching apps, or automating mobile workflows. Triggers on "tap on mobile", "mobile screenshot", "launch app", "swipe", "mobile automation", "test on device", "iOS simulator", "Android emulator".
npx claudepluginhub safe-global/safe-engineering-pluginThis skill uses the workspace's default tool permissions.
Mobile MCP is an MCP server that enables automation of iOS and Android applications across simulators, emulators, and physical devices. It uses native accessibility trees for element discovery and coordinate-based interactions.
Searches, retrieves, and installs Agent Skills from prompts.chat registry using MCP tools like search_skills and get_skill. Activates for finding skills, browsing catalogs, or extending Claude.
Searches prompts.chat for AI prompt templates by keyword or category, retrieves by ID with variable handling, and improves prompts via AI. Use for discovering or enhancing prompts.
Guides TDD-style skill creation: pressure scenarios as tests, baseline agent failures, write docs to enforce compliance, verify with RED-GREEN-REFACTOR.
Mobile MCP is an MCP server that enables automation of iOS and Android applications across simulators, emulators, and physical devices. It uses native accessibility trees for element discovery and coordinate-based interactions.
Before using mobile-mcp tools, verify the MCP server is configured. The tools should be available as mcp__mobile-mcp__mobile_* functions.
If tools are not available, add to Claude Code MCP config:
{
"mcpServers": {
"mobile-mcp": {
"command": "npx",
"args": ["-y", "@mobilenext/mobile-mcp@latest"]
}
}
}
The screenshot + element list pattern is optimal for mobile automation:
list_available_devices → launch_app → list_elements_on_screen → interact → take_screenshot → repeat
| Tool | Parameters | Description |
|---|---|---|
mobile_list_available_devices | none | List all physical devices, simulators, and emulators |
mobile_get_screen_size | device | Get device screen dimensions in pixels |
mobile_get_orientation | device | Check portrait/landscape orientation |
mobile_set_orientation | device, orientation (portrait/landscape) | Rotate screen |
| Tool | Parameters | Description |
|---|---|---|
mobile_list_apps | device | List all installed applications |
mobile_launch_app | device, packageName | Open app by bundle/package ID |
mobile_terminate_app | device, packageName | Close running app |
mobile_install_app | device, path (.apk/.ipa/.app/.zip) | Install app from file |
mobile_uninstall_app | device, bundle_id | Remove app from device |
| Tool | Parameters | Description |
|---|---|---|
mobile_list_elements_on_screen | device | List UI elements with coordinates and labels |
mobile_click_on_screen_at_coordinates | device, x, y | Tap at coordinates |
mobile_double_tap_on_screen | device, x, y | Double-tap at coordinates |
mobile_long_press_on_screen_at_coordinates | device, x, y, duration? (ms, default 500) | Long press |
mobile_swipe_on_screen | device, direction (up/down/left/right), x?, y?, distance? | Swipe gesture |
| Tool | Parameters | Description |
|---|---|---|
mobile_type_keys | device, text, submit (boolean) | Type text into focused element |
mobile_press_button | device, button (HOME/BACK/VOLUME_UP/VOLUME_DOWN/ENTER) | Press device button |
mobile_open_url | device, url | Open URL in device browser |
| Tool | Parameters | Description |
|---|---|---|
mobile_take_screenshot | device | Capture screen (returns base64 image) |
mobile_save_screenshot | device, saveTo (file path) | Save screenshot to file |
Always start by listing devices. The device parameter is required for nearly every tool.
1. Call mobile_list_available_devices
2. Pick the target device identifier from the list
3. Use that identifier for all subsequent calls
mobile_list_elements_on_screen returns UI elements with:
Use these coordinates for tap/click interactions. This is more reliable than guessing coordinates from screenshots.
For complex interactions, combine element listing with screenshots:
mobile_list_elements_on_screen — get structured element datamobile_take_screenshot — visual context for layout understandingIf the target element is not visible in mobile_list_elements_on_screen:
mobile_swipe_on_screen with direction "up" to scroll downmobile_list_elements_on_screen again to check for the elementmobile_list_available_devices
→ device: "iPhone 16 Pro"
mobile_launch_app
device: "iPhone 16 Pro"
packageName: "com.example.myapp"
mobile_take_screenshot
device: "iPhone 16 Pro"
→ base64 image of app screen
mobile_list_elements_on_screen
device: "iPhone 16 Pro"
→ textfield "Email" at (200, 350)
→ textfield "Password" at (200, 420)
→ button "Sign In" at (200, 500)
mobile_click_on_screen_at_coordinates
device: "iPhone 16 Pro", x: 200, y: 350
mobile_type_keys
device: "iPhone 16 Pro", text: "user@example.com", submit: false
mobile_click_on_screen_at_coordinates
device: "iPhone 16 Pro", x: 200, y: 420
mobile_type_keys
device: "iPhone 16 Pro", text: "password123", submit: false
mobile_click_on_screen_at_coordinates
device: "iPhone 16 Pro", x: 200, y: 500
mobile_take_screenshot
device: "iPhone 16 Pro"
→ verify logged in
mobile_launch_app
device: "Pixel 8", packageName: "com.android.settings"
mobile_swipe_on_screen
device: "Pixel 8", direction: "up"
mobile_list_elements_on_screen
device: "Pixel 8"
→ find target element coordinates
mobile_click_on_screen_at_coordinates
device: "Pixel 8", x: 540, y: 680
mobile_press_button
device: "Pixel 8", button: "BACK"
| Feature | mobile-mcp | Playwright MCP |
|---|---|---|
| Target | Mobile apps (iOS/Android) | Web browsers |
| Selection | Coordinates from accessibility tree | Refs from DOM snapshot |
| Gestures | Swipe, long press, double tap | Click, hover, drag |
| Navigation | App launch, device buttons | URL navigation, tabs |
| Best for | Native mobile app automation | Web page automation |
Use mobile-mcp for native mobile app testing and automation. Use Playwright MCP for web browser automation.