Cloudflare is blocking AI apps from my WordPress site: how to let MCP through
Why can't my AI app connect to a WordPress site behind Cloudflare?
Because some AI apps connect from their vendor's servers with a plain HTTP library, and Cloudflare's security features can treat that as a bad bot and stop it at the edge — before the request ever reaches WordPress. The app then reports something vague ("couldn't connect", "authorization failed", "the tool is unavailable"), while your site's logs show nothing at all, because WordPress never saw the request.
This is not specific to any one AI vendor. Apps that run in the cloud — ChatGPT, claude.ai, the Gemini app, Grok, Perplexity, Meta's Muse, n8n Cloud — all reach your MCP server from data-centre addresses, and each sends its own mix of headers. Whether Cloudflare lets a given app through depends on your zone's settings and on how that app's client looks to Cloudflare that week. Tools that run on your own computer (Claude Code, Cursor, Codex, the Gemini CLI) connect from your home or office address and are rarely affected.
We hit this ourselves on 14 October 2026, connecting Muse to one of our own sites: Muse's sign-in and token exchange passed, but every MCP call came back from Cloudflare as error 1010, which Cloudflare describes as "The owner of this website has banned your access based on your browser's signature". The culprit was Browser Integrity Check, and Muse's client identified itself as Python-urllib.
How do I know Cloudflare is the problem?
Three quick checks, in order:
- Run the Connection Doctor. In wp-admin go to Settings → Cowboy MCP → Connections and click Run checks under Connection Doctor. Starting with Cowboy MCP 1.7.4 (the next release), when the site is behind Cloudflare the Doctor says so up front, and its Cloudflare lets AI apps through check repeats a request to the MCP endpoint the way a script-based AI client sends it. A warning shows Cloudflare's error code (1010, 1020, a challenge) and the request's Ray ID.
- Look at Cowboy MCP's Logs tab. If the app says it tried and the Logs tab has no matching entry, the request stopped before WordPress.
- Look at Cloudflare's event log. In the Cloudflare dashboard, go to Security → Analytics → Events and find the blocked request. The Service field names the feature that blocked it, which tells you which section below applies.
Which URLs do AI apps need to reach?
One path prefix, and it is machine-to-machine: /wp-json/cowboy-mcp/ — the MCP endpoint itself, plus the sign-in registration and token routes the apps call from their servers.
Apps also read two small discovery documents under /.well-known/oauth- before they sign in, but they fetch them from their vendor's sign-in service, which got through in our tests even while Browser Integrity Check was refusing the same app's MCP calls. Leave them out of the rule unless Cloudflare's event log shows them blocked too.
The consent page where you click Approve opens in your own browser, which passes Cloudflare's checks like any other visit, so it needs no exception. Everything else on your site — pages, wp-admin, the login form — keeps every Cloudflare protection you have.
In Cloudflare's rule language, the prefix is:
starts_with(http.request.uri.path, "/wp-json/cowboy-mcp/")
How do I fix it?
Skip Browser Integrity Check for the MCP endpoint (all plans)
This is the fix for error 1010, and it is the one most sites need. Browser Integrity Check is on by default; it denies requests with headers commonly abused by spammers and challenges visitors with no user agent or a non-standard one — exactly what a server-side AI client looks like.
- In the Cloudflare dashboard, open your site and go to Security → Security rules.
- Select Create rule → Custom rules and give it a name such as "Let AI apps reach MCP".
- Under the rule expression, select Edit expression and paste the expression above.
- Under Choose action, select Skip, then select Browser Integrity Check in the list of products to skip. On Pro plans and above, also select All Super Bot Fight Mode rules.
- Select Deploy.
Custom rules are available on every Cloudflare plan, including Free.
Prefer to switch the check off rather than skip it? A configuration rule does the same job: go to Rules → Overview, select Create rule next to Configuration Rules, use the same expression, add Browser Integrity Check and set it to Off, then deploy.
Bot Fight Mode (Free plan)
If Cloudflare's event log shows Bot Fight Mode as the service, a rule will not help: Cloudflare documents that Bot Fight Mode cannot be bypassed or skipped by custom rules or Page Rules. Your choices are to turn it off under Security → Settings (filter by Bot traffic) or to move to a plan with Super Bot Fight Mode, which does support skip rules. Bot Fight Mode applies to the whole domain, so weigh what it is protecting before you switch it off.
Super Bot Fight Mode (Pro and above)
Covered by step 4 of the skip rule above: All Super Bot Fight Mode rules skips it for the MCP endpoint only.
AI bot policies (Agent traffic)
Cloudflare now lets every plan block AI traffic by behaviour — Search, Agent and Training — under Security → Settings → Configure AI bot policies. Agent covers "automated activity acting in real time on a person's behalf", which can include an AI app calling your site for you. Since 15 September 2026, new Cloudflare domains block Agent and Training traffic on pages with ads by default. If your Agent policy is set to Block (on all pages) and an AI app is refused, set it to Allow or Block on pages with ads — the MCP routes return JSON, not ad-carrying pages.
Error 1020, Under Attack mode, rate limits and country blocks
- Error 1020 means one of your own custom rules blocked the request. Find it in Security → Analytics → Events and add the expression above as an exception to it.
- I'm Under Attack mode challenges every request, and no AI app can solve a challenge. Turn it off when the attack is over, or use a configuration rule to turn it off for the MCP endpoint only.
- Rate limiting rules (error 1015) and country or IP blocks can catch a vendor's data-centre range. Exempt the MCP endpoint in those rules, or skip All rate limiting rules in the same skip rule.
Is it safe to skip these checks for the MCP endpoint?
Yes, because the endpoint is protected by WordPress, not by Cloudflare's guesswork about browsers. Every call to the MCP endpoint needs a valid sign-in token or API key, and a request without one gets a plain 401 answer. New apps can register only while you have New connections open on the Connections tab (it closes itself after 30 minutes), only from sign-in addresses on an allowlist of known AI vendors, and nothing is granted until an administrator clicks Approve on the consent page. Each connection can be read-only or limited to the tools you pick, every tool call is logged, and most changes can be undone.
Keep the exception narrow: skip only what is blocking AI apps (usually Browser Integrity Check) and only for /wp-json/cowboy-mcp/. Leave Cloudflare's WAF managed rules, DDoS protection and everything on the rest of your site as they are.
How do I confirm it worked?
Run the Connection Doctor again — the Cloudflare lets AI apps through check should pass — then ask the AI app something read-only, such as "What is this site's name and WordPress version?" The call should appear on Cowboy MCP's Logs tab within seconds. If one app still fails while the Doctor passes, look up its request in Security → Analytics → Events: Bot Fight Mode and AI bot policies judge each vendor's own servers, which a test from your server cannot imitate.
FAQ
What does Cloudflare error 1010 mean for an AI app?
Error 1010 means Cloudflare's Browser Integrity Check refused the request because of its browser signature — usually a server-side HTTP library's user agent, such as Python-urllib. AI apps that call your site from their vendor's cloud can trip it. Skip Browser Integrity Check for /wp-json/cowboy-mcp/ with a custom rule, and the app can connect.
Does Cloudflare block ChatGPT, Claude and Gemini from WordPress?
It can. Any AI app that connects from its vendor's servers can be challenged or blocked by Browser Integrity Check, Bot Fight Mode, AI bot policies, Under Attack mode or your own firewall rules, depending on your zone's settings. Whether a particular app is affected depends on how its client looks to Cloudflare, so test with the Connection Doctor and check Security → Analytics → Events.
Can I skip Bot Fight Mode for the MCP endpoint?
No. Cloudflare documents that Bot Fight Mode, the Free-plan bot feature, cannot be skipped by custom rules or Page Rules. If it blocks an AI app, turn it off under Security → Settings, or upgrade to Super Bot Fight Mode, which supports skip rules for specific paths.
Is it safe to skip Browser Integrity Check for /wp-json/cowboy-mcp/?
Yes. The MCP endpoint does its own authentication: every call needs a sign-in token or an API key, new apps can only register while you have New connections open and after an administrator approves them, and every tool call is logged. Skip only Browser Integrity Check, only for /wp-json/cowboy-mcp/, and keep the rest of Cloudflare's protection in place.