DNS-level redirect and SSL certificate for www

I’ve added a DNS-level redirect from www.andrecasal.com to andrecasal.com (with a CNAME record).

Accessing www.andrecasal.com was failing because the SSL certificate did not include the www subdomain. I’ve added a second certificate for www and, even thought I have not pointed www.andrecasal.com to Fly’s (v4 or v6) IP address, the website loads without redirecting to andrecasal.com first.

Why is that and how can I fix this?

A DNS CNAME record is not a redirect - it’s pointing a second domain name to the same webserver. If you want to redirect the www subdomain, you’ll need to add code in your app to do that.

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