Home / Servers

@cloudflare/mcp-server-cloudflare

by geelen

Cloudflare MCP Server

Model Context Protocol (MCP) is a new, standardized protocol for managing context between large language models (LLMs) and external systems. In this repository, we provide an installer as well as an MCP Server for Cloudflare's API.

This lets you use Claude Desktop, or any MCP Client, to use natural language to accomplish things on your Cloudflare account, e.g.:

  • Please deploy me a new Worker with an example durable object.
  • Can you tell me about the data in my D1 database named '...'?
  • Can you copy all the entries from my KV namespace '...' into my R2 bucket '...'?

Demo

<div align="center"> <a href="https://www.youtube.com/watch?v=vGajZpl_9yA"> <img src="https://img.youtube.com/vi/vGajZpl_9yA/maxresdefault.jpg" alt="Demonstrating the newly-released MCP server to explore Cloudflare properties, like Workers, KV, and D1." width="600"/> </a> </div>

Setup

  1. Make sure you are logged in to Cloudflare via Wrangler:

    npx wrangler login
    

    This authentication is required for the MCP server to access your Cloudflare resources when testing locally.

  2. Run npx @cloudflare/mcp-server-cloudflare init

<div align="left"> <img src="https://github.com/user-attachments/assets/163bed75-ec0c-478a-94b2-179969a90923" alt="Example console output" width="300"/> </div>
  1. Restart Claude Desktop, you should see a small πŸ”¨ icon that shows the following tools available for use:
<div align="left"> <img src="https://github.com/user-attachments/assets/a24275b1-1c6f-4754-96ef-dd7b9f0f5903" alt="Example tool icon" height="160"/> <img src="https://github.com/user-attachments/assets/4fb8badb-6800-4a3f-a530-a344b3584bec" alt="Example tool list" height="160"/> </div>

Paid Features

Some features in this MCP server require a paid Cloudflare Workers plan:

  • Observability and Analytics: The analytics_get tool and related analytics features require a paid Workers plan to access these metrics
  • Other premium Cloudflare features like advanced D1 database capabilities and higher usage limits also require appropriate paid plans

Ensure your Cloudflare account has the necessary subscription level for the features you intend to use.

Features

KV Store Management

  • get_kvs: List all KV namespaces in your account
  • kv_get: Get a value from a KV namespace
  • kv_put: Store a value in a KV namespace
  • kv_list: List keys in a KV namespace
  • kv_delete: Delete a key from a KV namespace

R2 Storage Management

  • r2_list_buckets: List all R2 buckets in your account
  • r2_create_bucket: Create a new R2 bucket
  • r2_delete_bucket: Delete an R2 bucket
  • r2_list_objects: List objects in an R2 bucket
  • r2_get_object: Get an object from an R2 bucket
  • r2_put_object: Put an object into an R2 bucket
  • r2_delete_object: Delete an object from an R2 bucket

D1 Database Management

  • d1_list_databases: List all D1 databases in your account
  • d1_create_database: Create a new D1 database
  • d1_delete_database: Delete a D1 database
  • d1_query: Execute a SQL query against a D1 database

Workers Management

  • worker_list: List all Workers in your account
  • worker_get: Get a Worker's script content
  • worker_put: Create or update a Worker script
  • worker_delete: Delete a Worker script

Durable Objects

  • durable_objects_list: List all Durable Objects namespaces
  • durable_objects_create: Create a new Durable Objects namespace
  • durable_objects_delete: Delete a Durable Objects namespace
  • durable_objects_list_instances: List all instances for a specific Durable Objects namespace
  • durable_objects_get_instance: Get details about a specific Durable Objects instance
  • durable_objects_delete_instance: Delete a specific Durable Objects instance

Queues

  • queues_list: List all Queues in your account
  • queues_create: Create a new Queue
  • queues_delete: Dele

Related servers

n8n

by n8n-io

Fair-code workflow automation platform with native AI capabilities. Combine visual building with custom code, self-host or cloud, 400+ integrations.

NOASSERTIONβ˜… 198,904

@modelcontextprotocol/server-everything

Official

by modelcontextprotocol

MCP server that exercises all the features of the MCP protocol

β˜… 89,105

@modelcontextprotocol/server-filesystem

Official

by modelcontextprotocol

MCP server for filesystem access

SEE LICENSE IN LICENSEβ˜… 89,105

mcp-server-fetch

Official

by modelcontextprotocol

A Model Context Protocol server providing tools to fetch and convert web content for usage by LLMs

β˜… 89,105