MCP Config Generator
🔒 In your browserGenerate a valid MCP server config for Claude, Cursor, VS Code & Windsurf.
How it works
Fill in your MCP server details and get a ready-to-paste config block in the exact shape your client expects — Claude Desktop, Claude Code, Cursor, VS Code or Windsurf. Nothing is uploaded; it's built in your browser.
Add to claude_desktop_config.json
{
"mcpServers": {
"my-server": {
"command": "npx",
"args": [
"-y",
"server-package-name"
]
}
}
}- • Restart Claude Desktop after editing the file for changes to take effect.
Client config formats change over time (these reflect the major clients as of early 2026) — if a server doesn't load, check your client's current MCP docs. Keep real API keys out of any file you commit to a shared repo.
About the MCP Config Generator
MCP (Model Context Protocol) servers give AI assistants like Claude extra tools and data, but each client wants the configuration in its own slightly different JSON shape and file location. This free MCP config generator builds a correct, copy-paste-ready config for Claude Desktop, Claude Code, Cursor, VS Code or Windsurf from a simple form.
Everything is generated in your browser — nothing you type, including placeholder API keys, is ever uploaded.
How to add an MCP server
- Pick your client — the tool switches to the exact JSON shape and file that client reads.
- Choose the transport: stdio for a local command (npx, uvx, node, python, docker) or http for a remote server URL.
- Enter the command and arguments, plus any environment variables such as API keys.
- Copy the generated block into the file shown (for example claude_desktop_config.json) and restart the client.
Why each client differs
Most clients — Claude Desktop, Claude Code, Cursor and Windsurf — nest servers under an mcpServers object, while VS Code uses a servers object with an explicit type field. Remote servers are expressed as a URL on some clients and through the mcp-remote bridge on Claude Desktop. This generator handles those differences for you so you don't have to remember them.
Keep your keys safe
- Never commit a config file containing real API keys to a shared or public repository.
- Where your client supports it (for example VS Code inputs), let it prompt for secrets instead of storing them in the file.
- Before installing an unfamiliar server, check what it can do with the MCP Security Scanner.
Frequently asked questions
Where does the Claude Desktop config file live?
It's called claude_desktop_config.json. On macOS it's under ~/Library/Application Support/Claude/, and on Windows under %APPDATA%\Claude\. Paste the generated mcpServers block into it and restart Claude Desktop.
What's the difference between stdio and http servers?
A stdio server is a local command the client launches (like npx a-package), talking over standard input/output. An http server is a remote endpoint you connect to by URL. Pick the one your server documents.
Why did the tool add -y to my npx command?
Without -y, npx pauses to ask permission to install the package, which can make the client hang while it waits. Adding -y (or --yes) lets it install non-interactively.
Is my API key uploaded anywhere?
No. The config is assembled entirely in your browser. Nothing you type is sent to a server, so placeholder or real keys stay on your device.
The server still won't load — what now?
Client config formats change over time. Double-check the command runs in your terminal, that the file is valid JSON (try the MCP Config Validator), and compare against your client's current MCP documentation.
Related searches
Related Developer tools
🔗 Embed this tool on your website — free
Copy this and paste it into your page's HTML. The tool runs in the visitor's browser, just like here. Change height to fit, or add the optional auto-resize snippet below. Add ?theme=dark to the URL for dark mode.
<iframe src="https://toolhq.dev/embed/mcp-config-generator/" title="MCP Config Generator — ToolsHub" width="100%" height="520" style="border:1px solid #e5e7eb;border-radius:12px;max-width:680px" loading="lazy"></iframe>Optional: auto-resize the iframe height
Add this once on the same page so the iframe grows to fit the tool:
<script>
addEventListener("message", function (e) {
if (e.data && e.data.type === "toolshub:resize") {
document.querySelectorAll('iframe[src*="/embed/"]').forEach(function (f) {
if (f.contentWindow === e.source) f.style.height = e.data.height + "px";
});
}
});
</script>