Skip to main content
Glama

rdp-mcp

An MCP server that lets Claude Code (or any MCP client) see and drive a Remote Desktop session on Linux, in a window you can watch and take over. RDP for Windows and Linux hosts, VNC for Macs and anything else.

Computer use for your other machines, from a Linux desktop:

  • You see everything. Each session is a real FreeRDP client in a window on your desktop. The pointer glides to where the model clicks.

  • You can take over. Use your own mouse and keyboard in the window at any time. The model is told when the pointer moved since its last action.

  • Shared sessions. A session lives outside the MCP process, so several agents can drive the same one and it stays open after the agent exits.

  • Passwords stay out of the model. A profile names an env var, or a password box opens on your desktop at connect time. The password goes to FreeRDP on stdin: never a tool argument, never in the process list.

  • Clipboard. Text copied on your desktop pastes in the session and back (RDP hosts; macOS Screen Sharing does not accept a VNC clipboard).

  • HiDPI and resizing. The window opens at your desktop scale, stays sharp, and the remote desktop follows when you resize it. The model works in screenshot pixels either way.

Works on GNOME Wayland (through XWayland) and on X11.

How it works

MCP client ──stdio──> server.py ──XTEST / XGetImage──> Xephyr window ──> xfreerdp ──RDP──> Windows
                                                          ^
                                                     you, watching

Xephyr is a small X display shown as a window. FreeRDP runs inside it. The server injects input with XTEST and reads the screen with XGetImage, so it never captures your real desktop and never steals your pointer.

Related MCP server: linux-cu

Install

Needs: xfreerdp (FreeRDP 3), Xephyr, xauth, mcookie, zenity, and uv. Optional: remote-viewer for VNC hosts, xclip for the clipboard bridge.

# Fedora
sudo dnf install freerdp xorg-x11-server-Xephyr xorg-x11-xauth zenity virt-viewer xclip
# Debian / Ubuntu
sudo apt install freerdp3-x11 xserver-xephyr xauth zenity virt-viewer xclip

git clone https://github.com/omeyz/rdp-mcp && cd rdp-mcp && uv sync
claude mcp add --scope user rdp -- "$PWD/.venv/bin/python" "$PWD/server.py"

Hosts

~/.config/rdp-mcp/hosts.toml, one block per machine (see hosts.example.toml):

[db01]
host = "10.0.0.25"
user = "Administrator"
domain = "CORP"
# no password_env: a password box opens on your desktop when connecting

Then ask: "connect to db01 and open Event Viewer". Partial names match.

Macs (VNC)

[macbook]
protocol = "vnc"
host = "macbook.local"

On the Mac: System Settings → General → Sharing → turn on Screen Sharing. If Remote Management is on instead, open its (i) → Options… and tick Observe and Control for your user, or sign-in is refused. Sign in with your Mac account name and password. cmd is the Command key in rdp_key.

Tools

Tool

What it does

rdp_hosts

List profiles and open sessions

rdp_connect

Open (or rejoin) a session, return a screenshot

rdp_screenshot

Current screen, optional wait

rdp_click

Left / right / middle click, double click

rdp_move, rdp_drag, rdp_scroll

Hover, drag, wheel

rdp_type

Type text

rdp_key

Keys and chords: ctrl+alt+delete, win+r, tab tab enter

rdp_disconnect

Close the window (Windows keeps the user signed in)

Every action returns a fresh screenshot once the screen settles.

Limits

  • rdp_type types as a US keyboard: US-keyboard characters only.

  • The clipboard bridge is text only, and does not reach Macs.

  • VNC sessions are scaled to the window, so text is a little soft.

  • Certificates are trust-on-first-use by default (cert = "tofu").

  • State and logs live in ~/.local/state/rdp-mcp/.

Safety

This gives a model the mouse and keyboard of whatever account you sign in with. Watch it, use the least-privileged account that does the job, and keep your MCP client's tool approvals on for machines that matter.

MIT license.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      D
      maintenance
      Control another PC's desktop from Claude Code via MCP — screenshot, mouse, keyboard, SSH, file transfer. For GUI work SSH can't reach on a remote machine; the remote PC approves each connection. Not Remote Control of your own Claude session.
      MIT
    • A
      license
      A
      quality
      B
      maintenance
      Enables Claude Code and Codex to see and drive an X11 desktop through screenshots, mouse, keyboard, and accessibility-tree actions while keeping the user's own pointer and focus separate.
      18
      Apache 2.0
    • A
      license
      Not graded
      quality
      C
      maintenance
      Enables AI agents to operate a complete Linux desktop through MCP, including applications, system windows, file managers, terminals, and browsers via AT-SPI element trees. It also provides noVNC access for humans to observe and take over the same desktop session.
      MIT
    • A
      license
      Not graded
      quality
      B
      maintenance
      Exposes a virtual Linux desktop over MCP so agents can drive humanized mouse and keyboard input, manage windows and shortcuts, launch programs, run shell commands, use the clipboard, and take screenshots or screen recordings.
      AGPL 3.0