home / mcp / mcp proxy server

MCP Proxy Server

Provides a TypeScript streamable HTTP and SSE proxy for MCP servers using stdio transport.

Installation
Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "punkpeye-mcp-proxy": {
      "command": "tsx",
      "args": [
        "server.js"
      ],
      "env": {
        "MCP_PROXY_API_KEY": "your-secret-key"
      }
    }
  }
}

MCP Proxy is a TypeScript-based proxy that enables streamable HTTP and SSE connections to MCP servers using stdio transport. It forwards messages between an MCP client and a local MCP server, with built‑in support for CORS and optional API key authentication to help you run MCP-based workflows with modern web clients.

How to use

You run a local MCP server (stdio) and point the proxy to it. The proxy exposes two browser-friendly endpoints: one for streamable HTTP at /mcp and one for SSE at /sse. Clients connect to these endpoints to send MCP messages, while the proxy forwards those messages to your local stdio server. You can enable or disable transports, customize endpoints, and opt into stateless mode for simple, scalable deployments. Use the API key option if you want to protect access to the proxy.

How to install

Prerequisites you need on your machine are Node.js and npm (or pnpm/yarn as preferred). Install the MCP proxy package and prepare to run it against your local stdio server.

Install the MCP proxy package globally or in your project.

Then start the proxy and point it at your stdio server.

Available tools

proxyServer

Sets up a proxy between a server and a client, routing messages in both directions.

startHTTPServer

Starts a proxy that listens for HTTP streamable transport and SSE, connecting to a given server, with options for port, host, endpoints, and CORS.

startStdioServer

Starts a proxy that listens to a local stdio server and forwards messages to a configured remote transport.

tapTransport

Wraps a transport to log or observe events for debugging or auditing.