Building a Remote MCP Server on Cloudflare (Without Auth)
@saachi-sonata
Overview
What is Building a Remote MCP Server on Cloudflare (Without Auth)?
This example deploys a remote Model Context Protocol (MCP) server that requires no authentication on Cloudflare Workers. It is for developers who want a simple, publicly accessible MCP endpoint to expose tools to AI clients.
How to use Building a Remote MCP Server on Cloudflare (Without Auth)?
Deploy by clicking the "Deploy to Workers" button or by running npm create cloudflare@latest -- my-mcp-server --template=cloudflare/ai/demos/remote-mcp-authless locally. To add custom tools, edit src/index.ts and define each tool inside the init() method using this.server.tool(...).
Key features of Building a Remote MCP Server on Cloudflare (Without Auth)
- No authentication required on the MCP server.
- Deployable with a single click or CLI command.
- Runs on Cloudflare Workers global network.
- Connects to Cloudflare AI Playground and local MCP clients.
- Supports custom tool definitions via code.
Use cases of Building a Remote MCP Server on Cloudflare (Without Auth)
- Expose AI tools via SSE to the Cloudflare AI Playground.
- Connect the remote MCP server to Claude Desktop using the
mcp-remoteproxy. - Rapidly prototype and test MCP tools without setting up authentication.
- Host lightweight, serverless tool endpoints for MCP-compatible clients.
FAQ from Building a Remote MCP Server on Cloudflare (Without Auth)
How do I deploy this MCP server?
Click the "Deploy to Workers" button or run npm create cloudflare@latest -- my-mcp-server --template=cloudflare/ai/demos/remote-mcp-authless in your terminal.
How do I add custom tools to the MCP server?
Edit src/index.ts and define each tool inside the init() method using this.server.tool(...).
How do I connect the MCP server to Cloudflare AI Playground?
Go to https://playground.ai.cloudflare.com/, enter your deployed MCP server URL (e.g., remote-mcp-server-authless.<your-account>.workers.dev/sse), and you can use the tools directly.
How do I connect Claude Desktop to this MCP server?
Use the mcp-remote proxy. Add a configuration entry in Claude Desktop’s Developer settings with the mcp-remote command and your server URL (e.g., http://localhost:8787/sse or the deployed URL).
Does this MCP server require authentication?
No, the server is deliberately built without authentication as the name implies.