Menu

Log in

Sign up

From beginner to master of web design, coding, infrastructure operation, business development and marketing

  • COURSES
  • HTML & CSS Introduction
  • HTML & CSS Coding with AI
  • Linux Introduction
  • Docker Basics
  • Git & GitHub Introduction
  • JavaScript Coding with AI
  • Django Introduction
  • AWS Basics
  • Figma Introduction
  • SEO Tutorial for Beginners
  • SEO with AI
  • OTHERS
  • About
  • Terms of Service
  • Privacy Policy

© 2024 D-Libro. All Rights Reserved

AWS BasicsChapter 2. Setting Up the AWS Environment

Managing AWS Cost from the Beginning

Managing AWS Cost from the Beginning

Managing AWS Cost from the Beginning

Managing your AWS cost from the very start is essential to avoid unpleasant surprises. Like most cloud platforms, AWS follows a pay-per-use pricing model — meaning you’re only charged for the resources you use, and how long you use them. This flexibility is one of the major benefits of cloud computing, but it also means that even small or idle resources can quietly generate costs if you’re not careful.

While AWS offers a Free Tier to help new users explore its platform at no cost, this tier only covers basic usage. Supporting services like snapshots, idle resources, and data transfer may still incur charges — even when you're working on small practice projects.

To stay within the Free Tier or keep your costs as low as possible, you need to understand how AWS bills its services and how to clean up unused resources. This section introduces cost management concepts before we dive into infrastructure practice. You can skim this now, even if some terms feel unfamiliar. It’s a good idea to revisit it after completing the hands-on chapters to reinforce your understanding.

How to check your AWS cost

There are several ways to track your AWS spending in real time. Familiarizing yourself with these tools helps you stay informed and react quickly if something starts to generate cost.

Billing and Cost Management

AWS provides a dedicated Billing Dashboard where you can view your total monthly costs, analyze usage by service, and download detailed reports.

Go to Billing and Cost Management. You can see the cost overview.

Managing AWS Cost from the Beginning Screenshot 1

To see a breakdown of charges, click “Bills”

To visualize cost trends and usage by service, click “Cost Explorer”

This is your primary tool for understanding where your charges come from.

Set up a budget alert

AWS Budgets allow you to set spending limits and receive email alerts when you exceed them.

  • Go to Budgets under Budgets and Planning in the left sidebar.

  • Click “Create a budget” and select Cost budget

  • Set “Zero spend budget” or Define a monthly spending limit (e.g., $1.00)

  • Enable email notifications so you’re alerted if your cost goes over
Managing AWS Cost from the Beginning Screenshot 2

This is one of the most effective ways to stay in control of your spending.

How to manage within free tier limit

In this guide, we’ll practice building infrastructure with EC2, S3, VPC, AMI, RDS, and ELB. While all of these have some Free Tier offerings, not every feature is covered. The key to managing cost is to delete unused resources as soon as your practice is complete.

EC2

Free Tier Structure:

  • 750 hours/month of t2.micro or t3.micro instances (Linux or Windows)

  • 30 GB of EBS (Elastic Block Store) general-purpose storage

Potential Costs:

  • Extra hours beyond 750

  • EBS volume storage exceeding 30 GB

  • Snapshots of volumes

  • Elastic IPs if not attached to a running instance

How to Manage Cost:

  • Use only one instance at a time

  • Terminate instances when not needed

  • Release unused Elastic IPs (if you use static IP for the instance)

  • Manually delete EBS snapshots

What is an EBS snapshot and volume?
An EBS volume is the storage space attached to your EC2 instance — you can think of it like the hard drive on your own computer. It holds everything your virtual server needs, including the operating system, files, and any data your application uses.

An EBS snapshot is a backup of that storage. AWS saves this backup in the background so you can restore it later if something goes wrong, or use it to create a new instance with the same setup.

Snapshots are not created automatically. They’re only made when you:

  • Manually take a snapshot of a volume

  • Create an AMI (Amazon Machine Image) — AWS automatically creates a snapshot during that process

