OpenClaw
Add MCP servers to OpenClaw
OpenClaw reads servers from mcp.servers in ~/.openclaw/openclaw.json, a JSON5 file, or adds them with openclaw mcp add.
- macOS
~/.openclaw/openclaw.json- Windows
~/.openclaw/openclaw.json- Linux
~/.openclaw/openclaw.json- Top-level key
mcp.servers- Format
- json5
- OAuth for remote servers
- Yes
Example config
This example adds GitHub's hosted server and Playwright as a local server, in the shape this client expects.
{
"mcp": {
"servers": {
"github": {
"url": "https://api.githubcopilot.com/mcp/",
"transport": "streamable-http"
},
"playwright": {
"command": "npx",
"args": [
"@playwright/mcp@latest"
]
}
}
}
}
openclaw mcp add github --url https://api.githubcopilot.com/mcp/ --transport streamable-http
openclaw mcp add playwright --command npx --arg @playwright/mcp@latest
Notes and quirks
- Always set transport on remote entries: if it's missing, OpenClaw uses legacy SSE.
- openclaw mcp doctor <name> --probe tests a configured server.
- openclaw mcp login <name> runs OAuth for a remote server.
- openclaw mcp serve exposes OpenClaw itself as an MCP server.
Other clients
Claude DesktopClaude CodeCursorVS Code (GitHub Copilot)Windsurf / Devin DesktopZedOpenAI Codex CLIGemini CLIChatGPTClineContinueJetBrains AI Assistant