# ios-simulator-mcp

> MCP Server

This repository provides an MCP server for interacting with iOS simulators, enabling UI element inspection, UI interaction control, and screenshot capture. It facilitates QA processes by automating UI validation and documentation.

## Overview

- **Category:** Developer Tools
- **Language:** JavaScript
- **Stars:** 2136
- **Forks:** 3
- **Owner:** joshuayoes
- **GitHub:** https://github.com/joshuayoes/ios-simulator-mcp
- **Created:** 2025-03-20T02:39:27+00:00
- **Updated:** 2025-03-28T22:28:21+00:00
- **Source:** https://model-context-protocol.com/servers/ios-simulator-interaction-control-qa-automation

## Setup

## Setup

**Prerequisites:**
- Node.js
- macOS (as iOS simulators are only available on macOS)
- [Xcode](https://developer.apple.com/xcode/resources/) and iOS simulators installed
- Facebook [IDB](https://fbidb.io/) tool [(see install guide)](https://fbidb.io/docs/installation)

**Option 1: Using NPX (Recommended)**
1. Edit your Cursor MCP configuration:
   ```bash
   cursor ~/.cursor/mcp.json
   ```
2. Add the iOS simulator server to your configuration:
   ```json
   {
     "mcpServers": {
       "ios-simulator": {
         "command": "npx",
         "args": ["-y", "ios-simulator-mcp"]
       }
     }
   }
   ```
3. Restart Cursor.

**Option 2: Local Development**
1. Clone this repository:
   ```bash
   git clone https://github.com/joshuayoes/ios-simulator-mcp
   cd ios-simulator-mcp
   ```
2. Install dependencies:
   ```bash
   npm install
   ```
3. Build the project:
   ```bash
   npm run build
   ```
4. Edit your Cursor MCP configuration:
   ```bash
   cursor ~/.cursor/mcp.json
   ```
5. Add the iOS simulator server to your configuration:
   ```json
   {
     "mcpServers": {
       "ios-simulator": {
         "command": "node",
         "args": ["/path/to/your/ios-simulator-mcp/build/index.js"]
       }
     }
   }
   ```
   Replace `"/path/to/your"` with the actual path to your project directory.
6. Restart Cursor.

## Tools

## Available Tools

1. Get the ID of the currently booted iOS simulator (Retrieves the simulator's identifier).
2. Describe all accessibility elements on screen (Provides a description of all accessible UI elements).
3. Tap on screen coordinates (Simulates a tap at specified coordinates).
4. Input text (Enters text into a text input field).
5. Swipe between coordinates (Simulates a swipe gesture between two points).
6. Get information about UI elements at specific coordinates (Retrieves details about a UI element at a given location).
7. Take screenshots of the simulator screen (Captures the current screen of the simulator).

