MCP Server Cloudflare logo

MCP Server Cloudflare

by ofershap

Manage Cloudflare zones, DNS, Workers, KV, R2 buckets, and cache purges through MCP tools.

Install MCP Server Cloudflare

Pick your client, then add it in one click or paste the config.

STDIONode.js
~/Library/Application Support/Claude/claude_desktop_config.json
claude_desktop_config.json
{
  "mcpServers": {
    "ofershap-mcp-server-cloudflare": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-server-cloudflare-dns"
      ],
      "env": {
        "CLOUDFLARE_API_TOKEN": "YOUR_VALUE_HERE",
        "CLOUDFLARE_ACCOUNT_ID": "YOUR_VALUE_HERE"
      }
    }
  }
}

Settings → Developer → Edit Config, merge this into mcpServers, then fully quit and reopen Claude Desktop.

Values are written into the snippet above so you can paste it as is. They never leave your browser.

Claude Code command
claude mcp add --env CLOUDFLARE_API_TOKEN=YOUR_VALUE_HERE --env CLOUDFLARE_ACCOUNT_ID=YOUR_VALUE_HERE --transport stdio ofershap-mcp-server-cloudflare -- npx -y mcp-server-cloudflare-dns

Run in your terminal. Add --scope project to share it with your team through .mcp.json.

We couldn’t confirm it starts correctly

The install command started, but didn't respond the way we expected when we tried to talk to it.

npx -y mcp-server-cloudflare-dns

initialize succeeded but no response to tools/list.

This is an experimental automated check and can have false negatives — missing environment variables, a slow cold install, etc. It doesn’t necessarily mean something’s wrong. Last checked .

Overview

The ofershap/mcp-server-cloudflare MCP server connects an MCP-compatible assistant to Cloudflare management APIs. It provides tools for zones, DNS records, Workers scripts, KV namespaces and values, R2 bucket listing, and cache purging. Authentication uses a Cloudflare API token, with an account ID additionally required for Workers, KV, and R2 operations. Reach for it when you want to inspect or change these Cloudflare resources from Claude Desktop, Cursor, or VS Code Copilot.

Use cases

  • List DNS records for a Cloudflare zone
  • Create or delete Cloudflare DNS records
  • Inspect and manage Workers KV values
  • List Workers scripts and R2 buckets
  • Purge cache for selected URLs

Key features

  • Cloudflare zone and DNS management
  • Workers script listing and deletion
  • Workers KV namespace and value operations
  • R2 bucket listing
  • Global or URL-specific cache purging

Tools13

What MCP Server Cloudflare lets your agent do. Expand a tool for its parameters.

Verified live~1.1k tokens of context

Security & health

What it can reach and how reliably it runs — from our own checks, not the maintainer’s claims.

ActiveLast checked

Recent health check succeeded.

28/28 checks healthy over the last 117d

Supply-chain signal

No high-severity advisories surfaced by our automated scan.

Critical 0High 0Medium 0Low 0

Scanned 16d ago via OSV.dev · mcp-server-cloudflare-dns (npm)

Adoption & maintenance

Factual signals from GitHub, npm, and our automated checks — not a rating.

GitHub stars4Stargazers on the source repository.
npm downloads193Package downloads in the last 30 days.
Last commit3mo agoMost recent push to the default branch.
Install checkInconclusiveStarted but did not complete the MCP handshake in our test.
Tools exposed13Callable tools this server registers over MCP.
Directory activity9 viewsConfig copies, upvotes, and views on AllMCPs.

How MCP Server Cloudflare works

What ofershap/mcp-server-cloudflare does

The ofershap/mcp-server-cloudflare MCP server exposes selected Cloudflare account and zone operations to AI assistants through MCP. It can list zones and DNS records, create or delete DNS records, inspect or remove Workers scripts, and work with Workers KV namespaces and keys. KV support includes reading, writing, and deleting values. The server can also list R2 buckets and purge cache either globally or for specific URLs.

This is intended for operational tasks that can be expressed through the available Cloudflare tools, such as checking a domain’s records, reviewing deployed Workers, updating a KV value, or clearing a cached page.

How it works

An MCP client starts the server with npx -y mcp-server-cloudflare-dns. The assistant then invokes the exposed tools with the relevant zone, namespace, record, key, bucket, or URL information. The server authenticates API calls using environment variables supplied by the client rather than an interactive sign-in flow.