It’s important to know that volumes and snapshots don’t always disappear when you delete your EC2 instance. If they’re not removed, they can keep running in the background and generate charges.

The AWS Free Tier gives you 30 GB of EBS volume storage each month, but snapshots are not included and typically cost about $0.05 per GB each month. To keep your account within the Free Tier, it’s a good idea to delete any snapshots or volumes you no longer need once your practice is complete.

AMI (Amazon Machine Image)

Free Tier Structure:

  • No separate Free Tier for AMIs, but AMIs are based on EBS snapshots

Potential Costs:

  • Snapshots stored in Amazon S3 (~$0.05/GB/month)

How to Manage Cost:

  • Deregister AMIs after use

  • Delete associated snapshots to stop storage billing

Caution: Watch out for snapshot costs when creating AMIs
When you create an AMI from an EC2 instance, AWS automatically creates a snapshot of the instance’s storage in the background. This snapshot is what allows the AMI to recreate the same system later.

While creating an AMI doesn’t cost anything upfront, the snapshot it generates can lead to ongoing storage charges — especially if you create multiple AMIs and forget to delete them. Snapshots are not covered by the Free Tier and typically cost about $0.05 per GB per month.

To avoid unexpected costs, remember to delete unused AMIs and their associated snapshots after you finish practicing.

S3

Free Tier Structure:

  • 5 GB of Standard Storage

  • 20,000 GET and 2,000 PUT requests

  • 15 GB of data transfer out/month

Potential Costs:

  • Storing files beyond 5 GB

  • Request overages

  • Using storage classes like Glacier or Infrequent Access

How to Manage Cost:

  • Store small test files only

  • Delete old files promptly

  • Use lifecycle rules to auto-delete objects

VPC

Free Tier Structure:

  • VPC itself is free

  • First Elastic IP is free only when attached to a running instance

Potential Costs:

  • Idle Elastic IPs

  • VPC flow logs stored in CloudWatch

How to Manage Cost:

  • Release unused Elastic IPs

  • Avoid enabling flow logs unless needed

  • Don’t use premium NAT gateways unless required

RDS

Free Tier Structure:

  • 750 hours/month of db.t2.micro or db.t3.micro instances

  • 20 GB of storage

Potential Costs:

  • Running multiple instances

  • Exceeding 20 GB of storage

  • Backup retention and read replicas

How to Manage Cost:

  • Use only one instance at a time

  • Set backups to minimum duration

  • Delete RDS instances after each practice

ELB (ALB)

Free Tier Structure:

  • No Free Tier for Elastic Load Balancing

Potential Costs:

  • Hourly usage charges

  • Charges for data processed through the load balancer

How to Manage Cost:

  • Use load balancers only during specific practice scenarios

  • Delete them immediately after testing

Common pitfalls that lead to unexpected AWS charges

Understanding the most common mistakes can help you avoid them:

1. Unused EBS volumes: Volumes remain after instance termination unless “Delete on Termination” is enabled.

2. Orphaned snapshots and AMIs: Deregistering an AMI doesn’t remove its snapshot. These accumulate and cost money.

3. Idle Elastic IPs:
Elastic IPs not attached to running instances are charged hourly.

4. Multiple or long-running RDS instances: Running more than one RDS instance or leaving it running continuously exceeds Free Tier limits.

5. ELB usage: Elastic Load Balancers are not part of the Free Tier. Charges begin as soon as they’re active.

6. S3 misconfigurations: Exceeding storage limits, enabling versioning, or using non-standard storage classes leads to unexpected costs.

7. Detailed CloudWatch monitoring: Enabling 1-minute metrics or accumulating logs can result in charges over time.

8. Running multiple instances simultaneously: The Free Tier offers 750 hours total — not per instance. Running two instances halves the free hours.

9. Forgetting to stop or delete resources: Resources left running can silently accumulate charges, even if they aren’t actively used.

10. Overlooking resources in other regions: Resources deployed in multiple regions can be forgotten, leading to additional charges. Free Tier limits are account-wide, not region-specific.

