Deploy a no-auth remote MCP server on Cloudflare Workers with customization and easy integration options
This example provides a step-by-step guide to setting up an MCP (Model Context Protocol) server that operates without authentication on Cloudflare Workers. The server allows AI applications to connect and utilize predefined tools through a secure, standardized protocol. This server can be seamlessly integrated with various AI tools and platforms such as Claude Desktop, Continue, Cursor, and more.
The core features of the Remote Authless MCP Server encompass its seamless integration capabilities, real-time data updates via SSE (Server-Sent Events), and the absence of authentication requirements. Its compatibility with both local development environments and production Cloudflare Workers makes it a versatile choice for developers.
init()
method in its source code.src/index.ts
file using the this.server.tool(...)
function.The architecture of this server adheres to the strict standards of the Model Context Protocol (MCP). The protocol ensures secure and efficient data exchange between clients and servers. Below is an example of how the protocol flow works using Mermaid diagrams.
graph TD
A[AI Application] -->|MCP Client| B[MCP Protocol]
B --> C[MCP Server]
C --> D[Data Source/Tool]
style A fill:#e1f5fe
style C fill:#f3e5f5
style D fill:#e8f5e8
graph LR;
A[MCP Client] --> B[API Gateway];
B -->|SSE| C[MCP Server];
C --> D[Data Source/Tool];
style A fill:#e1f5fe;
style C fill:#f3e5f5;
style D fill:#e8f5e8;
Deploying the Remote Authless MCP Server to Cloudflare Workers or your local machine is straightforward. Follow these steps:
This will deploy your server URL like: remote-mcp-server-authless.<your-account>.workers.dev/sse
npm create cloudflare@latest -- my-mcp-server --template=cloudflare/ai/demos/remote-mcp-authless
AI-assisted Financial Analysis
Medical Diagnosis Tool Integration
The Remote Authless MCP Server is compatible with several popular AI clients, including:
MCP Client | Resources | Tools | Prompts | Status |
---|---|---|---|---|
Claude Desktop | ✅ | ✅ | ✅ | Full Support |
Continue | ✅ | ✅ | ❌ (WIP) | Limited support |
Cursor | ❌ (WIP) | ✅ | ✅ (WIP) | Work in progress support |
To connect an MCP client like Claude Desktop, modify the configuration:
{
"mcpServers": {
"calculator": {
"command": "npx",
"args": [
"mcp-remote",
"http://localhost:8787/sse" // or remote-mcp-server-authless.your-account.workers.dev/sse
]
}
}
}
Restart Claude Desktop to see the new tools available.
The server is optimized for performance and compatibility across different environments:
Environment | Response Time (ms) | Concurrency Limit | Data Size Support |
---|---|---|---|
Cloudflare Workers | <50 | Unlimited | Up to 1MB |
{
"mcpServers": {
"[server-name]": {
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-[name]"],
"env": {
"API_KEY": "your-api-key"
}
}
}
}
Can I use this server with older MCPC clients?
Is there a limit to the number of tools I can add to my server?
How do I troubleshoot connection issues between client and server?
Can I host this server elsewhere besides Cloudflare Workers?
Is authentication enforced by default?
Contributions are welcomed! To contribute:
Ensure your code adheres to the existing coding standards and runs all tests successfully.
Explore more resources and tools related to MCP at Model Context Protocol.
Join the community for discussions, updates, and further integration help.
RuinedFooocus is a local AI image generator and chatbot image server for seamless creative control
Simplify MySQL queries with Java-based MysqlMcpServer for easy standard input-output communication
Learn to set up MCP Airflow Database server for efficient database interactions and querying airflow data
Build stunning one-page websites track engagement create QR codes monetize content easily with Acalytica
Explore CoRT MCP server for advanced self-arguing AI with multi-LLM inference and enhanced evaluation methods
Access NASA APIs for space data, images, asteroids, weather, and exoplanets via MCP integration