mcp-gateway
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-gatewayreload your configuration from mcp-servers.json"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Gateway
A local MCP gateway that aggregates multiple downstream MCP servers behind a single connection.
One config file (
mcp-servers.json) controls every downstream server.Hot-reload via HTTP admin API or file-watcher — no need to restart Claude.
Runs on localhost with a rare port (default
51337) for admin.Supports large request/response payloads (
100mbJSON limit, stdio streams unbounded).
How it works
Claude (host)
│ stdio
▼
┌──────────────┐ ┌─────────────┐
│ MCP Gateway │◄────────►│ filesystem │
│ (this app) │ stdio └─────────────┘
│ │ ┌─────────────┐
│ • 1 config │◄────────►│ brave │
│ • hot reload│ HTTP └─────────────┘
│ • aggregate │ ┌─────────────┐
└──────────────┘◄────────►│ sqlite │
localhost:51337 └─────────────┘
(admin API)You add Claude once as an MCP server in Claude Desktop / Claude Code.
After that, every other MCP server lives in mcp-servers.json.
Edit the JSON, hit reload, and the new tools appear — Claude keeps running.
Related MCP server: MCP Manager
Quick start
1. Install dependencies
cd mcp-gateway
npm install
npm run build2. Register the gateway with Claude
Claude Desktop
Edit %APPDATA%\Claude\claude_desktop_config.json (Windows) or the macOS/Linux equivalent:
{
"mcpServers": {
"gateway": {
"command": "node",
"args": ["D:/coding/temp/mcp-gateway/dist/index.js"]
}
}
}Claude Code CLI
claude mcp add gateway -s user -- node D:/coding/temp/mcp-gateway/dist/index.js3. Add downstream servers
Edit mcp-servers.json:
{
"servers": {
"fs": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-filesystem", "."]
},
"fetch": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-fetch"]
},
"remote-api": {
"url": "http://localhost:3001/sse"
}
}
}4. Reload
The gateway auto-reloads when the file changes (500 ms debounce).
Or hit the admin API manually:
curl -X POST http://localhost:51337/reload5. Check status
curl http://localhost:51337/statusConfig file format (mcp-servers.json)
{
"servers": {
"my-server-name": {
"command": "npx",
"args": ["-y", "some-mcp-package"],
"env": { "API_KEY": "secret" }
},
"another-server": {
"url": "http://localhost:8080/sse",
"headers": { "Authorization": "Bearer token" }
}
}
}Field | Required | Description |
| * | Executable to spawn (stdio transport) |
| Arguments array | |
| Extra env vars (merges with | |
| * | HTTP/SSE endpoint (alternative to |
| Extra HTTP headers |
Either command or url is required.
Tool / resource / prompt namespacing
To avoid collisions, every downstream item is prefixed:
Downstream | Gateway exposes |
|
|
|
|
|
|
Claude sees the prefixed names and routes are handled automatically.
Admin API
Method | Path | Body | Description |
|
| — | List connected servers |
|
|
| Reload from disk file |
|
| Full config JSON | Reload from inline JSON |
Default port: 51337.
Override with env var: ADMIN_PORT=61442 node dist/index.js
Environment variables
Variable | Default | Description |
|
| Path to config file |
|
| Admin HTTP port |
Large payloads
Admin API accepts up to
100 mbJSON bodies (express.json({ limit: "100mb" })).Stdio streams have no artificial buffer cap — messages are framed with
Content-Lengthand parsed as complete JSON-RPC objects.If a downstream server crashes on a huge payload, the error is caught and returned to Claude as an MCP error.
For Claude (the assistant)
You can add or remove MCP servers for the user by:
Editing
mcp-servers.jsonwith the Write/Edit tool.Triggering reload with the Bash tool:
curl -X POST http://localhost:51337/reloadOr simply wait 500 ms — the file watcher auto-reloads.
You never need to ask the user to restart Claude.
Maintenance
Related MCP Connectors
Stateless MCP gateway and OTel span-streaming bridge for hosted MCP servers.
61Governed MCP gateway: one endpoint for your tools, with credential custody and audit log.
MCP Gateway: wrap any MCP server with cold-start retries, uptime SLA, and per-execution MPP billing.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceMCP Gateway that aggregates multiple upstream MCP servers into a single endpoint with persistent connections, tool registry, and authentication.20 npm2MIT
- AlicenseNot gradedqualityBmaintenanceSelf-hosted MCP proxy and aggregation platform. Register multiple upstream MCP servers and expose them through a single unified endpoint with namespace routing, multi-transport support (HTTP/SSE, stdio, OpenAPI→MCP), per-tool overrides, and a web admin UI.18MIT
- AlicenseNot gradedqualityCmaintenanceCentralized MCP control plane that proxies multiple upstream MCP servers with tool namespacing, filtering, policy enforcement, audit logging, and health checks.12 npmMIT
- AlicenseNot gradedqualityAmaintenanceA universal MCP gateway that aggregates multiple MCP servers into a single endpoint, providing features like hot-reload, auto-healing, and a hook system for request/response mutation.1MIT