DEV Community

Cover image for WTF is Amazon S3?
Tomasz Łakomy
Tomasz Łakomy

Posted on • Edited on • Originally published at tlakomy.com

WTF is Amazon S3?

Before we start - I'm working on https://cloudash.dev, a brand new way of monitoring serverless apps 🚀. Check it our if you're tired of switching between 50 CloudWatch tabs when debugging a production incident.


Amazon S3 is one of those things you may have heard about in the context of:

So, we keep our static files on Amazon S3

or

Every image uploaded to dev.to is stored on an S3 bucket (which is true, btw)

and if you're not sure what exactly S3 is, this post is for you.

WTF is Amazon S3?

Amazon S3 stands for Amazon Simple Storage Service and it's one of the most popular services provided by AWS (Amazon Web Services).

It's an object storage service which takes care of scalability, data availability, security, and performance. By "object storage service" I mean - "this is a place for you to store your files".

Files in S3 are stored in things called buckets, which sounds weird at the beginning but you quickly get used to it. What's important to remember is that S3 bucket names need to be globally unique.

If I've created a bucket called tlakomyBucket, you are not able to create a bucket with exactly the same name, no matter how hard you try.

Speaking of names, you're not able to change the bucket name after you create it - choose wisely!

S3 offers virtually unlimited storage capacity, if you managed to collect every cat picture on the Internet, you'd be able to put it on S3.

There are two kind of buckets: private or public ones. If, for instance, you allow users to upload their CVs to a website, you'd probably want to use a private bucket. S3 can be used for hosting static websites and in order to do that - you need to convert it to a public one. By default all newly created buckets and their contents are private.

The image with 3 buckets on top of this post is, in fact, hosted on S3, here's the url:

https://thepracticaldev.s3.amazonaws.com/i/sph8x1z6yinrx1l0pq54.jpg

as you can see, name of the bucket is thepracticaldev. AWS does a lot of things to ensure that this file is accessible 99.99999999% of the time (literally).

Top comments (2)

Collapse
 
nomangul profile image
Noman Gul

Thanks for the descriptive intro 👌

Collapse
 
ferricoxide profile image
Thomas H Jones II

Though, setting per-object ACLs, using signed URLs, bucket-policies and IAM roles go a long way towards blurring the line between public and private buckets (especially if you do it wrong!).