scrcpy MCP Server
Provides tools for controlling Android devices via ADB and scrcpy, including device management, input injection, screen capture/recording, app management, clipboard operations, file transfer, and mirroring.
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.
scrcpy MCP Server
Local MCP server that exposes Android device control via adb and scrcpy as 22 tools for MCP clients like Claude Code and Codex CLI.
Quick Start
One command — no prerequisites needed (the installer handles everything):
curl -fsSL https://raw.githubusercontent.com/charettep/scrcpy-mcp/main/install.sh | bashOr from a local clone:
git clone https://github.com/charettep/scrcpy-mcp.git && cd scrcpy-mcp
./install.shThe installer will:
Detect your OS and package manager (apt, dnf, pacman, brew)
Download the repo to
~/mcp/scrcpy-mcp(if running via curl)Check for
adb,scrcpy, anduv— install any that are missingFind Python 3.10+ and create an isolated venv with dependencies
Detect installed MCP clients (Claude Code, Codex CLI)
Ask where to register the server:
Global — injects config directly into
~/.claude.jsonand/or~/.codex/config.tomlProject — generates a local
.mcp.jsonfile
Re-running the installer is safe — it updates the existing install and overwrites old config entries.
Related MCP server: adb-mcp-server
Prerequisites
Python 3.10+
adb(from Android SDK platform-tools)scrcpy(for mirroring/recording sessions)An Android device with USB debugging enabled
The installer handles all of the above automatically.
Manual Install
If you prefer not to use the installer:
uv venv .venv && uv pip install -r requirements.txtThen add to your project .mcp.json:
{
"mcpServers": {
"scrcpy": {
"command": "/path/to/.venv/bin/python",
"args": ["/absolute/path/to/scrcpy_mcp.py"],
"env": {
"SCRCPY_MCP_ADB_PATH": "/usr/bin/adb",
"SCRCPY_MCP_SCRCPY_PATH": "/usr/bin/scrcpy"
}
}
}
}The env block is optional — without it, adb and scrcpy are resolved from PATH.
Available Tools (22)
Device Management
Tool | Description |
| List connected devices with status |
| Get model, Android version, screen resolution, battery, IP |
| Connect/disconnect device via wireless ADB |
Input Injection
Tool | Description |
| Tap at x,y coordinates |
| Swipe from point A to B with duration |
| Send key event (BACK, HOME, POWER, etc.) |
| Type text string on device |
| Long press at coordinates |
Screen & Display
Tool | Description |
| Capture screenshot and save locally |
| Turn screen on/off/toggle |
| Get/set device rotation |
| Record screen to mp4 file |
App Management
Tool | Description |
| List installed packages |
| Launch app by package name |
| Force stop an app |
| Install APK file |
Clipboard
Tool | Description |
| Read device clipboard |
| Set device clipboard text |
File Transfer
Tool | Description |
| Push local file to device |
| Pull file from device |
Scrcpy Sessions
Tool | Description |
| Start scrcpy mirroring with full options |
| Stop a running scrcpy session |
Multi-device Support
All tools accept an optional serial parameter. If omitted, adb uses the only connected device (or fails if multiple are connected).
tap(x=500, y=1000, serial="ABCD1234")Environment Variables
Variable | Purpose | Default |
| Absolute path to |
|
| Absolute path to |
|
These are set automatically by install.sh via the MCP config env block.
Verify
python3 scrcpy_mcp.py # starts on stdio
python3 -c "from scrcpy_mcp import mcp; print(len(mcp._tool_manager._tools))" # should print 22This server cannot be deployed
Maintenance
Related MCP Connectors
Control Android TV from any AI. 38 MCP tools: playback, recap, recommend, smart-home, schedules.
Give your AI agent a real cloud Android phone: push APKs, drive it, get screenshots and logs.
Cloud Android phones for AI agents: create a phone, read the screen, tap, type, install APKs, park.
214 tools for AI agents over one MCP endpoint: image, video, audio, 3D, data, storage, mail, GPUs.
Related MCP Servers
- AlicenseBqualityCmaintenanceA comprehensive MCP server that enables AI agents to interact with Android devices through Android Debug Bridge (ADB), offering 198 tools for device control, app management, diagnostics, and more.10081 npm20Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables MCP-compatible agents to control an Android device over the network via ADB, providing tools for shell commands, screen capture, UI inspection, file operations, and input simulation.20 npmMIT
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to control Android devices via ADB, providing tools for screen capture, tap/swipe/input, app management, and diagnostics. Works locally over USB or WiFi and integrates with MCP clients like Claude and Cursor.1MIT
- AlicenseNot gradedqualityAmaintenanceEnables MCP-compatible AI assistants to see and control Android devices via ADB and scrcpy, exposing 44 tools for screenshots, taps, swipes, typing, UI element discovery, app management, file transfer, clipboard, shell commands, and audio/video streaming. Uses scrcpy's binary control protocol for fast input and near-instant screenshots, with an ADB fallback when no scrcpy session is active.365 npmMIT