How I Uploaded and Made an Image Publicly Accessible Using AWS S3

For my Cloud Engineering assignment, I used Amazon S3 to upload an image and make it publicly accessible via a browser link.

The goal of this task was to create an S3 bucket, upload an image, configure access permissions, and verify that the image can be accessed using its object URL.

Step 1: Creating the S3 Bucket

I started by logging into the AWS Management Console and opening the Amazon S3 service.

I created a new bucket with a unique name:

samuel-altschool-s3-task-2026

During setup, I disabled Block all public access to allow the bucket to serve public objects when permissions are configured correctly.

Step 2: Uploading the Image

After creating the bucket, I uploaded an image file named:

joyful house thumbnail.png

The upload was successful and the file appeared inside the bucket under the Objects section.

Step 3: Configuring Public Access

Since the bucket uses Object Ownership: Bucket owner enforced, ACLs are disabled. This means access control must be handled using a bucket policy instead of object-level permissions.

To make the image publicly accessible, I added a bucket policy that allows public read access (s3:GetObject) for all objects in the bucket.

This ensures that anyone with the object URL can view the file in a browser.

Step 4: Testing the Image Access

After applying the policy, I copied the object URL generated by S3:

https://samuel-altschool-s3-task-2026.s3.us-east-1.amazonaws.com/joyful+house+thumbnail.png

When I opened the link in a browser, the image loaded successfully, confirming that the configuration was correct.

Challenges and Key Learnings

This task helped me understand how Amazon S3 access control works, especially the difference between ACLs and bucket policies.

I learned that when Bucket Owner Enforced is enabled:

  • ACLs are disabled
  • Access must be managed using bucket policies

I also gained practical experience in:

  • Creating S3 buckets
  • Uploading objects to S3
  • Configuring public access permissions
  • Testing object URLs in a browser

Conclusion

This task demonstrated how Amazon S3 can be used to store and publicly serve static files such as images.

It also reinforced the importance of understanding AWS access control mechanisms when working with cloud storage services.

Write a Comment

Leave a Comment

Your email address will not be published. Required fields are marked *