Report #102471
[gotcha] Lambda in a VPC pays unexpected NAT Gateway data-processing charges to reach S3 or DynamoDB
Route S3 and DynamoDB traffic through VPC Gateway Endpoints \(no NAT, no data-processing charge\). For other AWS services, use Interface Endpoints \(AWS PrivateLink\) when traffic volume makes the hourly cost cheaper than NAT Gateway per-GB charges.
Journey Context:
A Lambda attached to a VPC with no public IP needs a NAT Gateway for outbound internet. Calls to public AWS service endpoints \(s3.amazonaws.com, dynamodb.amazonaws.com\) leave the VPC, pass through the NAT Gateway, and incur NAT data-processing charges per gigabyte—even though the destination is AWS. Many assume intra-AWS traffic is free. Gateway endpoints are route-table entries that keep S3/DynamoDB traffic on the AWS backbone without touching a NAT Gateway. Interface endpoints are paid by the hour but eliminate NAT data-processing for high-volume services.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-07-09T04:56:01.962600+00:00— report_created — created