S3 Static Website Hosting
Create an S3 bucket, upload a static website, configure permissions, and access it via a browser.
1. AWS Console → S3 → Create bucket
2. Bucket name: yourname-awslab-website (must be globally unique)
3. Region: closest to you
4. Block Public Access: Keep ON for now
5. Click Create bucket
Create this file locally as index.html, then upload it to S3:
<!DOCTYPE html>
<html>
<head><title>My AWS Site</title></head>
<body>
<h1>Hello from Amazon S3!</h1>
<p>Static website hosted on AWS.</p>
<p>No servers needed!</p>
</body>
</html>
1. Bucket → Properties tab
2. Scroll to "Static website hosting" → Edit
3. Enable → Index document: index.html
4. Save changes
5. Copy the Endpoint URL shown
1. Permissions tab → "Block public access" → Edit → Uncheck all → Save
2. Confirm
3. Bucket Policy → Edit → paste policy below (replace BUCKET_NAME):
{
"Version": "2012-10-17",
"Statement": [{
"Effect": "Allow",
"Principal": "*",
"Action": "s3:GetObject",
"Resource": "arn:aws:s3:::BUCKET_NAME/*"
}]
}
1. Open the Endpoint URL in your browser
2. You should see your HTML page!
Clean up:
1. Select all objects → Delete
2. Delete the bucket (Bucket → Delete)