Course contents

Chapter 10: NAT ConfigurationLesson 1 of 7

Inside local, inside global and friends

The four NAT address names, explained with one simple picture.

Beginner · 7 min read

Technical definition

NAT address terms (inside local, inside global, outside local, outside global) are the names Cisco uses for the addresses in a translated packet. Inside and outside say which side of the router a host is on; local is the address as seen from the inside network, and global is the address as seen from the outside network.

One packet, two addresses

PC1 visits the server at 198.51.100.10. Ask PC1 what its address is, and it says 192.168.10.11. Ask the server who just visited, and it says 203.0.113.2. Both are right. They see the same device from different sides of R1. Cisco gives each view a name, and those names appear in every NAT command and every show output.

Inside and outside

First, R1 splits its interfaces into two sides:

  • Inside: the network you own and manage. Here, Gi0/0 toward the office.
  • Outside: everything else, usually the ISP and the internet. Here, Gi0/1.

You tell the router which is which with ip nat inside and ip nat outside on each interface. Translation only happens when a packet crosses from one side to the other.

Local and global

The second word tells you where you are looking from:

  • Local: the address as seen by devices on the inside network.
  • Global: the address as seen by devices on the outside network.

Put the two words together and you get four names:

Diagram
Local and global
Local and global
NameWhich device?Seen fromIn the office
Inside localAn inside hostThe inside192.168.10.11 (PC1's real address)
Inside globalAn inside hostThe outside203.0.113.2 (PC1 after translation)
Outside localAn outside hostThe inside198.51.100.10
Outside globalAn outside hostThe outside198.51.100.10 (the server's real address)
Read each row across: the left box names the item, the others describe it.

Memory trick: the first word says whose address it is (an inside or outside device). The second word says who is looking (local = inside eyes, global = outside eyes).

Why the outside addresses are usually the same

With the normal kind of NAT, called inside source NAT, R1 only changes the address of the inside device. The server's address passes through untouched, so its outside local and outside global are equal. They only differ if you also translate outside addresses, which is rare and outside the CCNA scope. Almost every NAT problem you meet is about the two inside addresses.

Diagram
The four NAT names on one trip
The four NAT names on one trip
Gi0/0 · insideGi0/1 · outsidePC1IP 192.168.10.11PC2IP 192.168.10.12Web1IP 192.168.10.50SW1NATR1 (NAT)edge routerISPIP 203.0.113.1InternetServerIP 198.51.100.10

Device key: PC1 (computer) · PC2 (laptop) · Web1 (server) · SW1 (switch) · R1 (NAT), ISP (router)

Lines show the example’s network connections. Thick links: uplinks/WAN, as labelled. The coloured path and envelope follow the current step; its text identifies the sender, receiver and traffic type.

Reading the addresses

IP labels identify interfaces or destinations. Subnet labels identify networks; /n is the prefix length. A router ID (RID) identifies a routing process and need not be a reachable interface.

An IP address alone is not a URL. A web URL includes a scheme such as https://; an address on a router or printer does not imply a website.

  • PC1: IP 192.168.10.11
  • PC2: IP 192.168.10.12
  • Web1: IP 192.168.10.50
  • R1 (NAT): edge router
  • ISP: IP 203.0.113.1
  • Server: IP 198.51.100.10
  1. 1. Before R1 (inside view): source = inside local 192.168.10.11, destination = outside local 198.51.100.10.
  2. 2. After R1 (outside view): source = inside global 203.0.113.2, destination = outside global 198.51.100.10. Only the source changed.
  3. 3. Reply, outside view: the server answers the inside global address. It never learns 192.168.10.11.
  4. 4. Reply, inside view: R1 swaps inside global back to inside local and delivers it to PC1.

The four names as table columns

The four names are the four columns of the translation table. This output is based on Cisco documentation, not run on a lab device.

Example output · based on Cisco documentation; exact format varies by platform and software version
R1#show ip nat translations
Pro Inside global         Inside local          Outside local         Outside global
tcp 203.0.113.2:49812     192.168.10.11:49812   198.51.100.10:443     198.51.100.10:443
Total number of translations: 1
Read each row left to right: PC1 (192.168.10.11) is talking to the server on port 443 (HTTPS), and the outside world sees PC1 as 203.0.113.2. The two outside columns match, as expected. The numbers after the colons are port numbers, covered in the “PAT (NAT overload)” lesson.

Test yourself on the four NAT names

Predict · scenario 1

In the office, which name describes 192.168.10.11?

Predict · scenario 2

The server at 198.51.100.10 sees requests coming from 203.0.113.2. What is 203.0.113.2?

Predict · scenario 3

With normal inside source NAT, which two addresses are usually the same?