Download File in AWS S3 Bucket in Browser

Download File in AWS S3 Bucket in Browser

The file path in S3 will always has the following format:

http://{bucket-name}.s3.amazonaws.com/<path_to_file>

Now, ff you are given a link to a file inside of s3 in the following format:

s3://my-bucket/test-folder/dir1/test-file.txt

You should be able to convert it to the following url:

http://my-bucket.s3.amazonaws.com/test-folder/dir1/test-file.txt

So, you can now easily convert s3 protocol to http protocol, which allows you to download using your favourite browser, or simply use wget command to download file from S3 bucket.

 

Leave a Reply

Your email address will not be published.

My new Snowflake Blog is now live. I will not be updating this blog anymore but will continue with new contents in the Snowflake world!