Skip to main content
Glama

android-emulator-mcp

An MCP (Model Context Protocol) server that lets AI agents control the Android Emulator — boot AVDs, install apps, interact with UI, take screenshots, read logs, and more. Companion to ios-simulator-mcp.

Everything is driven by adb and the emulator binary — no extra daemons needed.

Prerequisites

  • Android SDK with platform-tools (adb) and emulator installed (e.g. via Android Studio)

  • ANDROID_HOME or ANDROID_SDK_ROOT set, or the SDK at ~/Library/Android/sdk

  • Node.js 18+

Related MCP server: Android DevTools MCP

Installation

git clone https://github.com/Sajinthan/android-emulator-mcp
cd android-emulator-mcp
pnpm install
pnpm build

Connect to Claude Code / Claude Desktop / Kiro

claude mcp add --scope user android-emulator node /absolute/path/to/android-emulator-mcp/dist/index.js

Or add to your MCP config JSON:

{
  "mcpServers": {
    "android-emulator": {
      "command": "node",
      "args": ["/absolute/path/to/android-emulator-mcp/dist/index.js"]
    }
  }
}

Tools

The serial parameter (e.g. emulator-5554) is optional on every tool when exactly one device is connected.

Emulator Control

Tool

Description

list_emulators

List AVDs, running emulators and connected devices

boot_emulator

Boot an AVD by name and wait for boot to complete

shutdown_emulator

Shut down a running emulator

get_booted_serial

Get serials of connected devices

get_screen_info

Screen size (px), density and rotation

App Management

Tool

Description

install_app

Install an .apk (grants runtime permissions)

uninstall_app

Uninstall by package name

list_apps

List installed packages

launch_app

Launch by package name (or a specific activity)

terminate_app

Force-stop an app

clear_app_data

Wipe app data and permissions

grant_permission

Grant a runtime permission

UI Interaction

Tool

Description

tap

Tap at x,y pixels

long_press

Long-press at x,y

swipe

Swipe between two points

type_text

Type into the focused input

press_button

HOME, BACK, MENU, APP_SWITCH, POWER, VOLUME_UP/DOWN, ENTER, DEL, TAB, CAMERA, SEARCH

key_event

Send any Android keycode

describe_ui

Compact JSON UI hierarchy (one element per line) with bounds and tap centers

find_element

Find elements by text / content-desc / resource-id

wait_for_element

Poll until an element appears or disappears

shake

Shake the device (accelerometer, e.g. RN dev menu)

set_orientation

Rotate to portrait / landscape

set_appearance

Light / dark mode

Media & Location

Tool

Description

screenshot

Save a PNG and return it inline (downscaled)

record_video

Start screen recording (max 3 min)

stop_recording

Stop recording and pull the .mp4

add_media

Push a photo/video into the media library

open_url

Open a URL or deep link

set_location

Set simulated GPS coordinates

Status Bar (SystemUI demo mode)

Tool

Description

set_status_bar

Override time, battery, wifi, notifications

clear_status_bar

Exit demo mode

Logs

Tool

Description

logcat

Recent logcat, filterable by regex or package

clear_logcat

Clear the logcat buffer

Files & Escape Hatch

Tool

Description

push_file

Copy a local file to the device

pull_file

Copy a file from the device

adb_shell

Run any adb shell command

Notes

  • boot_emulator returns the existing serial if that AVD is already running instead of starting a second copy.

  • type_text is limited to printable ASCII, a limitation of adb shell input text.

  • Read-only tools carry the MCP readOnlyHint annotation and destructive ones destructiveHint, so clients can prompt accordingly.

Coordinate System

Unlike iOS, Android's adb input uses physical pixels, which is the same space as screenshots and describe_ui bounds — no scaling needed. The screenshot tool returns a downscaled inline image to save context; its text response states the scale factor if you want to map inline coordinates back to device pixels. Prefer describe_ui / find_element for exact tap targets.

Available Tools

37 tools
adb_shellA

Run an arbitrary adb shell command for anything not covered by the other tools, e.g. 'dumpsys activity activities | head -50'

Inputs: command (required), serial.

add_mediaB

Add a photo or video to the device's media library (Photos/Gallery)

Inputs: file_path (required), serial.

boot_emulatorA

Boot an Android emulator by AVD name and wait until it has finished booting. Returns the device serial.

Inputs: avd (required), wipe_data, timeout_seconds.

clear_app_dataA
Destructive

Clear all data and permissions for an app (like a fresh install)

Inputs: package (required), serial.

clear_logcatC

Clear the logcat buffer

Inputs: serial.

clear_status_barA

Exit demo mode and restore the real status bar

Inputs: serial.

describe_uiA
Read-only

Get the UI hierarchy of the current screen as a compact JSON list with text, content descriptions, resource IDs, bounds and tap centers (pixels). By default only elements with text/desc or that are interactive are returned.

Inputs: serial, raw_xml, include_all.

find_elementA
Read-only

Find UI elements whose text, content description or resource ID contains the given string (case-insensitive). Returns bounds and tap centers.

Inputs: query (required), serial.

get_booted_serialA
Read-only

Get the serial(s) of currently connected devices/emulators

Inputs: no named parameters.

get_screen_infoA
Read-only

Get the screen size (pixels) and density. Screenshots, tap coordinates and describe_ui bounds all share this same pixel coordinate space — no scaling needed.

