Skip to content

Instantly share code, notes, and snippets.

@PeterGrecian
Last active June 15, 2025 08:35
Show Gist options
  • Select an option

  • Save PeterGrecian/8c5324cab335e69e7be32c9906b02e64 to your computer and use it in GitHub Desktop.

Select an option

Save PeterGrecian/8c5324cab335e69e7be32c9906b02e64 to your computer and use it in GitHub Desktop.
AWS Costs Cheatsheet

AWS Costs Cheatsheet

  • USD per year.
  • Yearly cost is so much easier to understand than hourly.
  • Costs which are charged by the event (usually per million) are more easily understood as the cost of one event per second sustained for a year.
  • The always free allowances are significant: Lambda is 24 requests per minute or 9, 1GB processes per minute whichever is reached first.

Compute and DB per year

On demand prices for typical region (eg. us-west-2), discounts of about 50% are obtainable with Reserved Instances, (Compute) Savings Plans and Spot Instances.

EC2 m7g.medium (2 CPU, 4GB) $360
Lambda per CPU GB year. ARM $420 + $6 per request per second
Fargate ARM 2 CPUs 4GB $690
ECS as EC2 or Fargate
EKS cluster $900 first 14 months after version release
cluster $5300 after 14 months after version release
auto mode + 20% EC2 surcharge
ELB ALB, NLB, Classic $200 + $70 x load units eg. data transfer 1 GB per hour.
RDS db.t4g.medium (1 CPU 4GB) $570 Single AZ. MySQL, PostgreSQL, MariaDB
OpenSearch m7g.medium.search (1 CPU 4GB) $600

relative sizes:

nanomicrosmallmediumlargexlarge2xlarge
1/81/41/21248

Storage per TB year

EBS gp3 $1000 HDD 1/2 price
snapshot standard $600retrieval free
archive $150 retrieval $370
S3 standard $280 infrequent 1/2 price. Std Glacier 1/6th price
glacier deep archive $12 12 hour retrieval
EFS standard $3700 $370 per TB read, $740 write. $70 transfer read or write
infrequent $200 $70 read or write

Network per TB or year

EC2 to internet $90 first 100GB/month = 40kB/s free
to another AWS region $20 first 100GB/month = 40kB/s free
CloudFront US/Europe $90 first 1TB/month = 400kB/s free
NAT gatewayper year $40
per TB $45
public IP $45 idle or in use
elastic IP $45 idle or additional
WAF Web ACL per rule per year $72 + $18 per request per second
API gatewayHTTP, WebSocket $30 per request per second
REST $105

Free networking:

  • Within the same AZ.
  • to EC2 from internet.
  • EC2 to CloudFront, S3.
  • Public IPv4 addresses that are not dedicated to your resource for example, public IPv4 addresses associated with Amazon S3 that are not dedicated per S3 bucket.
  • AWS Elastic IP addresses associated with a running instance
  • to CloudWatch.
  • Internet Gateway to public endpoint in the same Region. (not NAT).
  • between DynamoDB and other AWS services within the same AWS Region
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment