31 tools for Android devices.
MCP Scrcpy provides 31 tools. The small helper it runs on the device is built from the scrcpy project's server. Tools that act on one device accept deviceSerial; leave it out only when exactly one device is connected, or, for control tools, to use the device your session has adopted. Coordinates are device pixels, not screenshot pixels.
List devices and take control of one.
| Tool | Use it to | Parameters |
|---|---|---|
list_devices | List the Android devices and emulators ADB can see, each with its state, model and identifier. Start here to find the serial you pass to the other tools. | none |
scrcpy_wireless_devices | List only the devices connected over Wi-Fi, leaving out emulators. Pairing a device is done with ADB, not with this tool. | none |
scrcpy_adopt | Claim a device so this session can control it. It fails if the device is not connected or another session already holds it: a session controls one device, and a device has one controller. | deviceSerial (optional) |
scrcpy_unadopt | Release your claim on a device so another session can control it. | deviceSerial (optional) |
Why: control needs a claim, so two agents cannot tap the same screen at once. Watching does not: screenshots, recording, the log and the device lists work without adopting. Ending the session releases the claim, and so does 30 minutes without use.
Screenshots and recordings.
| Tool | Use it to | Parameters |
|---|---|---|
scrcpy_screenshot | Capture the device screen as a PNG. You get the model and picture size, the saved file's details and, if you ask, the picture itself in the reply. It needs the video decoder. | deviceSerial, filename, inlineImage (default false), all optional |
scrcpy_record_start | Start recording the screen to a file. A plain recording is an MP4 that includes the device's playback sound when it can be captured; the condensed option gives a VP9 WebM video of the same length instead, with repeated frames skipped, and needs the video decoder. | deviceSerial, filename, maxDurationSecs, audio (default true), condense (must be {}), all optional |
scrcpy_record_stop | Stop the recording and collect the file. Call it even after the time limit has passed, because that is what publishes the file and frees the recording slot. | deviceSerial (required when several recordings run) |
Why: look, act, look again. The picture is scaled so its longer side is at most 1920 pixels. Choose a unique filename for each recording, because an unnamed one is replaced by the next recording of the same device. Rotating the device during a recording ends the capture at that point.
Act on the screen.
| Tool | Use it to | Parameters |
|---|---|---|
scrcpy_tap | Tap a point on the screen, given in device pixels. | x, y (required) |
scrcpy_swipe | Swipe from one point to another, for example to scroll a list or turn a page. | x1, y1, x2, y2 (required), durationMs (default 300) |
scrcpy_long_press | Press and hold a point, for example to open a context menu or start a drag. | x, y (required), durationMs (default 600) |
scrcpy_scroll | Scroll with a mouse wheel at a point. A positive vertical value scrolls up. | x, y, v (required), h (optional), in wheel ticks |
scrcpy_pinch | Zoom in or out with two fingers around a point. The fingers sit on a horizontal line through that point. | x, y, span0, span1 (required), durationMs (default 400) |
scrcpy_key | Press a hardware or navigation key, such as back, home, recents, power, the volume keys, enter, delete or tab, or any numeric Android key code. | key (required: back, home, recents, power, volume_up, volume_down, enter, del, tab or a numeric key code) |
scrcpy_text | Type text into the focused field. It works by setting the clipboard and pasting, so the field must accept paste, and it replaces what was on the clipboard. The text is limited to 300 bytes. | text (required) |
scrcpy_clipboard_get | Read the text on the device clipboard. | none |
scrcpy_clipboard_set | Set the device clipboard, and optionally paste it at once. It takes much longer text than typing does. | text (required, up to 262130 bytes), paste (default false) |
Why: a sent answer means the device accepted the event, not that the app reacted. Take a screenshot after each action that matters. durationMs is a whole number of at least 1.
Install, open, read and remove.
| Tool | Use it to | Parameters |
|---|---|---|
scrcpy_install_apk | Install an Android app package. The path is read on the machine that runs the server, not on your client's machine, and an install that clashes with the signature of an installed copy is refused. | apkPath (required) |
scrcpy_uninstall_apk | Remove an installed app by its package name. | package (required) |
scrcpy_start_app | Open an app by its package name, on its launcher screen. | package (required) |
scrcpy_scan_file | Make a file you copied to the device visible to gallery and media apps. | path (required, absolute on the device) |
scrcpy_logcat_tail | Read the most recent device log lines, optionally for one tag. It works without claiming the device first. | lines (1 to 400, default 80), tag (optional) |
Rotation, display, panels and power.
| Tool | Use it to | Parameters |
|---|---|---|
scrcpy_rotate | Toggle between portrait and landscape. It turns automatic rotation off and locks the chosen orientation, so restore it yourself afterwards. | none |
scrcpy_screen_on / scrcpy_screen_off | Turn the display on or off. A screenshot of a display that is off can time out, so turn it on first. | none |
scrcpy_expand_notifications | Pull down the notification panel so you can read or act on notifications. | none |
scrcpy_expand_settings | Pull down the quick settings panel. | none |
scrcpy_collapse_panels | Close the notification or quick settings panel that is open. | none |
scrcpy_open_hard_keyboard_settings | Open the physical-keyboard settings screen on the device. | none |
scrcpy_reset_video | Ask the device for a fresh video frame when a capture looks frozen or corrupted. | none |
scrcpy_reboot | Reboot the device. It drops out of the device list until it has booted again. | none |
scrcpy_poweroff | Power the device off. It stays off until someone turns it on, so use it only where you can reach the device. | none |
Why: these change settings that outlast the session, and releasing the claim does not undo them. Put the rotation, the display and the panels back before you release the device.
What to expect when a call fails.
A tool failure comes back as a tool error with a message, not as a protocol error. The limits that matter:
| Limit | Value |
|---|---|
| Install, reboot, power-off and recording start | 5 calls a minute each |
| Every other scrcpy tool | 30 calls a minute together |
| One call | 60 seconds; a timeout does not prove the device work stopped |
| Control | one device per session and one session per device; released after 30 minutes unused |
| Typing | 300 bytes with scrcpy_text; 262130 bytes with scrcpy_clipboard_set |
| Pictures and video | scaled so the longer side is at most 1920 pixels |
| Access | whoever can open the server's socket can use every tool on every device your ADB sees; keep the socket in a private directory |
Screenshots are stored under your cache folder by session and device model and stay until you delete them. See Troubleshooting and the configuration reference.