How to Host a Static Website on AWS s3 Bucket

Muhammad Ahsan
2 min readAug 18, 2024

--

aws s3 bucket service — static web hosting

The best approach to get started is to first have an IAM user account with AWS S3 bucket permissions. Working directly on the root user account is not recommended.

Search s3 bucket in search bar. Click on create bucket. Name your s3 bucket, and that should be unique. Uncheck “Block all public access”, and keep other configurations as default settings.

current s3 buckets list
Un-check block all public access

Now you can see your s3 bucket on the dashboard. Go to your bucket. Go to “Properties”, and scroll all the way to down. You will find “Static website hosting”, click on edit. Check Enable, name your static website root file like index.html. Go back to your bucket. Upload the website files. In properties, static web hosting, you will find a URL. Copy and paste that in your browser search. Now, you can access your static web page.

static web hosting configuration
upload files

Now, your website is up and running on aws s3 bucket static website hosting.

index.html

Follow for more AWS SAA tutorials. Thank you!

https://github.com/001-mak

https://www.linkedin.com/in/ahsan-khaleeq/

--

--

Muhammad Ahsan

I am software engineering student. Always looking for open source contribution opportunities. Write about technologies I learn.