android-mcp-server
Enables Android device control via ADB and scrcpy, including device management, app management, file operations, shell commands, input simulation, screen mirroring, and UI element inspection.
README
Android MCP Server
MCP server providing ADB and scrcpy capabilities for Android device control. Built with FastMCP.
Assisted by Minimax Model via Claude Code.
Features
- Device Management: List devices, get device info
- App Management: Install/uninstall apps, start/stop apps, list packages
- File Operations: Push/pull files between device and host
- Shell Execution: Run shell commands on device, exec-out for binary output
- Input Control: Tap, swipe, input text, press keys
- System Info: Screen size, battery status, system properties
- Screen Control: Screen mirroring and control via scrcpy, screenshot via exec-out
- UI Element Finding: Dump UI hierarchy, find elements by attributes
Install
uv add android-mcp-server
Or install from source:
# Clone the repo, then install
git clone https://github.com/chldu2000/android-mcp-server.git
cd android-mcp-server
uv pip install -e .
uv run python -m android_mcp.main
Add MCP Server
Claude Code
claude mcp add android uv run -- python -m android_mcp.main --cwd /Path/to/workdir
Other MCP Clients
The server can be run with:
uv run python -m android_mcp.main
Tools
Device Management
| Tool | Description |
|---|---|
adb_list_devices |
List all connected Android devices |
adb_device_info |
Get detailed device information |
App Management
| Tool | Description |
|---|---|
adb_install_app |
Install an APK |
adb_uninstall_app |
Uninstall an application |
adb_list_packages |
List installed packages |
adb_start_app |
Start an application |
adb_stop_app |
Force stop an application |
File Operations
| Tool | Description |
|---|---|
adb_pull_file |
Pull file from device |
adb_push_file |
Push file to device |
Shell
| Tool | Description |
|---|---|
adb_shell |
Execute shell command |
adb_exec_out |
Execute command via exec-out (for binary output) |
Input Control
| Tool | Description |
|---|---|
adb_tap |
Tap at coordinates |
adb_swipe |
Swipe gesture |
adb_input_text |
Input text |
adb_press_key |
Press key event |
System Info
| Tool | Description |
|---|---|
adb_get_screen_size |
Get screen resolution |
adb_get_battery |
Get battery status |
adb_get_properties |
Get system properties |
Screen Control (scrcpy)
| Tool | Description |
|---|---|
scrcpy_start |
Start screen mirroring |
scrcpy_stop |
Stop screen mirroring |
scrcpy_screenshot |
Take screenshot |
scrcpy_control |
Send control command |
adb_screencap |
Capture screenshot via exec-out |
UI Elements
| Tool | Description |
|---|---|
adb_dump_ui_tree |
Dump UI hierarchy tree |
adb_find_element |
Find UI elements by attributes |
Device Connection
USB Devices
Connect via USB and ensure USB debugging is enabled on the device.
Network Devices
For TCP/IP connection:
-
Enable TCP/IP mode on device:
adb tcpip 5555 -
Find device IP:
adb shell ip route -
Connect:
adb connect <device-ip>:5555
Dependencies
- fastmcp - MCP server framework
- scrcpy - Screen mirroring (must be installed separately)
- uiautomator2 - uiautomator2 Python wrapper
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。