Secure Connection Failed when redirecting from www to naked domain

I followed this tutorial Redirect www.example.com to example.com about redirecting “www” to naked domain.
Currently I’m trying to do this for a subdomain: “sub.mydomain.com

So as shown in the steps I first created an “A” record for “www.sub” pointing to a dummy ip “192.0.2.1”. After that I went into page rules and applied the same rule shown in the tutorial.

When going to “https://sub.mydomain.com” it works perfectly.
When going to “http://sub.mydomain.com” it gets forwarded to https, and works perfectly.
When going both to “http://www.sub.mydomain.com” or “https://www.sub.mydomain.com” I get a “Secure Connection Failed”.

I went over this error in some of already posted questions, but mainly it seems from errors with the certificate. I know my certificate is working since I get to see my website under https when using the naked domain. And the redirect is working since whatever I’m doing, I always get redirected to “https://sub.mydomain.com”.

Any suggestion is appreciated :slight_smile: Thanks!

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.