Sorry, you have been blocked: Cloudflare's block page
"Sorry, you have been blocked" is the page Cloudflare serves when a firewall rule the site owner runs matched your request and its action was to block. Error 1020, Access denied, is the same decision from a different security feature. Both come with HTTP 403. The rule can match the address, but it can equally match the content of the request, so a proxy changes one thing the rule may look at and nothing else.
Reviewed by John Hale. Last updated .
What it looks like
Sorry, you have been blocked
You are unable to access example.com
Cloudflare Ray ID: ...Error 1020
Access deniedWhat does Sorry, you have been blocked mean?
The site uses Cloudflare's web application firewall (WAF). A rule in it matched the request and blocked it. The page asks you to tell the site owner what you were doing and to include the Ray ID printed at the bottom, because that ID lets the owner find the exact rule.
Cloudflare's documentation draws the line between the two forms. A request blocked by a WAF custom rule or a WAF managed rule gets the WAF block response, which is this page. Error 1020 is returned when another security feature with a block action matched and has no custom response, and the documentation names API Shield schema validation and JWT validation as examples.
Custom rules are written by the owner and can test almost any part of a request: the address, its country or ASN, the user agent, the path, headers. Managed rules are Cloudflare's own signatures for attack patterns, such as SQL injection or script injection in a URL or a form field.
What causes the block through a proxy?
Most likely first.
- Something in the request looks like an attack. A managed rule matched text in the URL, a form field or a header. Pasting code, SQL or HTML into a comment box or a search field is the everyday way real people trigger it.
- The client does not look like a browser to the owner's rule. Custom rules often block a library's default
User-Agent, an empty one, or requests without the headers a browser sends. - The exit's address, network or country. An owner who blocks by country or ASN with a custom rule produces this page instead of error 1009 or 1005, so the same block wears a different face.
- A path that is closed to the public. Admin, login and API paths are commonly restricted to the owner's own addresses.
- A rule that is wrong. Rules have false positives. If a normal action on a site you are a customer of is blocked, the owner needs to know.
How do you find what matched?
Keep the Ray ID and the status
The Ray ID is also the
cf-rayresponse header. It identifies this one request in the owner's Security Events log.Status, sender and Ray IDcurl -s -o body.html -D - -x http://HOST:PORT -U "USER:PASS" "https://TARGET/PATH" | grep -iE "^HTTP/|^server:|^cf-ray:" grep -oiE "sorry, you have been blocked|error code: [0-9]{4}|error [0-9]{4}" body.html | head -1Change one thing at a time
Request the home page instead of the blocked URL, then the blocked URL without its query string or form data. If the plain page loads, the rule matched the content you sent, not who you are.
Compare with and without the proxy
Blocked both ways with the same request: the rule is about the request. Blocked only through the proxy: the rule is about the exit's address, network or country.
What can you do about it?
Tell the site owner, with the Ray ID
This is what the page itself asks for and what Cloudflare's documentation tells visitors to do. Say what you were doing and when. Only the owner can change or relax the rule.
Send an honest, well-formed request
For a script you are allowed to run, set a
User-Agentthat names your application instead of the library default, which is Cloudflare's own advice for clients refused by its browser check. Encode query strings and form data properly, and send only the fields the endpoint expects.Do not disguise input to get past a signature
If legitimate text you need to submit trips a managed rule, the fix is on the owner's side: an exception for that field. Rewriting the payload until the firewall misses it is what the rule exists to stop.
If the site is yours
Search the Security Events log for the Ray ID. The event names the feature and the rule. Then narrow the rule, add an exception, or switch its action to a challenge while you tune it.
If you use TrueProxies
The block page arrives inside the tunnel, so it is the website's answer. The gateway does not read or change what you send through a tunnel, and its own refusals are 407 with a reason in X-Proxy-Reason.
A different exit, country or network changes only the rules that test those things. A rule that matched your user agent, your path or your payload will match again from any address.
Under the acceptable use policy you are responsible for following the terms of every site you reach through the service, and that includes its security rules.
Test the proxy from outside your network
The free proxy checker connects from our servers and reports the failed stage as a code, so you can tell a proxy problem from one on your computer or network.
Questions about Sorry, you have been blocked
Why does it say Sorry, you have been blocked?
A firewall rule on the website, run through Cloudflare, matched your request and blocked it. The rule may be about your address, your browser or script, the page you asked for, or the data you submitted.
What is the Cloudflare Ray ID?
An identifier Cloudflare gives every request that passes through it. The site owner can search for it in their Security Events log to see which rule blocked you.
Is Sorry, you have been blocked the same as error 1020?
They are the same kind of decision from different features. WAF custom and managed rules show the block page. Error 1020 comes from other security features with a block action. Both use HTTP 403.
Will a VPN or proxy remove the block?
Only if the rule was about your address, network or country, and then the site's terms still apply. If the rule matched your request's content or your client, it matches again from any address.
Related errors
403 Forbidden through a proxy
Usually the website's refusal after the tunnel opened; sometimes the proxy refusing the destination.
Error 1006: Access denied (IP banned)
The site owner banned this IP address. Also covers 1007, 1008 and 1106, which mean the same.
challenges.cloudflare.com
Stuck on a Cloudflare check that never finishes: what the challenge needs from your browser and your proxy.
The proxy checker error codes page maps each checker code to the stage that failed, and proxy errors explained covers timeouts and slow connections.