Amazon S3 Object Storage
Buckets, storage classes, lifecycle policies, and pricing
1. What Is Amazon S3?
Amazon Simple Storage Service (Amazon S3) is managed object storage built to store and retrieve any amount of data from anywhere. It is one of the most heavily tested services on the CLF-C02 exam.
S3 is designed for 11 9s of durability (99.999999999%). By default, data is redundantly stored across multiple facilities and multiple devices within the selected Region. You do not provision capacity; storage scales automatically and you pay only for what you use.
2. Buckets, Objects, and URLs
| Concept | Description |
|---|---|
| Bucket | A logical container for objects. Bucket names must be globally unique across all of AWS and DNS-compliant. |
| Object | Composed of data and metadata. Almost any file type can be stored: images, videos, logs, backups. |
| Region | When you create a bucket, you choose a Region. Data is redundantly stored across multiple facilities in that Region. |
| Access | Objects are accessible over HTTP/HTTPS via a URL. You can also access S3 privately through a VPC endpoint. |
3. S3 Storage Classes
S3 offers multiple storage classes optimized for different access patterns. The exam frequently presents a scenario and asks which class is most cost-effective.
| Storage Class | Best For | Key Characteristics |
|---|---|---|
| S3 Standard | Frequently accessed data: cloud applications, dynamic websites, content distribution, big data analytics. | 11 9s durability, four 9s availability, low latency, high throughput. No retrieval fees. |
| S3 Intelligent-Tiering | Long-lived data with unknown or unpredictable access patterns. | Automatically moves objects between frequent and infrequent access tiers. Small monthly monitoring fee per object. No retrieval fees or tier-movement fees. |
| S3 Standard-IA | Data accessed less frequently but requiring rapid access when needed: long-term backups, DR files. | Same durability as Standard, three 9s availability. Lower storage cost but per-GB retrieval fee. |
| S3 One Zone-IA | Infrequently accessed data that is easily re-creatable or already replicated elsewhere: secondary backup copies. | Stores data in a single AZ (not three). Lower cost than Standard-IA. Good for re-creatable data. |
| S3 Glacier | Data archiving with retrieval times from minutes to hours. | Very low cost. Three retrieval options: Expedited (1-5 min), Standard (3-5 hours), Bulk (5-12 hours). |
| S3 Glacier Deep Archive | Long-term retention and digital preservation for regulatory compliance (7-10+ years). | Lowest-cost S3 storage. Retrieval within 12 hours. Magnetic tape replacement. |
Storage Class Decision Framework
Is the data accessed frequently? Yes → S3 Standard.
Are access patterns unknown or unpredictable? Yes → S3 Intelligent-Tiering.
Is it infrequently accessed but must be available instantly when needed? Yes → S3 Standard-IA.
Is it easily re-creatable or a secondary copy stored in only one AZ? Yes → S3 One Zone-IA.
Is it archival data with defined retrieval time needs? Yes → S3 Glacier (minutes to hours) or Glacier Deep Archive (lowest cost, 12 hours).
4. Lifecycle Policies
S3 lifecycle policies automate the transition of objects between storage classes or their deletion based on age. This reduces cost by moving data to cheaper classes as it becomes less important over time.
Example lifecycle flow:
- Upload a video preview to S3 Standard for immediate access.
- After 30 days, transition to S3 Standard-IA because access drops off.
- After 60 days, move to S3 Glacier for long-term archiving.
- After 1 year, delete the object automatically.
5. Common Use Cases
- Application assets: Shared storage for user-generated media, server logs, or files that any EC2 instance can access.
- Static web hosting: Host HTML, CSS, JavaScript, and image files directly from a bucket.
- Backup and disaster recovery: High durability makes S3 ideal for backups. Cross-Region replication can copy data to another Region automatically.
- Big data staging: Store raw datasets before processing with analytics tools.
- Software delivery: Host application binaries that customers download.
6. Pricing Basics
S3 pricing has four main components. The exam tests whether you know what is free versus what incurs charges.
| Component | Charged? | Notes |
|---|---|---|
| Storage | Yes | Per GB per month. Rate varies by storage class. |
| Requests | Yes | PUT, COPY, POST, LIST, and GET requests have different rates. |
| Data transfer IN | No | Uploading data into S3 is free. |
| Data transfer OUT | Yes | Transferring data out of the S3 Region incurs charges. Transfer to CloudFront or EC2 in the same Region is free. |
7. Quick Quiz
Test Your Understanding
Select one answer per question. You will receive immediate feedback.