Available operations are grouped by Cloudflare resource:

  • Zones and DNS: enumerate zones, list records, and create or delete records.
  • Workers: list scripts and delete scripts.
  • KV: list namespaces, list keys, retrieve values, write values, and delete keys.
  • R2 and cache: list buckets and purge all cache or selected URLs.

Setup and configuration

Install and run the npm package named mcp-server-cloudflare-dns; this differs from the GitHub repository name and from an unrelated npm stub with a similar name. In Claude Desktop, add a cloudflare MCP entry to claude_desktop_config.json. In Cursor, add the equivalent entry to .cursor/mcp.json, using npx as the command and -y, mcp-server-cloudflare-dns as its arguments.

Set CLOUDFLARE_API_TOKEN for all API calls. Set CLOUDFLARE_ACCOUNT_ID when using Workers, KV, or R2 tools. The token should have permissions matching the operations you plan to perform: zone read or edit, Workers Scripts edit, Workers KV Storage edit, and Zone Cache Purge as applicable.

The repository also includes an Agent Plugins package. For Cursor, it can be cloned and copied or symlinked to ~/.cursor/plugins/local/mcp-server-cloudflare, then enabled after reloading the window. Configure the same environment variables in the client.

Tools and capabilities

The tool names are:

  • cf_zones, cf_dns_list, cf_dns_create, and cf_dns_delete
  • cf_workers_list and cf_worker_delete
  • cf_kv_namespaces, cf_kv_keys, cf_kv_get, cf_kv_put, and cf_kv_delete
  • cf_r2_buckets and cf_cache_purge

Together, these tools cover resource discovery, selected DNS and Workers changes, KV data operations, R2 bucket listing, and cache invalidation.

Limitations and notes

The ofershap/mcp-server-cloudflare MCP server requires credentials in the MCP client environment. Agent Plugins v1 does not provide OAuth, and the repository does not offer a one-click Cursor installation because credentials cannot be embedded in a portable install link. Access is also constrained by the Cloudflare token permissions you grant. R2 support is documented as bucket listing, while the listed tools do not provide R2 object operations.

Written by AllMCPs with AI assistance from the project’s README and listing data. How we build listings

Reviews

No reviews yet — be the first to share how it worked for you.

Frequently Asked Questions about MCP Server Cloudflare

ofershap/mcp-server-cloudflare is an MCP server that connects AI assistants to Cloudflare and exposes tools for zones, DNS, Workers, KV, R2, and cache management. It supports listing and selected mutations, including DNS changes, Workers deletion, KV reads and writes, R2 bucket listing, and cache purging.

Install it through the `mcp-server-cloudflare-dns` npm package with `npx -y mcp-server-cloudflare-dns`. Add that command to your MCP client configuration, then provide `CLOUDFLARE_API_TOKEN` and, for Workers, KV, or R2 operations, `CLOUDFLARE_ACCOUNT_ID`.

Yes, it works with Cursor. Add the server to `.cursor/mcp.json` with the npm command and required environment variables. The repository also supports installation as a local Agent Plugin under `~/.cursor/plugins/local/mcp-server-cloudflare`.

It needs a Cloudflare API token with permissions matching your operations. Use Zone:Read for zone and DNS listing, Zone:Edit for DNS changes, Workers Scripts:Edit for Workers, Workers KV Storage:Edit for KV, and Zone:Cache Purge for cache purging.

No object operations are listed. The available R2 capability is listing R2 storage buckets, and the server requires `CLOUDFLARE_ACCOUNT_ID` for R2 access.

Related MCP servers

Add a badge to your READMEShow it’s listed — live SVG, Markdown or HTML.

AllMCPs Directory Badge

Full Badge Customizer

Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.

Badge Style:
Live Dynamic SVG PreviewMCP Server Cloudflare AllMCPs Directory Badge
Markdown (GitHub README)
[![AllMCPs](https://allmcps.com/api/badge/ofershap-mcp-server-cloudflare?style=directory)](https://allmcps.com/mcp/ofershap-mcp-server-cloudflare)
HTML Embed
<a href="https://allmcps.com/mcp/ofershap-mcp-server-cloudflare"><img src="https://allmcps.com/api/badge/ofershap-mcp-server-cloudflare?style=directory" alt="MCP Server Cloudflare on AllMCPs" /></a>