# scrcpy-mcp

Connects an AI agent to an Android device through ADB and scrcpy, so it can inspect the screen and perform actions. Handy for checking an app directly on a device.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 124
- Author: JuanCF
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/JuanCF/scrcpy-mcp
- Updated: 2026-09-23
- HTML: https://affpapa.org/en/nevibecode/mcp/scrcpy-mcp

## What it does

The server lets an agent view the device screen, tap and swipe, enter text, launch apps, locate UI elements, move files, and run shell commands. Screenshots arrive as images, and element lookup can provide coordinates for a tap. Tools also cover clipboard access, video, and audio.

You need Node.js 24+, ADB, and an Android device with USB debugging enabled. scrcpy speeds up interaction, while basic controls can fall back to ADB at a slower pace. Video and audio streaming require scrcpy. Audio capture is opt-in and needs Android 11 or later; without USB debugging, the device cannot connect.

For Claude Code, register the server with `claude mcp add scrcpy-mcp -- npx -y scrcpy-mcp`. An alternate install command accepts environment variables for selecting a device and setting custom ADB or scrcpy paths.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `ANDROID_SERIAL`, `ADB_PATH`, `SCRCPY_SERVER_PATH` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env ANDROID_SERIAL=<ANDROID_SERIAL> --env ADB_PATH=<ADB_PATH> --env SCRCPY_SERVER_PATH=<SCRCPY_SERVER_PATH> --transport stdio scrcpy-mcp -- npx -y scrcpy-mcp
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add scrcpy-mcp --env ANDROID_SERIAL=<ANDROID_SERIAL> --env ADB_PATH=<ADB_PATH> --env SCRCPY_SERVER_PATH=<SCRCPY_SERVER_PATH> -- npx -y scrcpy-mcp
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "scrcpy-mcp": {
            "command": "npx",
            "args": [
                "-y",
                "scrcpy-mcp"
            ],
            "env": {
                "ANDROID_SERIAL": "<ANDROID_SERIAL>",
                "ADB_PATH": "<ADB_PATH>",
                "SCRCPY_SERVER_PATH": "<SCRCPY_SERVER_PATH>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "scrcpy-mcp": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "scrcpy-mcp"
            ],
            "env": {
                "ANDROID_SERIAL": "<ANDROID_SERIAL>",
                "ADB_PATH": "<ADB_PATH>",
                "SCRCPY_SERVER_PATH": "<SCRCPY_SERVER_PATH>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e ANDROID_SERIAL=<ANDROID_SERIAL> -e ADB_PATH=<ADB_PATH> -e SCRCPY_SERVER_PATH=<SCRCPY_SERVER_PATH> scrcpy-mcp npx -y scrcpy-mcp
```
Replace <…> with your own values

## When to use it
- inspect an Android device screen from an agent
- tap a UI element using its screen coordinates
- launch an app and enter text
- move files between a device and a computer
- stream or record audio from a device

## Example prompts
- Inspect the connected Android screen and describe what is open.
- Open the app and tap its sign-in button.
- Find the search field on screen and enter the app name.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [World Monitor](https://affpapa.org/en/nevibecode/mcp/world-monitor.md) — MCP server · ★ 89408
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [Front-End Checklist](https://affpapa.org/en/nevibecode/mcp/front-end-checklist.md) — MCP server · ★ 74559
- [Scrapling MCP Server](https://affpapa.org/en/nevibecode/mcp/scrapling-mcp-server.md) — MCP server · ★ 89433

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
