Domain Redirection Failed - Connection timed out Error code 522

I want to add following redirect according to this tutorial

Domain Redirection ==>

Then, I added following A Records

Finally I added Page rule
Screenshot :

Here is the result
Screenshot :

It’s working:

% curl -svo /dev/null 2>&1 | egrep "< HTTP|location"
< HTTP/2 301 
< location:

You can also check with this tool:


Thanks ! it works ! but - NOT OK

It gives “Connection timed out Error code 522” Error - OK

That’s weird. I thought I tried that one, as well. If you have some other Page Rule above that, and matches, that would prevent the redirect.

Redirect Rules will do the same thing. Use contains to redirect all .com hostnames to .fr, or use is in to make a list of specific hostnames:

1 Like - NOT WORK
Connection timed out Error code 522 - WORKS

Can you share a screenshot of your redirect rule?

1 Like

@DarkDeviL Here it is.


Both do not work. You may be probably seeing the cached page. As of now, your site is experiencing connection timeout error. Make sure to check this #CommunityTip for the resolution:

That redirect rule will redirect from http(s):// to, and that one is actually working as it should, according to the current set up:

$ curl -s -D - -o /dev/null
HTTP/1.1 301 Moved Permanently

$ curl -s -D - -o /dev/null
HTTP/2 301

Your current redirect rule will however only cover redirects FROM http(s)://, as you include the “www.” part in the URL (required) field.

If you also want http(s):// (without www) to be redirecting, one option would be to change that URL (required) field to become something like:


Changing that URL (required) field MAY however interfere with some of the records you have for Office 365, as it would be redirecting all Proxied (:orange:) records, where the actual URL contains “”.

Alternative would be using Redirect Rules (rather than Page Rules), which would offer much more granularity:

No matter which way you go, I would say that the five CNAME records you have, that are actually pointing to an external provider, should have their Proxy status changed, to become Unproxied (:grey:) / DNS-only instead.