windows-computer-use-mcp

windows-computer-use-mcp

Enables Claude to fully control a Windows desktop with native screen capture, low-level input injection, game-grade input, and play-testing capabilities.

Category
访问服务器

README

windows-computer-use-mcp

<p align="center"> <img src="docs/unreal-playtest.gif" width="820" alt="Claude play-testing an Unreal Engine project — entering Play-In-Editor and running up a ramp, driven through the MCP, with the full editor (toolbar, viewport, Outliner) visible the whole time"> </p>

<p align="center"><em>Claude play-testing a live <strong>Unreal Engine</strong> project — entering Play-In-Editor and running up a ramp, driven entirely through this MCP. The full editor stays on screen, so you can see it really is the desktop app.</em></p>

<details> <summary><strong>How that clip was made</strong> — one <code>play</code> call</summary>

A timed input script run at a cadence while the window is recorded (mouse-look is relative, keys are hardware scan codes, so the game responds). The raw input was exactly:

play(
    target="window:MyProject - Unreal Editor",
    script="""
        lmb 557 460
        wait 0.4
        look 150 0
        wait 0.15
        look 150 0
        wait 0.2
        down w
        wait 1.7
        tap space
        wait 0.7
        up w
        wait 0.4
    """,
)

That is: click the viewport to capture the mouse (lmb), turn to face the ramp (look, relative pixels), run forward up it (down wup w), and jump at the top (tap space).

</details>

A Model Context Protocol server that gives a Claude agent full control of the local Windows desktop — native screen capture, low-level input injection, video recording, and a play-test loop for driving games and apps.

Unlike Anthropic's sandboxed computer-use tool, this runs on the machine it controls: it reads the actual current displays (no resolution requests), is multi-monitor and per-monitor DPI aware, and injects input via SendInput scan codes so it works in games that ignore synthetic virtual-key events. Built for full Claude control — no security gating.

Why this exists

Anthropic's official computer use in the Claude Code CLI is a macOS-only research preview — Pro/Max only, interactive sessions only (not available with the -p flag). The cross-platform alternative is the Claude Desktop app. There is no official, non-Desktop computer-use for Windows: nothing you can drive headlessly from claude -p, from the API, or wire into an agent over MCP.

This server fills that gap. It's a standard MCP server, so it works on Windows in Claude Code (interactive and -p), in Claude Desktop, or from any MCP client / custom agent — with no plan gating — and it's tuned for what a Windows agent actually needs that the sandboxed cloud tool can't do: real multi-monitor capture, per-window GPU capture, game-grade input, and play-testing.

Tools

Tool What it does
screenshot See the screen: whole desktop, a display:N, a window (even occluded/DirectX via PrintWindow), or a region. Downscaled inline image + a coordinate frame for clicks.
act Do input, batched: left_click, type, key, scroll, drag, hold_key, paste, click_element (UIA, no pixels), mouse_move_relative (game look), … Coordinates are in the last screenshot's image space; the server maps them to physical pixels.
record Record N seconds → a single timestamped frame montage (not N images) + an mp4. Judge motion/animation/stutter.
play Drive a timed input script at a cadence while recording (scan codes + relative mouse). probe/until read telemetry per sample and stop early — the closed loop for play-testing.
window Find / focus / close / read (get_text via UI Automation + OCR) / click_element controls with no screenshot — token-cheap.
process Launch (incl. shell:true for URLs / ms-settings: / Store apps), kill, wait, run a shell command (real stdout), and wait on readiness (wait_for_window, wait_for_file).
system Monitor layout + DPI/scale, cursor position, clipboard get/set, and viewport management.

Coordinates & multi-monitor

Coordinates are physical pixels in virtual-desktop space (primary monitor's top-left is (0,0); monitors to the left/above are negative). You click in the image space of the last screenshot; the server maps that back to physical pixels (handling downscale, per-monitor offset, and DPI). Every screenshot returns a capture_id; act errors loudly if you click against a stale frame instead of mis-clicking. Use system displays to see the layout, then target a specific monitor with display:0 / display:primary|left|right.

Install

As a Claude Code / Desktop plugin (recommended)

/plugin marketplace add sshh12/claude-plugins
/plugin install windows-computer-use@shrivu-plugins

The plugin bootstraps a Python virtual environment and installs this package from GitHub on first run, then starts the MCP server automatically.

Standalone (project-local MCP)

Requires Python 3.10+ and (for video) ffmpeg on PATH.

pip install git+https://github.com/sshh12/windows-computer-use-mcp

Then add to your MCP client config (e.g. a project .mcp.json):

{
  "mcpServers": {
    "windows-computer-use": {
      "command": "python",
      "args": ["-m", "windows_computer_use"]
    }
  }
}

Development

python -m venv .venv
.venv\Scripts\python.exe -m pip install -e .
.venv\Scripts\python.exe tests\smoke_engine.py    # capture/input/display engine
.venv\Scripts\python.exe tests\smoke_server.py     # assembled MCP tool surface

MCP_OUTPUT_DIR overrides where screenshots/video are written (default: a client root → ~/Pictures/windows-computer-use%TEMP%).

Debugging

Set WCU_DEBUG_HTML_DIR to a directory and the server writes a per-session session_<stamp>.html that pretty-prints every tool call — arguments, result text, and the returned screenshots inline — so you can replay exactly what the agent saw and did:

<img src="https://github.com/user-attachments/assets/4395906b-cfe2-4e25-b560-261a9ebc782d" width="820" alt="Per-session debug HTML dump showing tool calls, arguments, results, and inline screenshots">

License

MIT

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选