Noureddine RAMDI / native-devtools-mcp: cross-platform AI agent control of native apps with macOS accessibility precision

Created Sat, 23 May 2026 20:41:14 +0000 Modified Sat, 23 May 2026 20:41:27 +0000

sh3ll3x3c/native-devtools-mcp

native-devtools-mcp is a Rust project that provides a Model Context Protocol (MCP) server enabling AI agents to control native desktop applications and browsers across platforms. What sets it apart is its multi-modal approach to automation: it supports visual control through screenshots and OCR, accessibility API dispatch on macOS, and Chrome DevTools Protocol (CDP) for browser automation. This lets AI agents interact with native apps on macOS and Windows, control Chrome and Electron-based browsers, and manipulate Android devices via ADB, all through a unified interface.

Cross-platform native app and browser automation server

The core of native-devtools-mcp is an MCP server written in Rust that exposes three distinct automation strategies:

  • Visual approach: Captures universal screenshots, applies OCR to recognize screen elements, and performs clicks based on visual cues. This method works universally but is less precise.

  • AX dispatch (macOS only): Leverages the macOS Accessibility API to access the accessibility tree of native apps. This allows element-precise control, such as clicks, without moving the mouse cursor or stealing focus from the user. This is a rare and valuable feature for automation tools, enabling background interactions without interrupting user workflows.

  • CDP for Chrome/Electron: Uses the Chrome DevTools Protocol to drive browser automation at the DOM level, allowing fine-grained control over web pages inside Chrome or Electron apps.

Additionally, the server supports Android device control via ADB, integrated directly into the same MCP server.

The stack is Rust-based, which provides performance and safety benefits. The code accesses platform-specific native APIs — Core Graphics and Accessibility on macOS, Win32 and UI Automation on Windows — to control native GUI elements. This platform-aware design comes with tradeoffs: Linux is not supported due to lack of equivalent native APIs, and browser automation is limited to Chrome/Electron only.

The architecture aims to unify these diverse control mechanisms under the MCP protocol, so AI agents like Claude Code or Cursor can call structured commands with clear semantics rather than brittle script generation.

macOS Accessibility API integration: precise control without stealing focus

The standout technical feature is the macOS AX dispatch method. Most automation tools rely on moving the mouse or sending keyboard events, which steals focus and disrupts the user. By directly dispatching commands to accessibility elements, native-devtools-mcp achieves:

  • Element-precise clicks and interactions without moving the mouse cursor.
  • No stealing of window focus, allowing the user to continue working undisturbed.
  • Access to the accessibility tree, which provides a reliable and semantically rich view of UI elements.

This approach addresses a common pain point in desktop automation, especially for AI agents that need to interact with apps in the background or without interrupting the user.

From a code quality standpoint, the Rust implementation keeps platform-specific code cleanly separated and uses Rust’s strong typing and safety guarantees. The codebase is pragmatic rather than overly abstracted, focusing on practical interoperability with native APIs and MCP protocol exposure.

Tradeoffs include the limitation to macOS for this AX dispatch feature and the dependency on macOS security permissions (Accessibility and Screen Recording) which must be granted manually. Without these permissions, clicks silently fail and screenshots are black.

Quickstart with native-devtools-mcp

The project offers straightforward installation and startup on macOS and Windows:

npx -y native-devtools-mcp

Alternatively, you can install it globally via npm:

npm install -g native-devtools-mcp

For Rust enthusiasts or those wanting to build from source:

curl -fsSL https://raw.githubusercontent.com/sh3ll3x3c/native-devtools-mcp/master/scripts/build-from-source.sh | bash

Or manually:

git clone https://github.com/sh3ll3x3c/native-devtools-mcp
cd native-devtools-mcp
cargo build --release

Configuration for MCP clients like Claude Desktop involves setting the command to run the native-devtools-mcp executable or npx command with appropriate JSON config files on macOS and Windows.

A key practical note: on macOS, the server requires Accessibility and Screen Recording permissions. The setup wizard assists opening the right System Settings panes. Without these permissions, automation features are impaired.

verdict: a practical cross-platform MCP server for AI-driven native app control with macOS precision

native-devtools-mcp is a solid example of bridging AI agents with native desktop automation across platforms. Its use of Rust and native APIs gives it a performance and reliability edge over script-based or cloud-dependent solutions.

The macOS AX dispatch feature is the most technically interesting part, solving a real-world problem of background, precise UI control without interrupting users. The tradeoff is clear: if you need Linux support or iOS device control, this repo doesn’t cover that yet. Browser automation is Chrome/Electron specific, and Android control requires ADB.

This project is highly relevant for developers building AI tooling that needs to interact with native apps at a granular level, especially on macOS and Windows. The quickstart commands make it easy to try, but macOS users should be mindful of the required permissions.

While not perfect, native-devtools-mcp strikes a good balance between practical capabilities and technical depth, making it a useful tool in the emerging landscape of AI-driven desktop automation.


→ GitHub Repo: sh3ll3x3c/native-devtools-mcp ⭐ 103 · Rust