NAT Explained
Network Address Translation is the trick that let the internet survive IPv4 exhaustion: your router rewrites addresses so an entire household shares one public IP, and somehow everything still works.
NAT types in practice
| Type | Behavior | Typical context |
|---|---|---|
| Static NAT | One-to-one mapping | Servers with dedicated public IPs |
| Dynamic NAT | Pool of public IPs | Larger office networks |
| PAT (NAT overload) | Many private IPs to one public IP with ports | Home routers, most SMB networks |
How it works
- A device inside sends a packet out; the router replaces its private source address (192.168.1.x) with the public IP and records the connection in a translation table.
- Replies come back to the public IP; the router matches them to the table entry and forwards to the original device.
- Unsolicited inbound packets with no table entry are dropped: that is why NAT is accidental firewall protection, and why hosting behind it needs port forwarding.
What NAT breaks and why
- Inbound hosting: nothing can reach your devices until you forward ports.
- End-to-end applications: VoIP, P2P, and some games need NAT traversal (STUN/TURN).
- Mail sending: consumer NAT space is blocklisted by policy (that is what Spamhaus PBL tracks), so mail must relay through a smarthost.
The public side of the translation uses whatever address your ISP assigns, and the Static vs Dynamic IP Addresses guide shows how to tell whether yours changes on reconnect. For IPv6-only clients reaching IPv4 destinations through DNS64 and NAT64 gateways, generate 64:ff9b::/96 and 64:ff9b:1::/48 translated addresses locally in the IPv4 to IPv6 converter.
Frequently asked questions
Does NAT protect me from hackers?+
It blocks unsolicited inbound connections, which is real protection, but it is not a firewall you configure: outbound threats and phishing pass freely.
Why does IPv6 remove NAT?+
Every device gets a globally routable address, so translation is unnecessary; the same protection comes from proper firewalls.
What is CGNAT?+
Carrier-grade NAT: your ISP applies the same trick to whole neighborhoods, stacking another layer. It breaks port forwarding entirely and puts hundreds of users behind one address.
Related
Last verified: 2026-12-01