Aider MCP WebSocket Server
@larock22
About Aider MCP WebSocket Server
WebSocket server that exposes Aider's AI coding capabilities through the Model Context Protocol (MCP) for programmatic access
Basic information
Config
Add this server to your MCP-compatible client using the configuration below.
{
"mcpServers": {
"aider-mcp": {
"command": "python3",
"args": [
"test-debug.py"
]
}
}
}Tools
No tools detected
We auto-extract tools from the README. The maintainer can list them under a ## Tools heading to populate this section.
Overview
What is Aider MCP WebSocket Server?
A real MCP (Model Context Protocol) server that lets you control Aider programmatically via WebSocket, wrapping Aiderβs functionality for use by editor plugins and services. It provides two server implementations: a standard MCP protocol server (recommended) and a custom WebSocket wrapper. It is for developers who want to send natural language commands to Aider from any MCP-compatible client, like Claude Desktop or custom apps.
How to use Aider MCP WebSocket Server?
Install dependencies with npm install, copy .env.example to .env and add your OpenAI API key. Start the recommended MCP server with npm run mcp, then connect via WebSocket using JSON-RPC 2.0. The server exposes tools such as aider_command, aider_add_file, and aider_run_command. Client code examples for WebSocket connection and tool calls are provided in the README.
Key features of Aider MCP WebSocket Server
- Full MCP protocol support with standard JSON-RPC 2.0 methods
- Multi-tenant isolation: one Aider child process per client
- Automatic completion detection (waits for Aider to finish)
- Isolated workspace directories per session
- Real-time bidirectional WebSocket communication
- Environment variable and CLI argument configuration
Use cases of Aider MCP WebSocket Server
- Send natural language commands to create or edit code files
- Add specific files to Aiderβs context before executing commands
- Run shell commands through Aider as part of a development workflow
- Build editor plugins or services that programmatically control Aider
- Integrate Aider into CI/CD pipelines or automated code review systems
FAQ from Aider MCP WebSocket Server
What prerequisites are needed?
Node.js 18+, Aider installed and available in PATH (pip install aider-chat), and an OpenAI API key.
How does the server handle multiple clients?
Each client gets an isolated workspace directory and a separate Aider process, ensuring session separation.
Is authentication supported?
The custom WebSocket wrapper supports token-based authentication via the VALID_TOKENS environment variable (empty means no auth). The MCP server does not mention authentication.
Where are created files stored?
Files are saved in directories under workspaces/, e.g., workspaces/mcp-*/. You can check them with ls -la workspaces/.
What if the server returns too quickly or gives incomplete responses?
The MCP server includes smart completion detection that waits for Aider to finish (using a 3-second silence detection), solving the problem of premature responses.
More Other MCP servers
MCP Toolbox for Databases
googleapisMCP Toolbox for Databases is an open source MCP server for databases.
MaxKB
1Panel-devπ₯ MaxKB is an open-source platform for building enterprise-grade agents. εΌΊε€§ζη¨ηεΌζΊδΌδΈηΊ§ζΊθ½δ½εΉ³ε°γ
Blender
ahujasidOpen-source MCP to use Blender with any LLM

EverArt
modelcontextprotocolModel Context Protocol Servers
Codelf
unbugA search tool helps dev to solve the naming things problem.
Comments