概览
What is Remote MCP Server on Cloudflare?
It is a pre-configured MCP server that runs on Cloudflare Workers with OAuth login, enabling remote MCP clients (such as Claude Desktop) to connect via SSE.
How to use Remote MCP Server on Cloudflare?
Clone the repository, install dependencies, and run locally with npx nx dev remote-mcp-server. Deploy using npx wrangler kv namespace create OAUTH_KV and npm run deploy. Then configure MCP clients (e.g., Claude Desktop) to point to the server’s SSE endpoint.
Key features of Remote MCP Server on Cloudflare
- Deploy a remote MCP server on Cloudflare Workers
- Built-in OAuth login flow
- SSE transport for MCP client connections
- Works with MCP Inspector and Claude Desktop
- Local development and remote deployment workflows
Use cases of Remote MCP Server on Cloudflare
- Running a remote MCP server accessible from anywhere
- Connecting Claude Desktop to a cloud‑hosted MCP server
- Testing MCP tools via the MCP Inspector
- Building and deploying custom MCP tools with OAuth
FAQ from Remote MCP Server on Cloudflare
How do I deploy the server?
Create a KV namespace with npx wrangler kv namespace create OAUTH_KV, add its ID to wrangler.jsonc, then run npm run deploy.
How do I connect the MCP Inspector?
In the Inspector, set Transport Type to SSE and enter http://localhost:8787/sse (local) or your workers.dev URL plus /sse (remote).
How do I connect Claude Desktop?
Update Claude’s configuration file to use npx mcp-remote with the server’s SSE URL (e.g., http://localhost:8787/sse or https://worker-name.account-name.workers.dev/sse).
How can I debug connection issues?
Run npx mcp-remote http://localhost:8787/sse directly in the terminal. If needed, clear stored auth data with rm -rf ~/.mcp-auth.
What authentication does the server use?
The server implements an OAuth login flow. During local development a mock login screen appears; after deployment, the real OAuth flow is used.