---
title: "Error 1006 Access Denied: Cloudflare 1006 and 1010"
url: https://proxy.wiki/guides/cloudflare-error-1006-1010/
type: Guide
author: "proxy.wiki editorial"
published: 2026-10-21
updated: 2026-10-21
site: proxy.wiki
topics: ["Anti-bot systems"]
license: CC BY 4.0; quote freely with attribution to https://proxy.wiki/
---

# Error 1006 Access Denied: Cloudflare 1006 and 1010

> Cloudflare error 1006 means the site owner banned your IP; 1010 means your client signature. How to tell them from proxy and WebSocket 1006 errors.

## Key takeaways

- Cloudflare error 1006 (and 1007, 1008, 1106) means the site owner banned the IP address your request came from. It returns HTTP 403 and only the owner can lift it.
- Error 1010 is the same kind of block keyed on the client's signature. On our own zone, Python's urllib, sqlmap and Nikto User-Agents got it while curl, requests and httpx did not.
- A Cloudflare 10xx block arrives through a working proxy tunnel with server: cloudflare and a cf-ray header. A proxy refusal ends at CONNECT and shows up as curl exit 56 or a ProxyError.
- WebSocket close code 1006 is unrelated to Cloudflare. Browsers report it for every failed or abnormally closed socket, and the console line printed before it holds the real cause.
- Give the site owner the Ray ID and UTC time from the page. Cloudflare's Security Events keep sampled events for up to 31 days.

**Error 1006** is a Cloudflare page. It means the owner of the website you asked for has banned your IP address. Cloudflare files 1007, 1008 and 1106 under the same heading, _Access Denied: Your IP address has been banned_, and [returns all four with HTTP status 403](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/). Only the site owner can lift it. Cloudflare’s own page for the error says its support team cannot override a customer’s security settings.

