Supergateway
Run MCP stdio servers over SSE and SSE over stdio. AI gateway.
Run MCP stdio servers over SSE and SSE over stdio. AI gateway.
{
"mcpServers": {
"supermachineExampleNpx": {
"command": "npx",
"args": [
"-y",
"supergateway",
"--sse",
"https://mcp-server-ab71a6b2-cd55-49d0-adba-562bc85956e3.supermachine.app"
]
}
}
}
 **Supergateway** runs **MCP stdio-based servers** over **SSE (Server-Sent Events)** or **WebSockets (WS)** with one command. This is useful for remote access, debugging, or connecting to clients when your MCP server only supports stdio. Supported by [Supermachine](https://supermachine.ai) (hosted MCPs), [Superinterface](https://superinterface.ai), and [Supercorp](https://supercorp.ai). ## Installation & Usage Run Supergateway via `npx`: ```bash npx -y supergateway --stdio "uvx mcp-server-git" ``` - **`--stdio "command"`**: Command that runs an MCP server over stdio - **`--sse "https://mcp-server-ab71a6b2-cd55-49d0-adba-562bc85956e3.supermachine.app"`**: SSE URL to connect to (SSE→stdio mode) - **`--streamableHttp "https://mcp-server.example.com/mcp"`**: Streamable HTTP URL to connect to (StreamableHttp→stdio mode) - **`--outputTransport stdio | sse | ws | streamableHttp`**: Output MCP transport (default: `sse` with `--stdio`, `stdio` with `--sse` or `--streamableHttp`) - **`--port 8000`**: Port to listen on (stdio→SSE or stdio→WS mode, default: `8000`) - **`--baseUrl "http://localhost:8000"`**: Base URL for SSE or WS clients (stdio→SSE mode; optional) - **`--ssePath "/sse"`**: Path for SSE subscriptions (stdio→SSE mode, default: `/sse`) - **`--messagePath "/message"`**: Path for messages (stdio→SSE or stdio→WS mode, default: `/message`) - **`--streamableHttpPath "/mcp"`**: Path for Streamable HTTP (stdio→Streamable HTTP mode, default: `/mcp`) - **`--stateful`**: Run stdio→Streamable HTTP in stateful mode - **`--sessionTimeout 60000`**: Session timeout in milliseconds (stateful stdio→Streamable HTTP mode only) - **`--header "x-user-id: 123"`**: Add one or more headers (stdio→SSE, SSE→stdio, or Streamable HTTP→stdio mode; can be used multiple times) - **`--oauth2Bearer "some-access-token"`**: Adds an `Authorization` header with the provided Bearer token - **`--logLevel debug | info | none`**: Controls logging level (default: `info`). Use `debug` for more verbose logs, `none` to suppress all logs. - **`--cors`**: Enable CORS (stdio→SSE or stdio→WS mode). Use `--cors` with no values to allow all origins, or supply one or more allowed origins (e.g. `--cors "http://example.com"` or `--cors "/example\\.com$/"` for regex matching). - **`--healthEndpoint /healthz`**: Register one or more endpoints (stdio→SSE or stdio→WS mode; can be used multiple times) that respond with `"ok"` ## stdio → SSE Expose an MCP stdio server as an SSE server: ```bash npx -y supergateway \ --stdio "npx -y @modelcontextprotocol/server-filesystem ./my-folder" \ --port 8000 --baseUrl http://localhost:8000 \ --ssePath /sse --messagePath /message ``` - **Subscribe to events**: `GET http://localhost:8000/sse` - **Send messages**: `POST http://localhost:8000/message` ## SSE → stdio Connect to a remote SSE server and expose locally via stdio: ```bash npx -y supergateway --sse "https://mcp-server-ab71a6b2-cd55-49d0-adba-562bc85956e3.supermachine.app" ``` Useful for integrating remote SSE MCP servers into local command-line environments. You can also pass headers when sending requests. This is useful for authentication: ```bash npx -y supergateway \ --sse "https://mcp-server-ab71a6b2-cd55-49d0-adba-562bc85956e3.supermachine.app" \ --oauth2Bearer "some-access-token" \ --header "X-My-Header: another-header...
A collection of MCP servers.
Chrome DevTools for coding agents
Enhanced ChatGPT Clone: Features Agents, MCP, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, M...
Playwright MCP server
GitHub's official MCP Server
🚀 The fast, Pythonic way to build MCP servers and clients.