Amazon CloudFront

Table of Contents



Price Class

Price Classes let you reduce your delivery prices by excluding Amazon CloudFront’s more expensive edge locations from your Amazon CloudFront distribution.

Ensure users S3 content only through Cloudfront

  1. Create originaccessidentity
  2. Allow this identity to access your private S3 bucket by updating bucket policy

  3. Set the identity to the cloudfront distribution.

Zone ID of CloudFront Distributions

It's globally a single one, which is Z2FDTNDATAQYW2


Use custom domain and its ACM (AWS Certificate Manager)

You must list any custom domain names (for example, that you use in addition to the CloudFront domain name (for example, for the URLs for your files. Specify up to 100 CNAMEs separated with commas or put each on a new line. You also must create a CNAME record with your DNS service to route queries for to For more information, see the Help.

If you want to use ACM for both apex domain and subdomains, you should specify apex domain( along with wildcard domain(* when you create ACM

Redirect HTTP to HTTPS

Within Behaviros tab:

Invalidate objects (Web Dist Only)

Or you can use awscli as follows:

aws cloudfront create-invalidation --distribution-id <ID> --paths '/*'