Pricing, Billing & Cost Management
AWS bills you for what you use, which can be wonderfully cheap or painfully expensive. Understanding how AWS charges, and using its cost tools before you build, is what separates confident cloud users from people who wake up to a surprise bill. AWS prices change, so this page explains the principles and tells you where to check current numbers.
How AWS charges
Almost every AWS charge comes down to one of these drivers:
| Driver | Measured as | Examples |
|---|---|---|
| Compute time | Per second or hour that something runs | EC2 instances, RDS databases, Fargate tasks, NAT gateways, load balancers |
| Duration x memory | GB-seconds | Lambda functions |
| Storage | Per GB-month | S3 objects, EBS volumes (provisioned size), snapshots, logs |
| Requests | Per thousand or million calls | S3 GET/PUT, API Gateway, DynamoDB on-demand reads and writes |
| Data transfer | Per GB | Data out to the internet, between AZs, between Regions |
| Units of work | Per item processed | Images analysed, characters translated, model tokens |
A few rules of thumb about data transfer: data coming into AWS from the internet is generally free; data going out to the internet is charged; traffic between Availability Zones and between Regions is usually charged; traffic within one AZ using private IPs is often free. Delivery through CloudFront can reduce data-out costs.
Prices also vary by Region. Always look up the service's official pricing page for the Region you use, and use the AWS Pricing Calculator to estimate a design before building it.
Ways to pay less
- On-Demand: no commitment; the flexible default.
- Savings Plans and Reserved Instances: commit to steady usage for one or three years for a significant discount.
- Spot Instances: spare EC2 capacity at a large discount, interruptible at short notice.
- Right-sizing: pick the smallest instance that does the job; AWS Compute Optimizer recommends sizes from real usage.
- Turn things off: stop dev servers at night, use serverless services that cost nothing when idle, and use lifecycle rules to move old data to cheaper storage classes.
The Free Tier
AWS's Free Tier lets new customers try services at no cost within limits. It changed significantly in 2025: new accounts receive promotional credits and choose a free or paid account plan, and the details differ from what older tutorials describe. Limits, durations and eligible services are listed on the official AWS Free Tier page, and your remaining credits and usage appear in the Billing and Cost Management console. Never assume a service is free; check first.
Your cost toolkit
| Tool | What it does |
|---|---|
| AWS Budgets | Alerts by email (or SNS) when actual or forecast spend crosses your thresholds; budget actions can apply restrictive policies automatically |
| Billing and Cost Management home and Bills | Month-to-date charges, broken down by service and Region |
| Cost Explorer | Graphs of spending over time, filtered by service, Region, account or tag |
| Cost Anomaly Detection | Uses machine learning to flag unusual spending patterns |
| Cost allocation tags | Tags such as project=results-portal let you see costs per project |
| AWS Pricing Calculator | Estimates monthly cost of a planned architecture |
| Trusted Advisor, Compute Optimizer | Recommend savings such as idle resources and oversized instances |
Create a budget from the CLI
You can create budgets in the console (the Zero spend and Monthly cost templates are quickest) or with the CLI. budget.json sets a monthly cost budget; the amount is whatever you choose to allow yourself:
{
"BudgetName": "monthly-learning",
"BudgetLimit": { "Amount": "10", "Unit": "USD" },
"BudgetType": "COST",
"TimeUnit": "MONTHLY"
}
notifications.json emails you at 80% of actual spend and when forecast spend will exceed 100%:
[
{
"Notification": {
"NotificationType": "ACTUAL",
"ComparisonOperator": "GREATER_THAN",
"Threshold": 80,
"ThresholdType": "PERCENTAGE"
},
"Subscribers": [{ "SubscriptionType": "EMAIL", "Address": "you@example.com" }]
},
{
"Notification": {
"NotificationType": "FORECASTED",
"ComparisonOperator": "GREATER_THAN",
"Threshold": 100,
"ThresholdType": "PERCENTAGE"
},
"Subscribers": [{ "SubscriptionType": "EMAIL", "Address": "you@example.com" }]
}
]
aws budgets create-budget --account-id 123456789012 \
--budget file://budget.json \
--notifications-with-subscribers file://notifications.json
To see where money went this month by service, use Cost Explorer in the console, or aws ce get-cost-and-usage grouped by the SERVICE dimension. (Each Cost Explorer API request carries a small charge; the console view does not.)
Where surprise bills come from
The usual culprits: EC2 instances left running (often in another Region); NAT gateways and load balancers that bill every hour; RDS databases (and stopped ones restarting after seven days); unattached EBS volumes and old snapshots; idle SageMaker endpoints and Studio apps; log groups with no retention; Elastic IPs and public IPv4 addresses; and leaked access keys used by attackers to launch expensive instances. Budgets warn you, but only you can delete the resource.
End-of-session clean-up checklist
- EC2: terminate instances; delete unattached volumes, unneeded snapshots and AMIs; release Elastic IPs.
- Networking: delete NAT gateways, load balancers and unused VPC endpoints.
- Databases: delete practice RDS instances and their snapshots.
- Containers and ML: delete ECS services, EKS clusters, SageMaker endpoints; stop Studio apps.
- IaC: run
cdk destroy,sam deleteordelete-stackfor practice stacks. - Check every Region you used. The Tag Editor in Resource Groups can search for resources across Regions.
Tag everything you create with project and owner, and activate those tags as cost allocation tags in Billing. Months later you will know exactly what each resource was for and whether it can be deleted.
Key points
- AWS charges for compute time, storage per GB-month, requests, data transfer out and units of work.
- Commitments (Savings Plans, Reserved Instances) and Spot cut compute costs; right-sizing and turning things off cut them further.
- Free Tier rules changed in 2025; always check the official Free Tier and pricing pages.
- Set up AWS Budgets before building, and use Cost Explorer and tags to see where money goes.
- Clean up after every session, in every Region you used.
Tip: use the ← and → keys to move between pages.
