MCP Config Generator
Build a valid Model Context Protocol config for Claude Desktop, Claude Code, Cursor, VS Code and Windsurf from one form. Correctly keyed, JSON-valid, with the exact file path for each client. Runs in your browser — keys never leave the page.
How it works
An MCP config file is small but unforgiving. It is plain JSON — no comments, no trailing commas — and a single syntax slip makes the whole file fail to parse, so every server vanishes with no error message. On top of that, each client expects a slightly different file, in a different location, under a different top-level key. This tool builds the block for you so none of that is done by hand.
The generation is deterministic serialization, not calculation. For each server you add, the tool assembles one object:
- Local (stdio): { command, args, env } — args is your argument list (one per line), env is a map of string values. args and env are omitted when empty.
- Remote (HTTP): { url, headers } — the streamable-HTTP shape. headers is omitted when empty.
Every server you add is merged into one map, keyed by server name. That map is then wrapped under the client-specific top-level key. Claude Desktop, Claude Code, Cursor and Windsurf use mcpServers; VS Code is the one outlier and uses servers in .vscode/mcp.json. Pasting the wrong key into a client is the most common reason a config looks right but loads nothing.
Finally the object is rendered with JSON.stringify(config, null, 2) and checked twice: the validity badge re-parses the output with JSON.parse, and an independent schema check confirms the right top-level key, that each server has a command or a url, and that all env and header values are strings. The key, file-path and shape rules come straight from the official MCP spec and each client's own docs (cited below), last verified on 2026-06-28.
Worked examples
Frequently asked questions
Sources & references
- Model Context Protocol — official specification & docs
- Anthropic — Connect Claude Code to tools via MCP (claude_desktop_config.json paths)
- VS Code — MCP configuration reference (servers key, .vscode/mcp.json)
- Cursor — Model Context Protocol (mcpServers, ~/.cursor/mcp.json)
- Windsurf — MCP (mcp_config.json)
The config keys, file paths and server-object shape on this page were last cross-checked against the official MCP spec and each client's docs on 2026-06-28. The format is a documented schema; this page is reviewed whenever a client changes its config layout.
Related tools
Comments & feedback
Spotted a bug or want an improvement? Tell us — our team reviews every comment, and good ideas get built. Comments are public and anonymous.
Found a bug, edge case, or want another client supported?
Email me at [email protected] — most fixes ship within 24 hours.