---
title: Cloudflare Blocking Claude or ChatGPT? 5 Easy Fixes That Work
url: https://handymcp.com/cloudflare-blocking-claude-chatgpt-wordpress/
description: Cloudflare blocking Claude or ChatGPT on WordPress? Let AI apps connect with 5 easy fixes and one Skip rule, while the rest of your site stays protected.
---

[Home](https://handymcp.com/)[Blog](https://handymcp.com/blog/)[Guides](https://handymcp.com/category/guides/)

# Cloudflare Blocking Claude or ChatGPT on WordPress? 5 Easy Fixes

By HandyMCP October 15, 2026 12 min read

![Cloudflare blocking Claude or ChatGPT on WordPress](https://handymcp.com/wp-content/uploads/2026/10/cloudflare-blocking-claude-chatgpt-wordpress-featured-1024x538.webp)

On this page

1. Why Cloudflare blocks AI apps
2. How to know Cloudflare is the problem
3. Fix 1: Turn off Bot Fight Mode
4. Fix 2: Check Under Attack mode and Security Level rules
5. Fix 3: Allow AI agents
6. Fix 4: Add a Cloudflare Skip rule for the HandyMCP paths
7. Fix 5: Test again and reconnect
8. Cloudflare settings at a glance
9. Don’t forget Cloudflare caching
10. Which addresses AI apps actually use
11. How HandyMCP protects these paths on its own
12. Test from the command line
13. Keep it working after changes
14. What to do while you wait for changes
15. Agencies managing many sites
16. A short checklist
17. Is this safe?
18. Cloudflare in front of other firewalls
19. Still blocked?
20. Common Cloudflare mistakes
21. Cloudflare FAQ

Your WordPress site sits behind Cloudflare, you connect Claude or ChatGPT, and it fails: a 403, a “couldn’t register” message, or a connection that works one minute and breaks the next. Your browser loads the site perfectly, which makes it confusing.

The reason is simple. AI apps do not connect from your browser. They connect from their own servers, and to Cloudflare those requests look like bots. This guide shows you how to let them through on the few addresses they need, while the rest of your site keeps full Cloudflare protection.

**Quick answer:**  In Cloudflare, turn off Bot Fight Mode, make sure Under Attack mode is off, allow AI agents in the AI bot settings, and add one Skip rule for `/wp-json/handymcp/`, `/.well-known/oauth`, `/handymcp/oauth/`, `/register`, `/token` and `/authorize`. Then click **Check again**  on the HandyMCP Connection screen.

![HandyMCP Connection screen with the WordPress MCP server URL used by Claude and ChatGPT](https://handymcp.com/wp-content/uploads/2026/10/handymcp-connect-claude-chatgpt-to-wordpress-mcp-server.webp)
The HandyMCP Connection screen, where you run Check again after changing Cloudflare.

## Why Cloudflare blocks AI apps

Cloudflare’s job is to stop automated traffic you did not ask for. It looks at where a request comes from, how it behaves and whether it can run JavaScript. A real visitor in a browser passes easily. A request from a data center that cannot solve a challenge page looks like a bot, because technically it is one.

Claude and ChatGPT connect to your site through the [Model Context Protocol](https://modelcontextprotocol.io/). When they sign in and use tools, the requests come from Anthropic’s and OpenAI’s servers. Those servers cannot click a checkbox or wait on a “Just a moment…” page, so Cloudflare either challenges them or blocks them outright.

That is not a fault in the firewall. It just cannot tell, on its own, that you invited these particular bots. The fix is to tell Cloudflare which addresses the AI apps need, and leave everything else as it is.

## How to know Cloudflare is the problem

Open **HandyMCP > Connection**  and click **Check again** . The connection check says **Cloudflare answered** , reports a browser challenge (“Just a moment…”) or shows a Cloudflare error code. It also tests a request that identifies as Claude, so it can tell a general block from a rule aimed at AI bots.

In the Cloudflare dashboard, open **Security > Analytics > Events**  and look at the newest block or challenge. The **Service**  and **Rule ID**  tell you exactly which feature blocked it.

| Error or event | Cause |
| --- | --- |
| Challenge page, “Just a moment…” | Bot Fight Mode, Under Attack mode or a Security Level setting |
| 1020 | A WAF custom rule |
| 1010 | Browser Integrity Check |
| 1015 | A rate limiting rule |
| 1006 to 1009 | An IP or country block |
| Rule ID `iuam` | Under Attack mode |

## Fix 1: Turn off Bot Fight Mode

Go to **Security > Settings > Bot traffic**  and turn off **Bot Fight Mode** . On the Cloudflare Free plan it ignores Skip rules, so it keeps blocking AI app servers whatever else you configure. This is the most common cause by far.

Turning it off does not leave your site open. Cloudflare’s other protections, including the managed rules and DDoS protection, keep running. Bot Fight Mode is a blunt tool that challenges almost all automated traffic, and in practice most small sites lose very little by switching it off.

## Fix 2: Check Under Attack mode and Security Level rules

Under **Overview > Quick Actions** , Under Attack Mode must be off.

Also check **Rules > Configuration Rules**  and **Page Rules** . A rule that sets Security Level to “I’m Under Attack” turns it on even when the Overview switch is off, and a Skip rule cannot override it. Edit that rule and add this to the end of its expression, so it keeps protecting everything else:

```
and not starts_with(http.request.uri.path, "/wp-json/handymcp/") and not starts_with(http.request.uri.path, "/.well-known/oauth") and not starts_with(http.request.uri.path, "/handymcp/oauth/") and not http.request.uri.path in {"/register" "/token" "/authorize" "/wp-cron.php"}
```

## Fix 3: Allow AI agents

Under **Security > Settings > Configure AI bot policies**  (on some accounts called AI Crawl Control), set **Agent**  to Allow. This lets `Claude-User` and `ChatGPT-User` through. Blocking AI crawlers that train models is a separate setting, and you can keep that on.

The difference matters. A crawler collects pages for training without anyone asking. An agent acts for a specific person who asked it to, in this case you. The two are handled separately so you can block one and allow the other.

## Fix 4: Add a Cloudflare Skip rule for the HandyMCP paths

1. Open **Security > Security rules > Create rule > Edit expression** .
2. Paste:
  ```
  (starts_with(http.request.uri.path, "/wp-json/handymcp/") or starts_with(http.request.uri.path, "/.well-known/oauth") or starts_with(http.request.uri.path, "/handymcp/oauth/") or http.request.uri.path in {"/register" "/token" "/authorize"})
  ```
3. Set the action to **Skip** . Tick all remaining custom rules, rate limiting rules, managed rules and Super Bot Fight Mode rules. Under **More components to skip** , tick everything except Hotlink Protection.
4. Set the order to **First**  and deploy.

The HandyMCP Connection screen has this rule ready to copy, so you do not need to type it. The official [skip rule documentation](https://developers.cloudflare.com/waf/custom-rules/skip/) explains each option if you want the details.

## Fix 5: Test again and reconnect

Click **Check again**  on the Connection screen. When it is green, remove the connector in Claude or ChatGPT and add it again, so the app does not reuse a failed attempt. Rules apply within a few seconds, so there is no need to wait.

## Cloudflare settings at a glance

| Cloudflare setting | Where | What to set |
| --- | --- | --- |
| Bot Fight Mode | Security > Settings > Bot traffic | Off |
| Under Attack mode | Overview > Quick Actions | Off |
| Security Level rules | Rules > Configuration Rules, Page Rules | Exclude the HandyMCP paths |
| AI bot policy: Agent | Security > Settings | Allow |
| AI bot policy: Crawler | Security > Settings | Your choice, can stay blocked |
| Skip rule | Security > Security rules | HandyMCP paths, order First |
| Caching | Caching > Cache Rules | Bypass cache for the HandyMCP paths |

![HandyMCP limits settings for reads and changes per minute and sign-in blocking](https://handymcp.com/wp-content/uploads/2026/10/handymcp-rate-limits-and-history-settings.webp)
HandyMCP keeps its own rate limits on the MCP paths, even when Cloudflare skips them.

## Don’t forget Cloudflare caching

Cloudflare does not cache REST API responses by default, but a Cache Everything rule or an APO setup can catch them. A cached sign-in response causes failures that come and go, which are the hardest to track down.

To be safe, add a Cache Rule under **Caching > Cache Rules**  with the same expression as the Skip rule and the action **Bypass cache** . HandyMCP already sends no-cache headers on every response, so this is a belt and braces step. After adding it, purge the Cloudflare cache once.

## Which addresses AI apps actually use

It helps to know what each path in the rule is for. If you ever need to explain the rule to a colleague or your host, this is the short version:

| Path | What it does | Who calls it |
| --- | --- | --- |
| `/wp-json/handymcp/v1/mcp` | The MCP server itself. Every tool call goes here. | Claude, ChatGPT, Cursor and other apps |
| `/.well-known/oauth-protected-resource` | Tells the app which sign-in server protects your site. | Apps, once when connecting |
| `/.well-known/oauth-authorization-server` | Tells the app where to register, approve and get a token. | Apps, once when connecting |
| `/register` | Lets the app register itself and get a client ID. | Apps, once per app |
| `/authorize` and `/handymcp/oauth/authorize` | The approval page you see in your browser. | You, in your browser |
| `/token` | Swaps your approval for a token and refreshes it later. | Apps, regularly |

Only the MCP server path is busy. The others are called a handful of times when an app first connects and when its token is refreshed. That is why excluding them from bot checks has almost no effect on your overall protection.

## How HandyMCP protects these paths on its own

Once requests get past the edge, the plugin applies its own checks. These run on your server no matter what sits in front of it:

- **Every tool call needs a valid token.**  Requests without one get a 401 answer and nothing else.
- **Tokens are tied to an app and a user.**  Each app you approve gets its own token, linked to the WordPress user who approved it.
- **Scopes limit what an app can do.**  You choose them on the approval screen.
- **WordPress roles still apply.**  An app approved by an Editor can only do what an Editor can do.
- **Rate limits slow down abuse.**  Too many failed sign-in or token requests from one address are throttled.
- **Everything is logged.**  The activity log records each request, and content changes can be undone.

So the edge rule does not open a door. It removes a second, generic lock that AI apps cannot pick, while the specific lock built for them stays in place.

## Test from the command line

If you are comfortable with a terminal, you can see what an AI app sees. This request asks for the sign-in details the same way Claude does:

```
curl -i https://your-site.com/.well-known/oauth-protected-resource
```

A healthy answer starts with `HTTP/2 200` and shows a short block of JSON with your site address in it. If you get a 403, a 503 or an HTML page that mentions a challenge, the edge is still blocking. Run it again after each change; rules apply within seconds.

The MCP server should answer a plain request with 401, which is correct because no token was sent:

```
curl -i https://your-site.com/wp-json/handymcp/v1/mcp
```

A 401 with a `WWW-Authenticate` header means the request reached WordPress and the plugin answered. Anything else means something in between got there first.

## Keep it working after changes

Rules tend to drift. Someone adds a new block rule, a plugin turns on a stricter mode, or a temporary emergency setting gets left on. A few habits prevent surprises:

- **Name the Skip rule clearly,**  for example “Allow AI apps (HandyMCP)”, so nobody deletes it by mistake.
- **Keep it at the top of the list**  whenever you add new rules.
- **Turn Under Attack mode off again**  after an incident. It is easy to forget, and it blocks every AI app.
- **Glance at the connection check**  after any security change. HandyMCP also runs it daily in the background.

![Creating a HandyMCP access token with scopes and expiry for Claude Code](https://handymcp.com/wp-content/uploads/2026/10/create-a-handymcp-access-token-v103.webp)
An access token lets you keep working while the Cloudflare rules are sorted out.

## What to do while you wait for changes

Sometimes you cannot change the edge settings yourself. Maybe an agency manages the account, or a client has to approve the change first. You can still get work done in the meantime.

On the HandyMCP Connection screen, click **Connect with an access token instead** . The plugin creates a token and shows ready-made setups for Claude Code and Claude Desktop. A token connection skips the sign-in pages entirely, so it works even when the discovery and registration addresses are blocked. The MCP server path still needs to be reachable, but many blocks only affect the sign-in steps.

Treat tokens like passwords. Give each one a clear name, store it only in the app that uses it, and revoke it on the Connection screen once the sign-in flow works again.

## Agencies managing many sites

If you look after several client sites, set up the rule once as a template. Most edge providers let you copy a rule between zones or apply account-level rules to many sites at once. Use the same rule name everywhere so it is easy to find later.

It is also worth adding a line to your site handover notes: “AI app access is allowed on the HandyMCP paths only.” When a client or another developer reviews the security settings months later, they will know the rule is intentional and not a mistake. HandyMCP Pro’s client sites feature shows the connection status of every site in one place, so you can spot a site where the rule went missing before the client does.

## A short checklist

1. Bot Fight Mode off.
2. Under Attack mode off, and no rule that turns it on for the HandyMCP paths.
3. AI agents allowed. AI crawlers can stay blocked.
4. One Skip rule for the HandyMCP paths, set to run first, skipping all components except Hotlink Protection.
5. Cache bypassed for the same paths.
6. Connection check green after **Check again** .
7. Old connector removed in Claude or ChatGPT and added again.

Work through the list in order and most sites are connected within ten minutes. If one step does not apply to your account, skip it and move on; the connection check will tell you if anything is still in the way.

## Is this safe?

Yes. These rules only stop Cloudflare from challenging requests to the HandyMCP addresses. Every request still needs a sign-in you approved on your own site, or an access token you created. The connected app can only do what its scopes and your WordPress role allow, and HandyMCP has its own rate limits. The rest of your site keeps full Cloudflare protection.

Think of it like a staff entrance. The edge still guards the front door for everyone else. The staff entrance has its own lock, and only people you gave a key to can open it.

## Cloudflare in front of other firewalls

Cloudflare is often not the only layer. Many sites also run a WordPress security plugin or sit on a host with its own firewall. When the connection still fails after the Cloudflare changes, check these too:

- **Wordfence:**  add the HandyMCP paths to the allow list under Firewall > All Firewall Options, and check that rate limiting does not treat AI app servers as crawlers.
- **Sucuri:**  Sucuri’s own firewall can sit behind or instead of Cloudflare. Add the paths to its allow list.
- **Imunify360 or ModSecurity on your host:**  ask your host to allow the paths. The Connection screen has a ready-made ticket text.
- **SiteGround:**  the host has its own anti-bot captcha and treats `/.well-known/` in its own way. See our [SiteGround MCP guide](/siteground-mcp-wordpress/).

The connection check tests your server directly as well as through Cloudflare, so it can tell you which layer answered.

## Still blocked?

- **Cloudflare Zero Trust or Access**  in front of the site redirects every request to a login. Add a bypass policy for the same paths.
- **Another firewall behind Cloudflare**  (Wordfence, your host) can block too. See the section above.
- **Need to work now?**  Click **Connect with an access token instead**  on the Connection screen. Tokens skip the sign-in pages, which helps while you sort out the rules.

## Common Cloudflare mistakes

- **Adding the Skip rule but leaving Bot Fight Mode on.**  On the Free plan Bot Fight Mode wins. Turn it off.
- **Putting the Skip rule last.**  Rules run in order. If a block rule runs first, the Skip rule never gets a chance. Set it to First.
- **Skipping only some components.**  Leave a managed rule or rate limit unticked and it can still block the sign-in. Tick them all except Hotlink Protection.
- **Allowing IP addresses instead of paths.**  AI app IP ranges change without notice. A path rule keeps working.
- **Testing in the browser only.**  Your browser passes challenges that AI app servers cannot. Use the connection check instead.

## Cloudflare FAQ

### Do I need a paid Cloudflare plan?

No. Everything here works on the Free plan. The only Free plan limit is that Bot Fight Mode cannot be skipped by a rule, so it has to be off.

### Can I allow only Anthropic’s or OpenAI’s IP addresses?

You can, but their addresses change, and a stale list breaks connections silently. The path-based rule above is easier to maintain and just as safe, because HandyMCP checks every request itself.

### Will this affect my SEO or caching?

No. The rule only covers the HandyMCP paths, which are not pages visitors see. Make sure Cloudflare does not cache `/wp-json/handymcp/`; HandyMCP sends no-cache headers for these responses.

### Which WordPress MCP plugin works best behind Cloudflare?

HandyMCP is built for it. Its connection check recognises Cloudflare, tells you which feature blocked the request and gives you the Skip rule ready to copy, in the free plugin as well as Pro.

### Does this also work for Cursor and Claude Code?

Yes. Every MCP app connects from outside your browser, so the same Cloudflare rules apply to all of them.

Related: [fix the Claude sign-in service error](/claude-sign-in-service-error-wordpress/), [WordPress MCP not connecting: 12 fixes](/wordpress-mcp-not-connecting-fixes/) and the [troubleshooting guide](/docs/troubleshooting/).

Share this article

Written by the HandyMCP team

We build HandyMCP, the WordPress MCP server that lets Claude, ChatGPT and other AI apps manage your site with permissions and one-click undo.

 [Read the setup guide](https://handymcp.com/docs/)

On this page

12 min read

1. Why Cloudflare blocks AI apps
2. How to know Cloudflare is the problem
3. Fix 1: Turn off Bot Fight Mode
4. Fix 2: Check Under Attack mode and Security Level rules
5. Fix 3: Allow AI agents
6. Fix 4: Add a Cloudflare Skip rule for the HandyMCP paths
7. Fix 5: Test again and reconnect
8. Cloudflare settings at a glance
9. Don’t forget Cloudflare caching
10. Which addresses AI apps actually use
11. How HandyMCP protects these paths on its own
12. Test from the command line
13. Keep it working after changes
14. What to do while you wait for changes
15. Agencies managing many sites
16. A short checklist
17. Is this safe?
18. Cloudflare in front of other firewalls
19. Still blocked?
20. Common Cloudflare mistakes
21. Cloudflare FAQ

Let AI do this for you

Connect Claude or ChatGPT to WordPress and just ask. Every change is logged and site edits can be undone.

 [Get HandyMCP Pro](https://handymcp.com/#pricing)

Keep reading

## More from the *blog.*

[All articles](https://handymcp.com/blog/)

Guides Nov 5, 2026

### [WordPress MCP Adapter vs Plugins vs Hosted Relays: Which to Use](https://handymcp.com/wordpress-mcp-adapter-vs-plugins-vs-relays/)

There are three ways to connect AI apps to WordPress over MCP: the official MCP Adapter,…

Guides Nov 3, 2026

### [How Agencies Can Use AI Across Client WordPress Sites](https://handymcp.com/ai-for-wordpress-agencies/)

How WordPress agencies can use Claude and ChatGPT across many client sites: one AI connection, client…

Guides Oct 31, 2026

### [How to Find and Remove Malware in WordPress with AI](https://handymcp.com/find-remove-malware-wordpress-with-ai/)

Use Claude or ChatGPT with an MCP server to scan WordPress files and the database for…


<!-- Page uncached by LiteSpeed Cache 7.9.3 on 2026-11-24 14:22:41 -->