🔷

AWS Networking Cost Summary

Networking Costs in AWS per GB – Simplified

Intra-VPC and Intra-Region Traffic

  • Within the same Availability Zone (private IPs)Free
  • Between Availability Zones (same Region)
    • Private IPs → $0.01 per GB
    • Public / Elastic IPs → $0.02 per GB
  • Between Regions$0.02 per GB

Best Practices

  • Always use private IPs where possible (lower cost, lower latency).
  • Place workloads in the same AZ when HA is not required to avoid cross-AZ charges.
Scenario
Cost per GB
Same AZ, private IP
Free
Cross-AZ, private IP
$0.01
Cross-AZ, public / Elastic IP
$0.02
Inter-region
$0.02

Minimizing Egress Traffic Network Cost

  • Ingress (into AWS) → typically free
  • Egress (out of AWS)charged

Cost Optimization Tips

  • Keep traffic inside AWS (avoid Internet egress).
  • Co-locate compute + storage in the same Region.
  • Use Direct Connect for consistent large-scale outbound traffic.

Example

  • Efficient: App + DB in AWS, only small query results leave AWS.
  • Inefficient: App on-prem, DB in AWS → every large query causes costly egress.

S3 Data Transfer Pricing (USA)

  • Uploads to S3 → Free
  • S3 → Internet$0.09 per GB
  • S3 → CloudFront → Free
  • CloudFront → Internet$0.085 per GB (cheaper + cached)
  • Cross-Region Replication$0.02 per GB
  • Transfer Acceleration → +$0.04–$0.08 per GB
Transfer Type
Cost per GB
Ingress (S3 Uploads)
Free
S3 → Internet
$0.09
S3 → CloudFront
Free
CloudFront → Internet
$0.085
Transfer Acceleration
+$0.04–0.08
Cross-Region Replication
$0.02
Optimization: Use CloudFront for lower cost & performance, use Transfer Acceleration only for global clients.

NAT Gateway vs Gateway VPC Endpoint

Costs

  • NAT Gateway:
    • $0.045/hour + $0.045 per GB processed
    • S3 same-region traffic → Free
    • S3 cross-region traffic → $0.09 per GB
  • Gateway VPC Endpoint (S3):
    • No hourly cost
    • $0.01 per GB (same-region)

Takeaway

For S3 access, VPC Endpoints are far cheaper than NAT Gateway.
Avoid NAT for S3 traffic → save cost & improve performance.