**Error 1010** is the same kind of block keyed on something else: the owner’s settings matched your browser’s signature, not your address. If you met “1006” in a WebSocket `close` event instead of on a web page, skip to [WebSocket close code 1006](#websocket-1006). That one has nothing to do with Cloudflare.

## What the page and the raw response look like

We could not produce a 1006 without adding a ban rule to a Cloudflare zone, and we did not change any rule. A 1010 we could capture for real, from the Cloudflare edge in front of this site’s own hostname, by sending the User-Agent `sqlmap/1.8` (the name of a SQL-injection testing tool). This is the text Chrome 155 rendered:

```
Error 1010 Ray ID: a4e2d0e40f4fd0ec • 2026-10-21 19:54:45 UTC
Access denied
What happened?

The owner of this website (proxy.wiki) has banned your access based on your browser's signature (a4e2d0e40f4fd0ec-ua47).

Please see https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/ for more details.
```

The tab title was `Access denied | proxy.wiki used Cloudflare to restrict access | proxy.wiki | Cloudflare`. A 1006 page uses the same layout. Only the sentence under “What happened?” changes: it says the owner “has banned your IP address” and prints the address, as in [this user’s report from a real 1006](https://forums.garmin.com/developer/connect-iq/f/discussion/208786/access-denied-error-1006).

Scripts often never see that page. With curl’s defaults, Cloudflare answered with 17 bytes of plain text:

```
$ curl -si -A 'sqlmap/1.8' https://proxy.wiki/
HTTP/2 403
content-type: text/plain; charset=UTF-8
content-length: 17
cache-control: private, max-age=0, no-store, no-cache, must-revalidate, post-check=0, pre-check=0
server: cloudflare
cf-ray: a4e2cd6d6e8b5a3c-SOF

error code: 1010
```

What decided the format surprised us. It was not the `Accept` header: `Accept: text/html` still got the plain text. It was whether the request carried any `Accept-Encoding` header. With one, even `Accept-Encoding: identity`, the response was the 7,133-byte HTML page. Without one, it was the 17-byte line. requests, httpx and Node’s fetch all send that header by default, so they get HTML; curl does not, so it gets plain text. Our [survey of default request headers](/research/default-request-headers/) lists what each client sends. If you parse for the code, match both `error code: 1010` and the `errorCode: 1010` that the HTML page carries in its inline script.

**How these results were produced.** All tests ran on 21 October 2026 from one Mac (macOS 26.6.2, arm64). Cloudflare responses came from the edge in front of this site’s own hostname; we changed no Cloudflare setting. Clients: Google Chrome 155.0.8059.85 headless, driven over the DevTools protocol; curl 8.7.1; Python 3.9.6 with requests 2.32.3, httpx 0.27.2 and urllib; Python 3.15.0 urllib; Node.js v24.2.0 (bundled undici 7.10.0). Proxies: Squid 6.13 and a small TLS-intercepting proxy we wrote for the test, both on 127.0.0.1, plus a stdlib Python WebSocket server. Each case ran once unless a count is given. The User-Agent table ran two rounds of 17 requests.

## The Cloudflare access-denied codes

Cloudflare puts the 1xxx code in the body of the response and an ordinary HTTP status in the header. Logs that keep only the status show 403. The code tells you which kind of rule matched.

| Code | Cloudflare’s title | HTTP status | What the owner’s setting matched |
| --- | --- | --- | --- |
| 1005 | Access Denied: Autonomous System Number (ASN) banned | 403 | The network your IP address belongs to |
| 1006, 1007, 1008, 1106 | Access Denied: Your IP address has been banned | 403 | Your IP address |
| 1009 | Access Denied: Country or region banned | 403 | The country of your IP address |
| 1010 | The owner of this website has banned your access based on your browser’s signature | 403 | Your client’s signature (Browser Integrity Check) |
| 1015 | You are being rate limited | 429 | How fast you sent requests |
| 1020 | Access denied | 403 | A security rule with a Block action and no custom response |

Cloudflare’s documentation does not say what separates 1006 from 1007, 1008 or 1106. Treat them as one error. Its 1006 page adds one odd case: the Preview tab in the Workers dashboard shows 1006 when a zone blocks the Google Cloud addresses that Preview uses. The 1015 rate-limit page has [its own logic](/glossary/rate-limiting/). One more trap: a block from a WAF custom rule [does not carry a 10xx code at all](https://developers.cloudflare.com/waf/reference/legacy/firewall-rules-upgrade/). It shows Cloudflare’s WAF block page or whatever custom response the owner set.

## First question: did Cloudflare say no, or did your proxy?

Through an HTTPS proxy, a Cloudflare block arrives inside a tunnel that worked. The proxy answers [CONNECT](/glossary/http-connect/) with 200, TLS runs end to end, and the 403 comes from the site’s edge. A proxy that refuses never lets the request reach Cloudflare. curl’s verbose output separates the two in two lines. Here is the Cloudflare case through a local Squid:

```
$ curl -sv -x http://127.0.0.1:46128 -A 'sqlmap/1.8' https://proxy.wiki/
* Establish HTTP proxy tunnel to proxy.wiki:443
< HTTP/1.1 200 Connection established
* CONNECT tunnel established, response 200
< HTTP/2 403
< content-type: text/plain; charset=UTF-8
< server: cloudflare
< cf-ray: a4e2d88cebb6263a-SOF
error code: 1010
```

And here is Squid refusing the tunnel itself, because port 8443 is not in its allowed list:

```
$ curl -sSv -x http://127.0.0.1:46128 https://proxy.wiki:8443/
* Establish HTTP proxy tunnel to proxy.wiki:8443
< HTTP/1.1 403 Forbidden
< Server: squid/6.13
< X-Squid-Error: ERR_ACCESS_DENIED 0
< Via: 1.1 pw-test-proxy (squid/6.13)
* CONNECT tunnel failed, response 403
curl: (56) CONNECT tunnel failed, response 403
```

Libraries make the difference even plainer. A Cloudflare block is a response. A proxy refusal is an exception.

| Case | curl 8.7.1 | requests 2.32.3 | httpx 0.27.2 |
| --- | --- | --- | --- |
| Cloudflare 1010 through a working tunnel | exit 0, HTTP 403, error code: 1010 | no exception, status_code 403, server: cloudflare | no exception, status_code 403 |
| Proxy refused CONNECT | curl: (56) CONNECT tunnel failed, response 403 | ProxyError(... 'Tunnel connection failed: 403 Forbidden') | httpx.ProxyError: 403 Forbidden |
| Proxy wanted credentials | curl: (56) CONNECT tunnel failed, response 407 | ProxyError(... 'Tunnel connection failed: 407 Proxy Authentication Required') | httpx.ProxyError: 407 Proxy Authentication Required |

This helper turns that into one line per request. It ran as shown with requests 2.32.3:

```
import re
import requests

CF_CODE = re.compile(r"error code: (\d{4})|errorCode:\s*(\d{4})")

def who_blocked(url, proxy=None, **kw):
    proxies = {"http": proxy, "https": proxy} if proxy else None
    try:
        r = requests.get(url, proxies=proxies, timeout=20, **kw)
    except requests.exceptions.ProxyError as e:
        return f"PROXY refused before the site saw anything: {e.__context__ or e}"
    m = CF_CODE.search(r.text[:20000])
    if r.headers.get("server") == "cloudflare" and "cf-ray" in r.headers and m:
        return f"CLOUDFLARE {m.group(1) or m.group(2)} (HTTP {r.status_code}, Ray ID {r.headers['cf-ray']})"
    return f"HTTP {r.status_code} from the site itself (server={r.headers.get('server')})"

print(who_blocked("https://proxy.wiki/", "http://127.0.0.1:46128", headers={"User-Agent": "sqlmap/1.8"}))
```

```
CLOUDFLARE 1010 (HTTP 403, Ray ID a4e2da30df0f1bd4-SOF)
PROXY refused before the site saw anything: HTTPSConnectionPool(host='proxy.wiki', port=8443): ... Tunnel connection failed: 403 Forbidden
PROXY refused before the site saw anything: HTTPSConnectionPool(host='proxy.wiki', port=443): ... Tunnel connection failed: 407 Proxy Authentication Required
HTTP 200 from the site itself (server=cloudflare)
```

The first three lines are our test cases: Cloudflare’s 1010, Squid’s port refusal and Squid’s 407. The last is the control with a normal User-Agent. For more on reading these status codes side by side, see [403 vs 407 vs 429](/guides/403-vs-407-vs-429/).

## The causes, most common first

### 1. Your address, or your proxy’s exit address, is on the owner’s ban list

This is 1006, 1007, 1008 and 1106. The owner added an [IP Access rule](https://developers.cloudflare.com/waf/tools/ip-access-rules/) or similar block covering the address Cloudflare saw. Those rules accept a single IPv4 or IPv6 address, a range such as a /24 or a /64, an [ASN](/glossary/asn/) or a country. A range rule catches your neighbours too.

The address Cloudflare saw is often not “yours”. Behind a VPN, a proxy pool, an office gateway or [carrier-grade NAT](/glossary/carrier-grade-nat/), many people leave through the same address, and one ban covers all of them. A rotating proxy makes it intermittent: some requests leave from a banned exit and some do not, which is why 1006 can come and go between page loads. [Rotating vs sticky sessions](/guides/rotating-vs-sticky-sessions/) covers how exits change.

**Diagnose.** Cloudflare serves a [trace endpoint](https://developers.cloudflare.com/fundamentals/reference/cdn-cgi-endpoint/) on every zone it proxies. It prints the address and country the edge saw. Run it once directly and once through the proxy, against the same site:

```
$ curl -s https://proxy.wiki/cdn-cgi/trace
fl=74f110
h=proxy.wiki
ip=<your address, masked here>
visit_scheme=https
uag=curl/8.7.1
colo=SOF
http=http/2
loc=BG
tls=TLSv1.3
warp=off

$ curl -s -x http://user:pass@gw.example.net:8080 https://proxy.wiki/cdn-cgi/trace | grep -E '^(ip|loc)='
```

If the two `ip=` lines differ and only the proxied request gets 1006, the ban is on the exit. On our zone the trace endpoint answered 200 to the same `sqlmap/1.8` request that the home page blocked with 1010. We did not test whether it also answers a banned address, so if it fails, compare against `https://www.cloudflare.com/cdn-cgi/trace` instead.

**Fix.** As a visitor, stop sending traffic from the banned exit and write to the owner with the Ray ID, the UTC time from the page and the address. As an owner, see the section for site owners below. Do not open a ticket with Cloudflare for someone else’s site; its 1006 page says plainly that support cannot override the owner.

### 2. Your client’s signature tripped Browser Integrity Check

This is 1010. Cloudflare’s [Browser Integrity Check](https://developers.cloudflare.com/waf/tools/browser-integrity-check/) looks for HTTP headers that spammers commonly abuse and challenges requests with a missing or non-standard [User-Agent](/glossary/user-agent/). Cloudflare enables it by default. Which strings it objects to is not published, so we tested our own zone, two rounds, one GET each:

| User-Agent sent | Round 1 | Round 2 |
| --- | --- | --- |
| curl/8.7.1 (curl’s default) | 200 | 200 |
| Empty, or no User-Agent header at all | 200 | 200 |
| python-requests/2.32.3, python-httpx/0.27.2 | 200 | 200 |
| node, Go-http-client/1.1, Wget/1.21.4 | 200 | 200 |
| Scrapy/2.11.2 (+https://scrapy.org) | 200 | 200 |
| Chrome 155 desktop, and the same string with HeadlessChrome | 200 | 200 |
| Nmap Scripting Engine, masscan/1.3, WPScan v3.8.25 | 200 | 200 |
| Python-urllib/3.9 | 403, 1010 | 403, 1010 |
| sqlmap/1.8 | 403, 1010 | 403, 1010 |
| Nikto/2.1.6 | 403, 1010 | 403, 1010 |

The Python row is the one that catches people. A script using only the standard library gets 1010 on a zone where the same script written with requests loads fine. We confirmed it with real `urllib.request` calls, not just the string: Python 3.9.6 and Python 3.15.0 (which sends `Python-urllib/3.15`) both got `HTTPError 403` with `error code: 1010`. Note that urllib raises on a 403 while requests returns it, so the same block looks like a crash in one and a status code in the other. The empty User-Agent passing surprised us too, given what the documentation says. This is one zone on one day, so read it as an example, not as Cloudflare’s list.

**Diagnose.** Send the same request from the same address with a different client. If one gets 1010 and another gets 200, the address is fine and the signature is the trigger. In a browser, suspect extensions that rewrite the User-Agent or strip headers.

**Fix.** The owner can turn Browser Integrity Check off for the zone or skip it for one path, such as an API, with a configuration rule or a custom rule using the Skip action. A visitor cannot change the setting. When you write to the owner, quote the code in brackets after “browser’s signature”, `a4e2d0e40f4fd0ec-ua47` in our capture, along with the Ray ID. Neither Cloudflare page explains the suffix, so pass it on whole. If the client is your own script, give it a User-Agent that names the tool and a contact address; that is what an owner needs in order to allow it.

### 3. The owner blocked a whole network or country

1005 blocks an ASN and 1009 a country. Proxy users meet both: datacenter proxy addresses sit inside hosting providers’ ASNs, so one ASN rule covers many of them, and a [residential or datacenter exit](/guides/residential-vs-datacenter-proxies/) chosen in one country carries that country’s ban. Cloudflare’s documentation notes that country blocks through IP Access rules are an Enterprise feature; on other plans owners block countries with custom rules, which show the WAF block page rather than 1009. Diagnose with the trace endpoint’s `loc=` line. The fix is again the owner’s.

### 4. Your proxy refused the tunnel (not a Cloudflare error)

Squid’s stock configuration contains `http_access deny CONNECT !SSL_ports`, and proxies built from that file inherit the rule. Any HTTPS or `wss://` address on a port outside the list fails at CONNECT. You saw the output above: `X-Squid-Error: ERR_ACCESS_DENIED 0`, curl exit 56, `ProxyError` in Python. There is no `cf-ray` header because Cloudflare never saw the request. Fix it on the proxy side: ask for the port to be allowed, or use the standard port. Our [curl proxy guide](/guides/how-to-use-a-proxy-with-curl/) shows how to print the CONNECT exchange.

### 5. Proxy authentication failed

Squid answered 407 with `Proxy-Authenticate: Basic realm="pw-test"`. curl reported `CONNECT tunnel failed, response 407`; requests and httpx raised `ProxyError` with `407 Proxy Authentication Required`. With the right `user:pass` in the proxy URL the tunnel opened and Cloudflare’s 1010 came back as before. Wrong credentials never produce a 10xx page. See [proxy authentication](/glossary/proxy-authentication/) and [proxies in Python](/guides/proxies-in-python-requests-httpx/) for where the credentials go.

### 6. A TLS-intercepting proxy sits in the path

Office networks and some security products run a [TLS-intercepting proxy](/glossary/tls-interception/). It decrypts your traffic and opens its own connection to the site, so Cloudflare sees the proxy’s address and the proxy’s TLS handshake. A 1006 aimed at that address hits everyone in the building. Through our intercepting proxy, curl without `-k` stopped with `curl: (60) SSL certificate problem: self signed certificate`. With `-k` the request went through, as `HTTP/1.1` because our proxy offered no HTTP/2, and Cloudflare still answered `403` with `error code: 1010`. To see whether interception is happening, check who issued the certificate:

```
$ echo | openssl s_client -connect proxy.wiki:443 -proxy 127.0.0.1:46130 -servername proxy.wiki 2>/dev/null | openssl x509 -noout -issuer
issuer=CN=pw-test intercepting proxy

$ echo | openssl s_client -connect proxy.wiki:443 -proxy 127.0.0.1:46128 -servername proxy.wiki 2>/dev/null | openssl x509 -noout -issuer
issuer=C=US, O=Google Trust Services, CN=WE1
```

The first command went through the intercepting proxy, the second through Squid, which only tunnels. If the issuer is your company’s CA, the ban is on its egress address, and the fix goes through your network team and the site owner.

### 7. The proxy could not reach the site

When the upstream connection fails, Squid answers CONNECT with `503`. Our log line read `TCP_TUNNEL/503 CONNECT 127.0.0.1:46099 ... ERR_CONNECT_FAIL/errno=61`, errno 61 being “connection refused” on macOS. Clients show it as another CONNECT failure. It is the proxy reporting that the far end refused, and it carries no Cloudflare code.

## WebSocket close code 1006

The second common “error 1006” is a WebSocket close code. [RFC 6455](https://www.rfc-editor.org/rfc/rfc6455) reserves 1006 for a connection that ended abnormally, without a Close frame being sent or received. No endpoint may put it in a Close frame. Your own client reports it when the socket dies. The [WHATWG WebSockets standard](https://websockets.spec.whatwg.org/) then requires browsers to report 1006 for an unresolvable host, a refused port, a failed TLS handshake, a non-WebSocket server and an abrupt close alike, so that a page cannot probe your local network. The close event tells you nothing. The console does.

We reproduced each case against a local WebSocket server, directly and through Squid and the intercepting proxy:

| What happened | Chrome 155 console message | Chrome close code | Node.js 24.2.0 |
| --- | --- | --- | --- |
| Control: client closed normally | none | 1000 | 1000 |
| Server dropped TCP after the handshake | none | 1006 | 1006 |
| Endpoint answered 200 instead of 101 | Error during WebSocket handshake: Unexpected response code: 200 | 1006 | 1002 |
| Nothing listening on the port | net::ERR_CONNECTION_REFUSED | 1006 | 1002 |
| Server certificate not trusted | net::ERR_CERT_AUTHORITY_INVALID | 1006 | 1002 |
| Proxy refused CONNECT (Squid 403) | Establishing a tunnel via proxy server failed. | 1006 | — |
| Proxy wanted credentials (407) | Proxy authentication failed | 1006 | — |
| Proxy could not reach the server (Squid 503) | Establishing a tunnel via proxy server failed. | 1006 | — |
| Intercepting proxy re-signed TLS | net::ERR_CERT_AUTHORITY_INVALID | 1006 | — |
| Proxy idle timeout (Squid read_timeout 5 seconds) | none | 1006 | — |

We did not run the proxied cases in Node. Two results stood out. First, Node 24.2.0 does not follow the browser rule: its bundled undici 7.10.0 closes every failed handshake with `1002` and the reason `Received network error or non-101 status code.`, which is [written into its source](https://github.com/nodejs/undici/blob/v7.10.0/lib/web/websocket/connection.js). Code that only checks for 1006 misses those. Second, Chrome 155 blocked our first attempt with `net::ERR_BLOCKED_BY_LOCAL_NETWORK_ACCESS_CHECKS`, also as 1006, because the script ran on `about:blank` and the server was on 127.0.0.1. Chrome’s [Local Network Access](https://developer.chrome.com/blog/local-network-access) restrictions target public pages that reach into private or loopback addresses, so a web app talking to a local agent or a LAN device can meet the same 1006.

The idle case deserves numbers, because it looks random in production. With Squid’s `read_timeout` at 5 seconds, an open but silent WebSocket through the tunnel was closed three times out of three, and each time the browser reported 1006 with no console message. The same test through a Squid at its default timeout, which [Squid documents as 15 minutes](https://www.squid-cache.org/Doc/config/read_timeout/), was still open when we stopped it at 12 seconds.

_Time from open to close code 1006 for an idle WebSocket through Squid 6.13 with read\_timeout 5 seconds, Chrome 155, three runs_

| Run | Milliseconds until close 1006 |
| --- | --- |
| Run 1 | 4438 |
| Run 2 | 5658 |
| Run 3 | 5324 |

Cloudflare does the same thing to idle WebSockets. Its [WebSockets documentation](https://developers.cloudflare.com/network/websockets/) says it closes a connection when no data moves in either direction for a period, and that a code release can restart servers and drop live connections. It gives no default figure. The cure for both is a heartbeat: send a ping or a small message more often than the shortest idle timeout on the path, and reconnect with [exponential backoff](/glossary/exponential-backoff/) when a close does come.

To see what your own client reports, paste this into the browser console, then read the error line Chrome prints above it:

```
const ws = new WebSocket('wss://example.com/socket');
ws.onclose = e => console.log('close', e.code, 'wasClean=' + e.wasClean, JSON.stringify(e.reason));
```

And the Node.js version we ran (v24.2.0, built-in `WebSocket`, no packages). Our [Node.js proxy guide](/guides/proxies-in-nodejs/) covers sending Node traffic through a proxy.

```
// node ws_node.mjs wss://example.com/socket
const t0 = Date.now();
const ws = new WebSocket(process.argv[2]);
ws.onopen = () => { console.log(`open after ${Date.now() - t0} ms`); ws.send('hello'); };
ws.onmessage = (e) => { console.log(`message: ${e.data}`); ws.close(1000, 'done'); };
ws.onclose = (e) => console.log(`close: code=${e.code} wasClean=${e.wasClean} reason=${JSON.stringify(e.reason)}`);
```

```
$ node ws_node.mjs ws://127.0.0.1:46080/drop
open after 17 ms
close: code=1006 wasClean=false reason="" after 1017 ms
$ node ws_node.mjs ws://127.0.0.1:46080/notws
error event: Received network error or non-101 status code.
close: code=1002 wasClean=false reason="Received network error or non-101 status code." after 15 ms
```

## Cause-to-fix table

| What you see | Who sent it | Cause | Check | Fix |
| --- | --- | --- | --- | --- |
| Cloudflare page, Error 1006, 1007, 1008 or 1106 | Cloudflare, on the owner’s rule | Your IP address or your proxy’s exit is banned | /cdn-cgi/trace directly and through the proxy; compare ip= | Owner removes or narrows the rule; visitor sends the Ray ID and time |
| Error 1010, or error code: 1010 | Cloudflare, Browser Integrity Check | Client signature, such as the User-Agent | Same address, different client: does it pass? | Owner turns the check off or skips it for the path |
| Error 1005 or 1009 | Cloudflare, on the owner’s rule | Your ASN or country is blocked | loc= in the trace output | Owner allows the network or country |
| curl: (56) CONNECT tunnel failed, response 403, no cf-ray | Your proxy | Proxy policy, often a port outside its allowed list | curl -v: no “tunnel established” line | Allow the port on the proxy or use 443 |
| response 407 or ProxyError ... 407 | Your proxy | Missing or wrong proxy credentials | Look for Proxy-Authenticate | Put the right user:pass in the proxy URL |
| curl: (60) SSL certificate problem through a work network | An intercepting proxy | The proxy re-signs TLS | openssl s_client -proxy, read the issuer | Trust the company CA or get the host exempted |
| Squid 503, ERR_CONNECT_FAIL | Your proxy | Proxy could not reach the site | Proxy access log | Check the target host and port from the proxy |
| WebSocket close 1006 (or 1002 in Node) | Your own client | Connection failed or died without a Close frame | Browser console, DevTools network tab | Fix the cause the console names; add a heartbeat for idle drops |

## For site owners: finding why a visitor got 1006 or 1010

- Ask for the Ray ID and the UTC time shown on the page. The [Ray ID](https://developers.cloudflare.com/fundamentals/reference/cloudflare-ray-id/) is also in the `cf-ray` response header, so a developer can copy it from `curl -v`.

- Open Security Events under Security, Analytics, and filter by that Ray ID or the visitor’s address. [Every plan](https://developers.cloudflare.com/waf/analytics/security-events/) gets sampled logs reaching back up to 31 days, so a report older than that cannot be traced. Cloudflare warns that sampling can hide an event; narrow the time window if the search comes back empty.

- If an IP Access rule matched, delete or narrow it. Cloudflare now recommends custom rules with IP lists over IP Access rules for this job.

- If the event shows Browser Integrity Check, turn it off in Security Settings or skip it for the paths your API clients use.

- Be careful with “allow”. Cloudflare notes that an IP or ASN allow rule also bypasses custom rules, rate limiting rules and WAF managed rules for that source.

- Think twice before banning a single address that many people share. A mobile carrier’s NAT address, a university gateway or a popular VPN exit puts a 1006 in front of everyone behind it.

Cloudflare’s 1xxx pages can also be replaced with your own through Custom Errors, which is a good place to say how a blocked visitor can reach you.

## Frequently asked questions

### Can Cloudflare support remove an error 1006?

No. Cloudflare's documentation for 1006 says the website owner set the block and that Cloudflare support cannot override a customer's security settings. Contact the owner of the site, with the Ray ID and the time from the page.

### How long does an error 1006 ban last?

The page gives no duration. The block lasts until the owner changes the rule that matched your address. If you use a rotating proxy, it can seem to come and go, because only some of your exits are covered by the rule.

### Why do I get error 1006 only through a VPN or proxy?

Because the site sees the VPN's or proxy's exit address, not yours, and that address is the one on the ban list. Shared exits collect bans from other users' traffic. Run the /cdn-cgi/trace check with and without the proxy to confirm which address Cloudflare saw.

### What is the difference between error 1006 and error 1020?

1006 is a ban on your IP address. 1020 means a Cloudflare security rule with a Block action matched your request and the owner set no custom response for it. Both return HTTP 403, and both are the owner's decision.

### Why does my Python script get error 1010 when my browser works?

On our own Cloudflare zone, Python's standard library User-Agent, Python-urllib/3.9 or /3.15, got 1010 in every attempt, while requests and httpx defaults loaded the page. Browser Integrity Check judges the client's signature, so two clients on one address can get different answers. Ask the site owner to allow your client, and identify it honestly.

### What does WebSocket error 1006 mean?

It means the connection closed abnormally, without a Close frame. Browsers use it for every kind of failure, including a refused proxy tunnel, failed proxy sign-in, an untrusted certificate and an idle timeout. The browser console names the real cause in the line printed just before the close event.

### Will clearing cookies or the cache fix error 1006?

No. Cloudflare's 1006 is keyed on the IP address your request came from, and neither cookies nor the cache change that. A 1010 depends on what your client sends, so a browser extension that rewrites headers can matter there; disable extensions and try again.

## Sources

1. [Cloudflare docs: Error 1006, 1007, 1008 or 1106](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1006/)
2. [Cloudflare docs: Error 1010](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1010/)
3. [Cloudflare docs: 1xxx errors and the HTTP status each returns](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/)
4. [Cloudflare docs: Error 1005 (ASN banned)](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1005/)
5. [Cloudflare docs: Error 1009 (country or region banned)](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1009/)
6. [Cloudflare docs: Error 1020](https://developers.cloudflare.com/support/troubleshooting/http-status-codes/cloudflare-1xxx-errors/error-1020/)
7. [Cloudflare docs: Browser Integrity Check](https://developers.cloudflare.com/waf/tools/browser-integrity-check/)
8. [Cloudflare docs: IP Access rules](https://developers.cloudflare.com/waf/tools/ip-access-rules/)
9. [Cloudflare docs: IP Access rules parameters](https://developers.cloudflare.com/waf/tools/ip-access-rules/parameters/)
10. [Cloudflare docs: WAF custom rule block response versus 1020](https://developers.cloudflare.com/waf/reference/legacy/firewall-rules-upgrade/)
11. [Cloudflare docs: Cloudflare Ray ID](https://developers.cloudflare.com/fundamentals/reference/cloudflare-ray-id/)
12. [Cloudflare docs: Security Events (sampled logs, 31-day retention)](https://developers.cloudflare.com/waf/analytics/security-events/)
13. [Cloudflare docs: the /cdn-cgi/ endpoint and /cdn-cgi/trace](https://developers.cloudflare.com/fundamentals/reference/cdn-cgi-endpoint/)
14. [Cloudflare docs: Custom Errors](https://developers.cloudflare.com/rules/custom-errors/)
15. [Cloudflare docs: WebSockets (idle timeout, restarts)](https://developers.cloudflare.com/network/websockets/)
16. [RFC 6455: The WebSocket Protocol, sections 7.1.5 and 7.4.1 (close code 1006)](https://www.rfc-editor.org/rfc/rfc6455)
17. [WHATWG WebSockets Standard: failures reported to scripts as 1006](https://websockets.spec.whatwg.org/)
18. [undici v7.10.0 source: failed handshakes closed with 1002](https://github.com/nodejs/undici/blob/v7.10.0/lib/web/websocket/connection.js)
19. [Chrome for Developers: Local Network Access](https://developer.chrome.com/blog/local-network-access)
20. [Squid configuration reference: read_timeout (default 15 minutes)](https://www.squid-cache.org/Doc/config/read_timeout/)
21. [Garmin developer forum: user report quoting a Cloudflare 1006 page](https://forums.garmin.com/developer/connect-iq/f/discussion/208786/access-denied-error-1006)
