How to allow public access to private AWS S3 bucket objects
AWS S3 buckets are by default private. You can enable public access to the whole S3 bucket by applying public access policy to the bucket.
Related: How to create public AWS S3 bucket
You can allow public access to objects or files in your private S3 buckets by applying the Make public option onto the files.
Steps to allow public access to private AWS S3 bucket files:
-
Go to S3 section in your AWS console.
Related: AWS S3 Management Console
-
Click on the bucket of the object that you want to make public.
-
Click on the Permissions tab.
-
Click the Edit link on the Public access settings card.
-
Uncheck both Block new public ACLs and uploading public objects and Remove public access granted through public ACLs options and click on the Save button.
This will allow public access settings for the bucket but not immediately make your bucket's contents publicly accessible
-
Type confirm and click on the Confirm button.
-
Go back to the main section of your bucket by clicking on the Overview tab.
-
Click on the object that you want to make public.
-
Click on the link for your object at the bottom of the page to test.
You should get a permission error.
-
Go back to the file page and click on the Make public button.
A Success flash message should appear
-
Click on the link for your object at the bottom of the page again to test.
You should now be able to access your object via the public URL.