home / mcp / appium mcp server

Appium MCP Server

MCP Appium provides cross-platform mobile automation with intelligent locators, session management, and test generation.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "appium-appium-mcp": {
      "command": "npx",
      "args": [
        "appium-mcp@latest"
      ],
      "env": {
        "ANDROID_HOME": "/path/to/android/sdk",
        "CAPABILITIES_CONFIG": "/path/to/your/capabilities.json"
      }
    }
  }
}

MCP Appium is a server that lets you automate mobile testing with natural language prompts, intelligent element locating, session management, and automated test generation for Android and iOS. It unifies device interaction and test creation so you can build robust mobile automation workflows quickly across real devices, emulators, and simulators.

How to use

Start by launching the MCP Appium server through your MCP client. Create or attach to a session for the target device and platform (Android or iOS). Use the available tools to find elements, interact with them, capture screenshots, and navigate through screens. When you describe a mobile test scenario in natural language, MCP Appium can generate locator strategies, produce automated test code, and document your flow. You can also generate locators for all interactive elements on a screen and generate TestNG-compatible Java tests from your descriptions. Manage multiple sessions or contexts as needed, and use the platform-specific tools to boot simulators, install apps, or switch contexts between native and web views.

How to use with a client workflow

1. Ensure prerequisites are met (Node.js, JDK, Android SDK, Xcode for iOS, and any required devices or simulators). 2. Start MCP Appium via your MCP client configuration. 3. Create a session for the device you want to automate. 4. Use element discovery tools to locate UI elements and perform actions like clicks, text entry, or scrolling. 5. Generate automated tests from natural language scenarios and export them in your preferred language and framework. 6. Take screenshots, obtain page sources, and manage contexts to support hybrid app testing.

Workflow patterns

- Begin with platform selection to ensure you target Android or iOS. - Create a session to establish a live automation context on a device or simulator. - Use locator generation to obtain robust selectors that adapt to UI changes. - Generate tests automatically from descriptive scenarios and integrate them into your test suite. - Use page object templates to organize your interactions and maintain test code.

Available tools

select_platform

REQUIRED FIRST: Ask user to choose between Android or iOS platform

select_device

Select a specific device when multiple devices are available

boot_simulator

Boot an iOS simulator and wait for it to be ready (iOS only)

setup_wda

Download and setup prebuilt WebDriverAgent for iOS simulators (iOS only)

install_wda

Install and launch WebDriverAgent on a booted iOS simulator (iOS only)

create_session

Create a new mobile automation session for Android or iOS

delete_session

Delete the current mobile session and clean up resources

appium_get_contexts

Get all available contexts in the current Appium session, including NATIVE_APP and WEBVIEW contexts

appium_switch_context

Switch to a specific context in the Appium session, e.g., NATIVE_APP or WEBVIEW_ contexts

appium_find_element

Find an element using locator strategies such as xpath, id, accessibility id, etc.

appium_click

Click on a targeted element

appium_double_tap

Perform a double tap on an element

appium_set_value

Enter text into an input field

appium_get_text

Retrieve text content from an element

appium_screenshot

Capture a screenshot and save as PNG

appium_scroll

Scroll the screen vertically (up or down)

appium_scroll_to_element

Scroll until a specific element becomes visible

appium_swipe

Swipe the screen in a direction or between coordinates

appium_get_page_source

Obtain the page source (XML) of the current screen

appium_activate_app

Activate (launch/bring to foreground) an app by bundle ID

appium_installApp

Install an app on the device from a file path

appium_uninstallApp

Uninstall an app from the device by bundle ID

appium_terminateApp

Terminate (close) a specified app

appium_list_apps

List all installed apps on the device (Android only)

generate_locators

Generate intelligent locators for all interactive elements on the current screen

appium_generate_tests

Generate automated test code from natural language scenarios

appium_documentation_query

Query Appium documentation using RAG for help and guidance