Cloud NAT Gateway
A cloud NAT (Network Address Translation) gateway is a managed service that lets resources in a private subnet initiate outbound connections to the internet — for software updates, API calls, or package downloads — while preventing any…
Definition
A cloud NAT (Network Address Translation) gateway is a managed service that lets resources in a private subnet initiate outbound connections to the internet — for software updates, API calls, or package downloads — while preventing any inbound connections from the internet from reaching them directly.
Overview
Resources in a private subnet, by design, have no public IP address and no direct route from the internet — that's the point of putting them there. But those resources often still need outbound internet access: an application server pulling OS security patches, a service calling a third-party API, or a container pulling a base image from a public registry. A NAT gateway solves this asymmetric need by acting as a managed intermediary: private resources route their outbound traffic through the NAT gateway, which itself sits in a public subnet with a public (or elastic) IP, translates the private resource's source IP to its own public IP for outbound requests, and forwards return traffic back to the originating private resource — while never allowing a connection to be initiated from the internet inbound. This is functionally similar to how a home router lets multiple devices on a private local network share one public IP to reach the internet, but implemented as a managed, highly available cloud service rather than a single device. Cloud providers (AWS NAT Gateway, GCP Cloud NAT, Azure NAT Gateway) handle the scaling, redundancy, and bandwidth of the NAT function, removing the operational burden of running and patching a self-managed NAT instance, which was the older pattern before managed NAT gateways existed. NAT gateways are typically deployed per availability zone (to avoid a cross-AZ single point of failure and cross-AZ data transfer charges) and are billed on both an hourly rate and per-gigabyte of data processed, which can become a meaningful cost line for services with high outbound data volume — a common cost-optimization exercise is auditing what's actually being pulled through a NAT gateway and whether it could instead go through a cheaper, more direct path like a VPC endpoint for supported AWS services. NAT gateways are a standard, near-universal component of any VPC architecture that includes private subnets needing any form of outbound internet reachability.
Key Features
- Allows outbound-only internet access for resources in private subnets
- Blocks all inbound connections initiated from the internet by design
- Managed, highly available service — no self-managed NAT instance to patch or scale
- Translates private resource IPs to the NAT gateway's public IP for outbound requests
- Typically deployed per availability zone to avoid cross-AZ dependency and transfer costs
- Billed on hourly usage plus per-gigabyte data processing charges
- Commonly used for OS patching, third-party API calls, and container image pulls from private subnets
- Can often be bypassed for specific AWS/GCP/Azure services using VPC endpoints/private service connect for cost savings
Use Cases
Alternatives
Frequently Asked Questions
From the Blog
Cloud Computing for Beginners: A Complete Guide
A comprehensive guide to cloud computing for beginners: a complete guide — written for learners at every level.
Read More Cloud & CybersecurityAWS vs Azure vs Google Cloud: Which to Learn?
A comprehensive guide to aws vs azure vs google cloud: which to learn? — written for learners at every level.
Read More Cloud & CybersecurityAWS for Beginners: Cloud Computing Fundamentals
Amazon Web Services is the world's most widely used cloud platform. This guide covers the core services every developer needs — EC2 (virtual servers), S3 (storage), IAM (access control), VPC (networking), and RDS (databases) — with practical setup instructions and free tier guidance.
Read More Cloud & CybersecurityInfrastructure as Code Explained: Terraform Basics
Clicking through cloud consoles doesn't scale. Infrastructure as Code (IaC) lets you define, version, and automate your cloud resources in code. This guide explains IaC concepts and walks you through Terraform — the most widely used IaC tool.
Read More