## AWS Static Website

Deploy a static website on AWS with Pulumi, Amazon S3, and Amazon CloudFront.

## Azure Static Website

Deploy a static website on Azure with Pulumi, Azure Blob Storage, and Azure CDN.

## Google Cloud Static Website

Deploy a static website on Google Cloud with Pulumi, Cloud Storage, and Cloud CDN.

## About these templates

### What is a static website?

A static website is a site whose pages are pre-built HTML, CSS, and JavaScript files served directly from object storage and a CDN, without a server-side runtime. Static sites are typically generated by a framework such as [Next.js](https://nextjs.org/), [Hugo](https://gohugo.io/), [Gatsby](https://www.gatsbyjs.com/), or [Jekyll](https://jekyllrb.com/) and deployed as a folder of files.

### Where should I host a static website on each cloud?

Each major cloud provides an object-storage + CDN combination well suited for static-site hosting:

- **AWS**: an [Amazon S3](/content/registry/packages/aws/api-docs/s3/bucket/index.html) bucket for the files and an [Amazon CloudFront](/content/registry/packages/aws/api-docs/cloudfront/distribution/index.html) distribution for HTTPS, caching, and global delivery.
- **Azure**: an [Azure Blob Storage account](/content/registry/packages/azure-native/api-docs/storage/storageaccount/index.html) configured for static-website hosting and an [Azure CDN](/content/registry/packages/azure-native/api-docs/cdn/endpoint/index.html) endpoint.
- **Google Cloud**: a [Cloud Storage](/content/registry/packages/gcp/api-docs/storage/bucket/index.html) bucket fronted by Cloud CDN.

### How do I deploy a static website with Pulumi?

Use one of the Static Website templates above to scaffold a Pulumi project that provisions storage, a CDN, and any supporting access controls (such as Origin Access Control on AWS). Each template ships with placeholder HTML so the project deploys end to end with `pulumi new` followed by `pulumi up`. You can replace the placeholder content with your own build output by setting the `path` configuration value.

### Can I add a custom domain to a static website deployed with Pulumi?

Yes. The [AWS Static Website template](/content/templates/static-website/aws/index.html) walks through provisioning an ACM certificate and a Route 53 alias record for the CloudFront distribution. The same pattern applies to Azure and Google Cloud using the corresponding DNS providers.
