home / mcp / computer control mcp server
MCP server that provides computer control capabilities, like mouse, keyboard, OCR, etc. using PyAutoGUI, RapidOCR, ONNXRuntime. Similar to 'computer-use' by Anthropic. With Zero External Dependencies.
Configuration
View docs{
"mcpServers": {
"ab498-computer-control-mcp": {
"command": "computer-control-mcp",
"args": [],
"env": {
"COMPUTER_CONTROL_MCP_WGC_PATTERNS": "obs, discord, game, steam",
"COMPUTER_CONTROL_MCP_SCREENSHOT_DIR": "C:\\\\Users\\\\YourName\\\\Pictures\\\\Screenshots"
}
}
}
}You can automate computer interactions with this MCP server, which provides mouse and keyboard control, OCR, screenshots, and window management. It runs locally or via a remote MCP client, letting you script repetitive tasks and accessibility workflows across your computer.
To control your computer through the MCP client, connect to the Computer Control MCP server and call its actions from your automation scripts. You can move the mouse, click, type text at the current cursor, drag and drop, take screenshots with optional OCR, and manage windows. There are also options tailored for GPU-accelerated windows to improve screenshot reliability. If you want to tailor how screenshots are saved or how WGC is applied, you can configure environment variables on startup.
{
"mcpServers": {
"computer-control-mcp": {
"command": "uvx",
"args": ["computer-control-mcp@latest"]
}
}
}Alternatively, install the package with Python’s package manager. After installation, start the server by calling the runtime command directly.
pip install computer-control-mcp
```
```bash
computer-control-mcpEnvironment variables let you customize behavior without changing code. The following options are shown for screenshot handling and GPU-accelerated Windows use:
{
"mcpServers": {
"computer-control-mcp": {
"command": "uvx",
"args": ["computer-control-mcp@latest"],
"env": {
"COMPUTER_CONTROL_MCP_SCREENSHOT_DIR": "C:\\Users\\YourName\\Pictures\\Screenshots",
"COMPUTER_CONTROL_MCP_WGC_PATTERNS": "obs, discord, game, steam"
}
}
}
}If you prefer to keep screenshots in your Downloads folder by default, you can omit the environment variable and the server will save to the standard downloads location. You can also enable Windows Graphics Capture (WGC) automatically for specific windows by listing title patterns in COMPUTER_CONTROL_MCP_WGC_PATTERNS. This helps avoid black screens with GPU-accelerated apps.
Click at specific screen coordinates (x, y) to simulate a mouse click.
Move the mouse cursor to specified coordinates (x, y).
Drag the mouse from one position to another with an optional duration.
Hold down a mouse button (left, right, or middle).
Release a held mouse button.
Type the provided text at the current cursor position.
Press a single keyboard key.
Hold down a specific keyboard key until released.
Release a held keyboard key.
Press one or more keys, including sequences and combinations.
Capture the screen or a window, with optional OCR and WGC options.
Capture and extract text from a screenshot using OCR, with optional coordinate data.
Return the current screen resolution.
List all open windows.
Bring a window matching a title pattern to the foreground.
Pause execution for a specified amount of time.