Answer to Why We need to use Cloudfront is :
Note: We need to do this because SSL certificates can only be assigned to cloudfront distributions or AWS ELB, so you need to create
one to enable SSL for your static website.
There are few steps involved in this , assuming you have site properly set up with HTTP end working here are some steps :
1) You need to Request SSL Certifcate from AWS (ACM) it is free and you would not be chraged for this you follow this AWS Documentation
- Enter one or more domain names, you want to create a SSL certificate
for. You can even use a wildcard.
- Verify the email you will get to email address associated witht the
domain.
Note: Choose Region as per your s3 bucket as Cloudfront only accepts certificates hosted in region us-east-1
2) Now you need to create Cloudfront Distribution :
- Create a new Web distribution and select your S3 bucket as Origin
Domain Name. Select HTTPS Only for
Viewer Protocol Policy
.
- In the Distribution Settings section enter your domain name you want
to host your static files on.
- Beside that keep all the default settings and click
“Create
distribution”
.
3) Now Assign the SSL certificate to your Cloudfront distribution
- Go back to Cloudfront and edit your distribution. Now you should be
able to select your brand new SSL certificate.

Hope This Helps..