Inputs: serial.

grant_permissionA

Grant a runtime permission to an app (e.g. android.permission.CAMERA)

Inputs: package (required), permission (required), serial.

install_appB

Install an .apk on the device

Inputs: apk_path (required), serial.

key_eventA

Send any Android keycode (e.g. KEYCODE_ESCAPE, 66) — for keys not covered by press_button

Inputs: keycode (required), serial.

launch_appA

Launch an app by package name (uses its main launcher activity), or a specific activity

Inputs: package (required), serial, activity.

list_appsA
Read-only

List installed packages (third-party only by default)

Inputs: serial, include_system.

list_emulatorsA
Read-only

List available Android Virtual Devices (AVDs) and currently connected devices/emulators

Inputs: no named parameters.

logcatA
Read-only

Read recent logcat output, optionally filtered by a regex or restricted to one app's process

Inputs: lines, filter, serial, package.

long_pressC

Long-press at x,y pixel coordinates

Inputs: x (required), y (required), serial, duration_ms.

open_urlC

Open a URL or deep link in the device

Inputs: url (required), serial.

press_buttonB

Press a hardware/navigation button (HOME, BACK, MENU, APP_SWITCH, POWER, VOLUME_UP, VOLUME_DOWN, ENTER, DEL, TAB, CAMERA, SEARCH)

Inputs: button (required), serial.

pull_fileB

Copy a file from the device to the local machine

Inputs: local_path (required), remote_path (required), serial.

push_fileA

Copy a local file to the device

Inputs: local_path (required), remote_path (required), serial.

record_videoA

Start recording the device screen (max 3 minutes per recording). Call stop_recording to finish and pull the .mp4.

Inputs: serial, output_path.

screenshotA
Read-only

Take a screenshot of the device screen. Saves a full-resolution PNG and returns a downscaled copy inline (the text notes the scale factor to map back to device pixels).

Inputs: serial, output_path, return_image, inline_max_px.

set_appearanceB

Switch the device between light and dark mode

Inputs: appearance (required), serial.

set_locationC

Set the simulated GPS location (emulator only)

Inputs: latitude (required), longitude (required), serial.

set_orientationC

Rotate the screen

Inputs: orientation (required), serial.

set_status_barC

Override the status bar via SystemUI demo mode (time, battery, wifi, notifications)

Inputs: time, serial, wifi_level, battery_level, +2 more.

shakeA

Shake the device (emulator only — simulates accelerometer motion, e.g. to open the React Native dev menu)

Inputs: serial.

shutdown_emulatorA

Shut down a running emulator

Inputs: serial.

stop_recordingA

Stop an active screen recording and save the video locally

Inputs: serial.

swipeB

Swipe from one point to another (pixels)

Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +2 more.

tapA

Tap at x,y pixel coordinates on the screen

Inputs: x (required), y (required), serial.

terminate_appC

Force-stop a running app

Inputs: package (required), serial.

type_textA

Type text into the currently focused input field (ASCII only — adb input text cannot type emoji or non-Latin characters)

Inputs: text (required), serial.

uninstall_appA
Destructive

Uninstall an app by package name

Inputs: package (required), serial.

wait_for_elementA
Read-only

Poll until an element matching the query appears (or disappears). Useful after navigation or network calls.

Inputs: query (required), gone, serial, timeout_seconds.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    B3.3/5.0

    Scored across 37 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose, from device control (orientation, location, appearance) to UI interaction (tap, swipe, type, find elements) to app management and file operations. Even closely related tools like press_button vs key_event are differentiated by scope (common navigation vs arbitrary keycodes).

    Naming Consistency4/5

    Most tools follow a verb_noun pattern (type_text, press_button, set_orientation, install_app), but a few exceptions like 'swipe', 'tap', 'shake', 'logcat', and 'key_event' break the strict consistency. Overall the naming is clear and readable, with only minor deviations.

    Tool Count3/5

    With 37 tools, this server is twice the typical upper bound of 15. While each tool serves a specific function for comprehensive emulator control, the sheer number feels heavy and could be consolidated (e.g., combining some status bar or UI query tools). Still, the scope justifies the count better than a generic utility server.

    Completeness5/5

    The toolset covers essentially all major aspects of Android emulator interaction: device control, UI automation, app lifecycle, file transfer, logging, screen capture, and emulator lifecycle management. No critical gaps are apparent for the intended domain.

    Maintenance

    ActivityStale
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      B
      quality
      D
      maintenance
      Enables AI assistants to interact with Android devices and emulators via ADB, providing tools for screenshots, UI inspection, touch and text input, app management, and device control.
      42
      143 npm
      23
      MIT
    • A
      license
      A
      quality
      D
      maintenance
      Enables an agent to inspect and interact with Android emulators or physical devices via ADB, capturing UI snapshots, tapping nodes, typing text, and reading app logs.
      10
      MIT
    • A
      license
      B
      quality
      C
      maintenance
      Enables AI agents to control Android TV/Android devices through ADB, including screen capture, remote control, app management, and more.
      24
      16 npm
      5
      MIT
    • A
      license
      A
      quality
      C
      maintenance
      Enables AI agents to control, inspect, and automate Android devices, Waydroid containers, and AVD emulators over ADB. Provides tools for screenshots, UI-hierarchy text-based tapping, gestures, key presses, text input, app management, and raw shell commands.
      12
      MIT