AWS Builder Center

How to Use Amazon S3: A Beginner's Guide

Amazon S3 (Simple Storage Service) is an AWS service used to store and retrieve files such as images, videos, documents, backups, and application data.

S3 uses two important concepts:
  • Bucket — a container where your files are stored.
  • Object — the actual file stored inside the bucket.
1
2
3
4
5
6
7
8
S3
└── my-app-bucket
├── images/
│ ├── profile.jpg
│ └── logo.png
├── documents/
│ └── resume.pdf
└── backup.zip
AWS describes a bucket as a container for objects, and each object consists of the file data and associated metadata.

1. Create an S3 Bucket

First, open the Amazon S3 console.
Choose:
S3 → Create bucket
Give your bucket a unique name, for example:
1
my-first-s3-bucket-2026
Choose an AWS Region that is appropriate for your application.
Keep the default security settings for a beginner. In particular, don't make the bucket public unless you specifically need public access.
AWS recommends keeping public access blocked for most use cases.

2. Upload a File

After creating the bucket:
  1. Open your bucket.
  2. Click Upload.
  3. Click Add files.
  4. Select a file from your computer.
  5. Click Upload.
For example, you could upload:
1
hello.txt
Now your S3 bucket contains:
1
2
my-first-s3-bucket-2026
└── hello.txt
An S3 object has a key, which is essentially the name/path used to identify the object inside the bucket.

3. Download the File

To download the file:
  1. Open your bucket.
  2. Select hello.txt.
  3. Choose Download.
S3 will download the object to your computer.
You can also open objects through the AWS console; AWS notes that these operations can use temporary presigned URLs.

4. Using S3 from the AWS CLI

S3 becomes much more useful when you start using the AWS CLI.
For example, you can upload a file using:
1
aws s3 cp hello.txt s3://my-first-s3-bucket-2026/
To see the files in your bucket:
1
aws s3 ls s3://my-first-s3-bucket-2026/
To download the file:
1
aws s3 cp s3://my-first-s3-bucket-2026/hello.txt .
AWS provides the aws s3 cp command for copying files between your local system and S3.

5. Using S3 in an Application

S3 is especially useful when building applications.
For example, imagine you're building a website where users upload profile pictures.
Instead of storing the images directly on your application server:
1
2
3
4
5
6
7
User
↓
Your Application
↓
Amazon S3
↓
profile.jpg
Your application can upload the image to S3 and store the S3 object key in your database:
1
2
User ID: 101
Profile Image: users/101/profile.jpg
The actual image stays in S3 while your database only needs to keep information about the object.

6. Important S3 Features

Once you understand basic upload/download operations, these are some S3 features worth learning:

Versioning

S3 Versioning allows you to keep multiple versions of an object. This can help recover from accidental overwrites or deletions.

Storage Classes

S3 provides different storage classes depending on how frequently you need to access your data.
For example:
1
2
3
4
5
6
7
8
9
10
11
Frequently accessed data
↓
S3 Standard

Infrequently accessed data
↓
S3 Infrequent Access

Long-term archive
↓
S3 Glacier

Permissions

S3 permissions are important when building real applications.
You can control access using mechanisms such as:
  • IAM policies
  • Bucket policies
  • S3 Access Points
  • ACLs where applicable
By default, S3 resources are private unless access is explicitly granted.

7. Simple Real-World Example

Suppose you're developing a Java backend for a hospital application.
A user uploads a medical document:
1
patient-report.pdf
Your application could store it in S3:
1
2
3
4
hospital-files/
└── patients/
└── 12345/
└── patient-report.pdf
Your database could store:
1
2
3
Patient ID: 12345
File name: patient-report.pdf
S3 key: patients/12345/patient-report.pdf
Your Java application can then retrieve the file from S3 when it is needed.

8. Clean Up After Practice

If you're just experimenting with S3, remember to delete the objects and bucket when you're finished.
AWS recommends cleaning up resources from tutorials when you no longer need them so that you don't continue accumulating charges.

Conclusion

Amazon S3 is one of the easiest AWS services to start with.
The basic workflow is:
1
2
3
4
5
6
7
8
9
Create Bucket
↓
Upload Object
↓
Store/Retrieve Object
↓
Manage Permissions
↓
Use S3 from CLI or SDK
Once you understand buckets, objects, keys, permissions, and storage classes, you have a good foundation for using S3 in real-world applications.
Any opinions in this article are those of the individual author and may not reflect the opinions of AWS.
Enjoyed reading this content? Let the author know!

Your likes, comments, shares, and saves help creators reach more builders.

Loading recommendations

Loading article