Can an AI agent work with Cloudflare?

Yes. Agent Planners connects to Cloudflare through the official API and gives the agent 19 read tools and 12 write tools. Reads such as reports run at once; by default every write waits for your approval. You can use the same tools in the app or from Claude, ChatGPT and Codex over MCP.

Websites & DNS

AI agent for Cloudflare: DNS records, zone settings, cache and Workers with your own API token

TL;DR

Cloudflare connects with an API token from your Cloudflare profile. The token's own permissions are the limit: what it may not do is answered with the exact permission to add, never worked around. Deleting a DNS record, deploying Worker code, removing a Worker route, purging the whole cache and TLS / security settings always wait for a person; account members, API tokens, billing and deleting a zone are never reachable.

Connecting it

  1. 1In Cloudflare, open My Profile → API Tokens → Create Token and give it the permissions the agent should have (for DNS: Zone · DNS · Edit) on the accounts and zones it may touch.
  2. 2Open Integrations, press Connect with an API token on the Cloudflare card, paste the token and press Check and save.
  3. 3Each Cloudflare account the token reaches appears with what the token can and cannot do there. Pick it for the task, then write the goal.

What the agent reads

  • Zones (status, plan, name servers), DNS records and the BIND export, zone settings and rulesets (WAF, redirects, transforms, cache rules).
  • Traffic by day: requests, cached requests, bandwidth, threats, page views and unique visitors.
  • Workers (settings and source) and their routes, Pages projects, R2 buckets, KV namespaces, D1 databases and domains registered with Cloudflare.

What the agent changes — all of it approval-gated

  • DNS records — create and change (read first, shown before and after); deleting one waits for a person.
  • Zone settings and cache — change a setting, purge files, prefixes, hosts or tags; TLS / security settings and purging everything wait for a person.
  • Workers — add a route; deploying code and removing a route wait for a person.
The agent never gets more than your token. To keep it to some domains, scope the token to those zones in Cloudflare — or add a Forbidden Rule that allows only those domains. From Claude, Codex or Cursor: Cloudflare MCP server · Every tool and permission: Cloudflare guide · Cloudflare playbook · Keep an agent to some domains · What's new: Cloudflare.

Frequently asked questions

Does Agent Planners support Cloudflare?
Yes. It connects to the Cloudflare API with your own API token and covers DNS, zone settings, cache, rulesets, analytics, Workers and routes, and reads Pages, R2, KV, D1 and Registrar.
Is my API token safe?
It is checked with Cloudflare before it is saved, stored encrypted, never shown again and never written to logs. Remove it on the card, and roll or delete it in Cloudflare, at any time.
Can I limit the agent to some domains?
Yes — scope the token to those zones in Cloudflare, or add a Forbidden Rule ("MCP may only manage example.com") that refuses changes anywhere else.
Connect Cloudflare and try it on your own account

Start free — 2,500 credits a month, no credit card. Reads run at once; by default every write waits for your approval.

Related platforms

How the agent works