Lab Overview
Create an Amazon S3 bucket, enable static website hosting, upload your HTML files, and configure a public read bucket policy. At the end of this lab your website will be live on the internet — no servers, no monthly fees, and no web hosting account required.
This is the foundation for all other labs. Every subsequent lab builds on the S3 website you create here.
| Service | Purpose | Free Tier |
|---|---|---|
| Amazon S3 | Stores your website files and serves them as a static website | 5 GB storage + 20K GET requests/mo free |
| AWS IAM | Bucket policy granting public read access to your files | Always free |
Step-by-Step Instructions
1
Amazon S3
Create Your S3 Bucket
An S3 bucket is a container that holds your website files. The bucket name must be globally unique.
- In the AWS Console search bar type
S3and click it - Click Create bucket
- Bucket name: enter a unique name e.g.
my-cloudpracticelabs-site - AWS Region: select US East (N. Virginia) us-east-1
- Uncheck Block all public access
- Check the acknowledgement box that appears
- Leave all other settings at defaults
- Click Create bucket
2
Amazon S3
Enable Static Website Hosting
- Click on your new bucket name
- Click the Properties tab
- Scroll to the bottom and find Static website hosting
- Click Edit
- Select Enable
- Index document:
index.html - Error document:
error.html - Click Save changes
- Scroll back down to Static website hosting — copy the Bucket website endpoint URL
3
Amazon S3
Add a Bucket Policy for Public Access
By default S3 buckets are private. You need a bucket policy to allow anyone to read your files.
- Click the Permissions tab
- Scroll to Bucket policy and click Edit
- Paste the policy below — replace
YOUR-BUCKET-NAMEwith your actual bucket name - Click Save changes
{
"Version": "2012-10-17",
"Statement": [
{
"Sid": "PublicReadGetObject",
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::YOUR-BUCKET-NAME/*"
}
]
}4
Amazon S3
Upload Your Website Files
- Click the Objects tab
- Click Upload
- Click Add files and select your
index.htmlanderror.html - Click Upload
- Wait for the green success banner
5
Web Browser
Test Your Live Website
- Paste the Bucket website endpoint URL into your browser
- You should see your website live on the internet
- Try a URL that doesn't exist — you should see your error.html page
TIP: Bookmark this URL. All future labs will add features to this same website.
Verification Checklist
- S3 bucket created with a unique name in us-east-1
- Block all public access unchecked
- Static website hosting enabled with index.html and error.html
- Bucket policy added — shows Access: Public in the console
- index.html and error.html uploaded
- Website loads correctly in the browser at the S3 endpoint URL
What You Learned
- Amazon S3 — object storage, buckets, and objects
- Static website hosting — serving HTML directly from S3 without a web server
- Bucket policies — JSON-based IAM policies controlling access to S3 objects
- Public access settings — how S3 blocks public access by default and how to override it
Lab Cleanup
IMPORTANT: Delete these resources when finished to avoid charges.
| # | Resource | How to Delete |
|---|---|---|
| 1 | S3 Objects | S3 → your bucket → select all objects → Delete |
| 2 | S3 Bucket | S3 → select your bucket → Delete bucket → confirm |