SSL Encryption Mode: Error 522 on subdomains or ERR_TOO_MANY_REDIRECTS on main domain

I am having a weird problem:

If I set the SSL encryption mode to ‘Flexible’, I get ‘ERR_TOO_MANY_REDIRECTS’ error on the main domain ‘’ but the subdomains are accessible ‘

If I set the SSL encryption mode to ‘Full’ or ‘Full-Strict’, the main domain works well but I get ‘Error 522’ on subdomains.

Can someone help?

Is this Wordpress? You need to enable proxy_ssl mode in the config.

There’s also a plugin called Wordpress Cloudflare Redirect Fix.

If you don’t have WP, you can enable this proxy ssl thing in Apache.

Hi @ashok,

Full (strict) is the best choice, flexible is not secure and can cause issues such as the redirect error you experienced.

This gets the main domain working, you can then look into the 522 on the subdomains:

A 522 error typically happens when Cloudflare requests to the origin (your webserver) get blocked. Review the suggestions in this Community Tip for troubleshooting ideas.

1 Like

Not Wordpress

Thanks … I will look that up

1 Like