The NAT Gateway line is the second-biggest item on the AWS bill.
IntermediateTroubleshootingCloudFormation, CloudWatch, KMS, Secrets and Cost
Answer
Likely causes → NAT charges per GB processed as well as per hour. Big traffic through NAT, such as pulling container images, S3 or DynamoDB transfers, or backups, adds up quickly. Cross-AZ NAT usage adds data transfer charges on top.
Diagnose →
aws ce get-cost-and-usage --time-period Start=2026-10-01,End=2026-11-01 --granularity MONTHLY --metrics UnblendedCost \
--filter '{"Dimensions":{"Key":"USAGE_TYPE_GROUP","Values":["EC2: NAT Gateway - Data Processed"]}}'
# CloudWatch AWS/NATGateway BytesOutToDestination per NAT
# VPC Flow Logs on the NAT ENI -> top destinations by bytes (Athena)
Fix →
- Add free gateway endpoints for S3 and DynamoDB
- Add interface endpoints for ECR, Logs and STS where the volume justifies their hourly cost
- Use one NAT per AZ with AZ-local routes
- Cache images (ECR pull-through cache)
Prevent → Tag and dashboard NAT bytes, and review the top talkers through flow logs every month.
More on CloudFormation, CloudWatch, KMS, Secrets and Cost
Updating a stack fails: `Stack:arn:aws:cloudformation:...:stack/app/... is in ROLLBACK_COMPLETE state and can not be updated.`BeginnerA stack is stuck in `UPDATE_ROLLBACK_FAILED`.AdvancedA pipeline fails with `An error occurred (ValidationError) when calling the UpdateStack operation: No updates are to be performed.`Beginner`InsufficientCapabilitiesException: Requires capabilities : [CAPABILITY_NAMED_IAM]`.BeginnerStack deletion ends in `DELETE_FAILED` with `The bucket you tried to delete is not empty` on an S3 bucket resource.IntermediateDrift detection shows `MODIFIED` on a security group and an RDS instance that someone changed in the console. How do you reconcile?Advanced