Wrapping up

Managing costs is an essential part of working with AWS. While the Free Tier gives you a solid starting point, it’s easy to go over the limits without realizing it.

You don’t need to know every pricing detail right away. Just stay aware of what you’re using, check your billing dashboard regularly, and clean up resources when you’re done.

As you continue through the hands-on chapters, feel free to revisit this guide. You’ll gain a clearer sense of how your choices affect cost — and how to keep things efficient as you build.

Tags:

Free Tier

AWS Cost Management

Billing Dashboard

Budget Alert

Cost Explorer

AWS Basics
Course Content

Chapter 1. Cloud and AWS Fundamentals

Introduction to Cloud Computing

Discovering Amazon Web Services (AWS)

AWS vs. Azure vs. Google Cloud

Chapter 2. Setting Up the AWS Environment

Creating Your AWS Account

Managing User Access with IAM

Managing AWS Cost from the Beginning

Chapter 3. Deploying a Web App on AWS with a Simple Setup

Preparing a Web App for Deployment

Launching and Configuring EC2 Instances

Implementing Storage with Amazon S3

Chapter 4. Building Scalable Infrastructure with AWS

Defining Target AWS Configurations

Configuring Your Virtual Private Cloud (VPC)

Using AMIs to Recreate EC2 Instances in a Custom VPC

Setting Up a Relational Database with RDS

Distributing Traffic with Elastic Load Balancing (ELB)

Monitoring Performance with CloudWatch

Chapter 5. Next Steps on Your AWS Journey

Exploring AWS Further: Rise of AI Services

Certification and Continuing Your AWS Journey

Chapter 1. Cloud and AWS Fundamentals

Introduction to Cloud Computing

Discovering Amazon Web Services (AWS)

AWS vs. Azure vs. Google Cloud

Chapter 2. Setting Up the AWS Environment

Creating Your AWS Account

Managing User Access with IAM

Managing AWS Cost from the Beginning

Chapter 3. Deploying a Web App on AWS with a Simple Setup

Preparing a Web App for Deployment

Launching and Configuring EC2 Instances

Implementing Storage with Amazon S3

Chapter 4. Building Scalable Infrastructure with AWS

Defining Target AWS Configurations

Configuring Your Virtual Private Cloud (VPC)

Using AMIs to Recreate EC2 Instances in a Custom VPC

Setting Up a Relational Database with RDS

Distributing Traffic with Elastic Load Balancing (ELB)

Monitoring Performance with CloudWatch

Chapter 5. Next Steps on Your AWS Journey

Exploring AWS Further: Rise of AI Services

Certification and Continuing Your AWS Journey

FAQ: Managing AWS Cost from the Beginning

How can I check my AWS cost?

You can track your AWS spending in real time using the Billing Dashboard. It allows you to view total monthly costs, analyze usage by service, and download detailed reports. Use the "Bills" section for a breakdown of charges and "Cost Explorer" to visualize cost trends.

What is the AWS Free Tier and what does it cover?

The AWS Free Tier offers basic usage for new users, including 750 hours/month of t2.micro or t3.micro instances, 30 GB of EBS storage, and 5 GB of S3 storage. However, it doesn't cover all services, and additional charges may apply for snapshots, idle resources, and data transfer.

How can I manage costs within the Free Tier limit?

To manage costs, delete unused resources promptly, use only one instance at a time, release unused Elastic IPs, and manually delete EBS snapshots. Be mindful of the Free Tier limits and avoid exceeding them.

What are common pitfalls that lead to unexpected AWS charges?

Common pitfalls include unused EBS volumes, orphaned snapshots and AMIs, idle Elastic IPs, running multiple or long-running RDS instances, and S3 misconfigurations. Regularly check your resources and clean up to avoid these charges.

How can I set up a budget alert in AWS?

To set up a budget alert, go to Budgets under Budgets and Planning, create a cost budget, set a spending limit, and enable email notifications. This helps you stay informed and control your spending.