How to redirect non www to www in aws s3 bucket and cloudfront
问题 I know how to redirect/rewrite non-www to www using .htaccess in apache server. But I have no clue, about s3 bucket, and CloudFront. I have hosted the website on an s3 bucket using CloudFront. How do I redirect all http://example.com/ requests to http://www.example.com 回答1: There is a feature in S3 where you can to this. Select a bucket, in Properties under Static Web Hosting select Redirect all requests to another host name . Read more here: https://aws.amazon.com/blogs/aws/root-domain