cua-local
Provides tools to control a local macOS computer, including reading app/screen state, mouse movement, clicking, typing, scrolling, dragging, pressing keys, and opening URLs.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@cua-local open Safari, navigate to google.com, and type 'weather today'"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
cua-local
Use ChatGPT with MCP to control your local Mac, similar to Computer Use.
cua-local is a small local bridge that lets ChatGPT, or another MCP-compatible AI client, observe and operate your own Mac in a controlled loop:
observe -> act -> observeIt can expose basic tools for reading app/screen state, moving the mouse, clicking, typing, scrolling, dragging, pressing keys, and opening URLs. Everything runs locally on macOS, while the AI assistant connects through MCP.
How it works
cua-local uses native macOS capabilities:
AppleScript / Apple Events for app control
System Events for keyboard input
screencapturefor screen observationSwift + CGEvent for mouse movement, clicks, scroll, and drag
In other words: it gives ChatGPT a local Computer Use-like control layer for your Mac through MCP. It is inspired by the Computer Use idea, but it is not an official Computer Use client and not a full desktop automation product.
Related MCP server: macos-mcp
Quick start
Requirements:
macOS
Node.js >= 20
Xcode Command Line ToolsRun:
npm run doctor
npm run check
npm run smoke
npm run demonpm run doctor prints a ready-to-copy MCP config for the current checkout.
Does it require DevSpace?
No. cua-local itself is just a local MCP server and can run on its own.
DevSpace is only one possible bridge when you want to call this local MCP server from ChatGPT. If your AI client can launch local MCP servers directly, you do not need DevSpace. If the client runs in the cloud and cannot directly reach your Mac, you need some bridge such as DevSpace, a tunnel, or another remote MCP connection layer.
Typical setups:
Local MCP client -> cua-local -> your Mac
ChatGPT -> DevSpace/tunnel/bridge -> cua-local -> your MacMCP config
Use absolute paths on the target machine:
{
"mcpServers": {
"computer-use-local": {
"command": "node",
"args": ["/ABSOLUTE/PATH/TO/cua-local/cua-local.mjs"],
"cwd": "/ABSOLUTE/PATH/TO/cua-local"
}
}
}Scripts
npm run start # start MCP server over stdio
npm run doctor # check dependencies and macOS permissions
npm run check # syntax-check project scripts
npm run smoke # lightweight core validation
npm run demo # safe observe -> move pointer -> observe sampleTools
list_appsget_app_stateget_screen_statehealth_checkopen_urltype_textpress_keymove_mouseclickscrolldragset_value
Safety
This tool can operate the local computer. Only connect it to MCP hosts you trust.
click blocks common high-risk labels such as Buy, Purchase, Pay, Delete, Remove, Send, Submit, Publish, Share, Update, and Install unless confirm_risk_action=true is explicitly provided.
Do not expose this server to the public internet.
Local files not to commit
cua-local.mcp.json
.env
traces/
/tmp/cua-local-*
~/.cua-local/Limitations
Native app support is partial and app-specific.
Chrome webpage DOM exposure is limited by macOS Accessibility.
Multi-display screenshot stitching still needs hardening.
Trace writing is opt-in via
CUA_LOCAL_TRACE=1orCUA_LOCAL_TRACE_DIR=....
License
MIT. See LICENSE.
Available Tools
12 toolsclickA
Click screen coordinates or an accessibility element center using CGEvent. Use element_index from get_app_state when possible.
Inputs: app (required), x, y, click_count, +4 more.
dragC
Drag from one screen coordinate to another using CGEvent.
Inputs: app (required), to_x (required), to_y (required), from_x (required), +1 more.
get_app_stateB
Get the app state: front window info, Chrome title/url when available, lightweight accessibility tree, and optional screenshot.
Inputs: app (required), include_screenshot.
get_screen_stateA
Return display, screenshot, mouse, Retina scale, and coordinate-space diagnostics for calibration.
Inputs: no named parameters.
health_checkB
Return server version, dependency, permission, log, and optional screen diagnostics.
Inputs: include_logs, include_screen.
list_appsA
List running GUI apps on this Mac. Local adapter; no Codex login required.
Inputs: no named parameters.
move_mouseB
Move the visible mouse pointer to screen coordinates or an accessibility element center without clicking.
Inputs: app (required), x, y, display_index, +2 more.
open_urlC
Open an http(s) URL in Google Chrome. Local helper for browser smoke tests.
Inputs: app (required), url (required).
press_keyB
Press a key or key-combination. Examples: Return, Tab, cmd+l, command+r, shift+cmd+r.
Inputs: app (required), key (required).
scrollC
Scroll the active app by pages in a direction.
Inputs: app (required), direction (required), pages, element_index.
set_valueC
Set value for a focused or known field. For Chrome, element_index="address_bar" sets the address bar.
Inputs: app (required), value (required), element_index (required).
type_textB
Type literal text into the active app using macOS System Events.
Inputs: app (required), text (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 12 tools
Tools are mostly distinct, with mouse actions (click, drag, move_mouse) clearly separated. Potential confusion between set_value and type_text is mitigated by descriptions.
All tool names follow a consistent verb_noun snake_case pattern, with clear verb choices like get_, list_, open_, press_, etc.
12 tools is well-scoped for a local GUI automation server, covering mouse, keyboard, app state, and device diagnostics without excess.
Core interactions (click, type, scroll, open URL) are covered. Minor gaps like window management exist, but the set is functional for typical workflows.
Maintenance
Related MCP Connectors
Human-input bridge for AI agents with voice-first answer links, MCP tools, and HTTP APIs.
MCP connector that lets ChatGPT list, search, and run your Apple Shortcuts via a local Mac agent
Web scraping, browser automation, screenshots and AI data extraction for AI agents via MCP.
Connect AI assistants to your approved computer for files, commands, browser and desktop tasks.
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceAn experimental MCP server providing full control over the macOS user interface through mouse, keyboard, and window management tools. It enables AI assistants to automate desktop tasks by utilizing native accessibility APIs and OCR for real-time screen comprehension.7Creative Commons Zero v1.0 Universal
- AlicenseNot gradedqualityAmaintenanceA lightweight MCP server that bridges AI agents and macOS, enabling automation of file navigation, application control, UI interaction, browser automation, and system operations.244MIT
- AlicenseNot gradedqualityDmaintenanceStandalone MCP server that gives AI agents full GUI control over macOS — screenshots, mouse, keyboard, apps, clipboard, and multi-display — with zero private dependencies.20MIT
- AlicenseBqualityDmaintenanceMCP server that enables AI to fully control macOS — mouse, keyboard, terminal, screenshots, window management, UI element detection, and provides AI-optimized information reporting.36MIT