HTTPS redirect from a naked domain (example.com) to a full domain ‘www.example.com’ without an error

amazon-route53https

I'm trying to Redirect non-www requests to www on Amazon Route 53.

I made an S3 bucket with the name of the naked domain and configure the bucket properties to redirect from example.com to www.example.com, and then in Route 53 create an alias for the naked domain name that points to that S3 bucket based on the following :

Redirect non-www requests to www on Amazon Route 53

It worked great for me, except for the HTTPS.

Right now I can't access https://example.com for some reason.

Any help would be highly appreciated.

Best Answer

You can put CloudFront in front of your s3 bucket and have CloudFront terminate the SSL connection. HTTPS is free when using SNI.

Steps:

  • create distribution and configure ssl, with the origin being your s3 website redirect bucket.
  • set the cname to be your naked domain
  • update route 53 to point to this distribution
Related Topic