IP

Private Address Ranges

RFC 1918 private IP ranges, reserved addresses, and special-use addresses.

Public and private IPv4 addresses

IPv4 addresses have different scopes and purposes. A public address can be used for routing between independent networks, while a private address has local significance within an administrative domain. Other ranges serve special functions such as loopback and automatic link-local configuration.

A public IP address is assigned with the uniqueness required by the relevant routing system and can be advertised on the Internet. Routers use a prefix and prefix length when selecting a route. A service reachable from outside can run on a host with its own public address or behind a router address with port forwarding. Public IPv4 addresses are a managed and limited resource.

A private IP address has local and non-global significance and can be used at the same time in several independent networks. Two organizations can use 192.168.1.10 without a conflict while their routing domains remain separate. When such networks are connected, the address plan must be coordinated or translation must be used, because the repeated address does not identify one host globally.

Reserving private ranges lets organizations and households plan internal addressing without assigning a public address to every device. These addresses are not intended for global routing, so access to external networks usually requires NAT or another border mechanism. The ranges were formalized in .

RFC 1918 private address ranges

RFC 1918 defines three address blocks for private use. Public Internet routers should discard or avoid forwarding packets whose source or destination belongs to one of these ranges as a global address. This separates local addressing from public routing, while a device with can serve as a gateway for the required mappings.

1. The 10.0.0.0/8 block (historical Class A)

  • Address Range: 10.0.0.0 to 10.255.255.255
  • CIDR Notation: 10.0.0.0/8
  • Mask: 255.0.0.0
  • Total Addresses: 2242^{24}, or 16,777,216 addresses.

This is one block with a /8 prefix. In the historical classful model it corresponded to a Class A network, while current CIDR addressing can divide it into smaller prefixes according to an organization's plan. Twenty-four bits remain outside the prefix, giving 2242^{24} values in the whole block. Each subnet still requires routing only within the network that uses it.

2. The 172.16.0.0/12 block (historical Class B range)

  • Address Range: 172.16.0.0 to 172.31.255.255
  • CIDR Notation: 172.16.0.0/12
  • Mask: 255.240.0.0
  • Total Addresses: In the historical model, this block contains 16 contiguous Class B networks, totaling 16×65,536=1,048,57616 \times 65,536 = 1,048,576 addresses.

The /12 prefix leaves 20 bits for internal hosts and subnets. An organization can divide it into smaller prefixes while retaining the local meaning of the addresses. The sixteen consecutive second-octet values from 16 through 31 form one RFC 1918 block.

3. The 192.168.0.0/16 block (historical Class C range)

  • Address Range: 192.168.0.0 to 192.168.255.255
  • CIDR Notation: 192.168.0.0/16
  • Mask: 255.255.0.0
  • Total Addresses: In the historical model, this block contains 256 contiguous Class C networks, totaling 256×256=65,536256 \times 256 = 65,536 addresses.

The /16 prefix is often selected in small networks because it permits subnets from 192.168.0.0 through 192.168.255.0. An address such as 192.168.1.x indicates use of this private block, but the notation alone does not identify the topology or border device. The same values can be reused in another separated network.

Special-purpose addresses

Alongside public addresses and the RFC 1918 private ranges, IPv4 contains blocks assigned to specific functions. Their scope and forwarding behavior differ from private addressing. Special-purpose registries distinguish source addresses, destination addresses, routable ranges, and ranges intended only for local use.

Loopback: 127.0.0.0/8

Scope: Addresses in 127/8 identify the local host and are not used to communicate with other devices.

The entire 127.0.0.0/8 block is reserved for loopback purposes. The address used most often is 127.0.0.1, commonly called localhost. A packet sent to an address in this range is processed locally by the host networking stack and must not appear outside the host. This allows a client and server to run on one computer and communicate without a physical network interface. A source address from 127/8 must also not be sent beyond the host.

Link-local addresses: 169.254.0.0/16

Scope: The 169.254/16 prefix is used on one link and is not routed between subnets.

Link-local addresses are limited to one link. When a device is configured to obtain an IP address automatically through , and receives no response, it can configure an address from 169.254.0.0/16. In Windows, this automatic configuration is called APIPA. RFC 3927 defines these addresses as link-local and limits their use to the local link.

Devices on the same physical or logical link can communicate without a central server. Routers must not forward packets with addresses from 169.254.0.0/16 beyond that link, so the address does not provide Internet access or routing between subnets. It also does not replace a configured gateway or DNS server.

Unspecified address and default route: 0.0.0.0

The address 0.0.0.0 has several meanings depending on the field and context. A host without a configured address can use it as a source while requesting configuration through DHCP. In a routing table, the prefix 0.0.0.0/0 represents the default route, selected when no more specific prefix matches the destination.

How the address types interact in a home network

A typical home network combines a private range, DHCP, a default gateway, and NAT/PAT:

  • The ISP assigns one public IP addressto the home router, for example a real address allocated by the provider. This example uses the documentation address 203.0.113.45 from TEST-NET-3, so it is not an address assigned on the Internet. In a real deployment, that address is used on the router's external interface.
  • The router's built-in DHCP server is configured to use the private range 192.168.1.0/24 and assigns addresses from that subnet.
  • A laptop receives 192.168.1.100, a phone receives 192.168.1.101, and a television receives 192.168.1.102. The router has 192.168.1.1 on its internal interface.
  • The laptop opens example.com. Name resolution supplies a destination address in a remote network.
  • It sends a packet with source 192.168.1.100 and the resolved destination to its default gateway (192.168.1.1).
  • The router performs NAT/PAT, changes the source to the example's external address (203.0.113.45), and assigns an external port for the flow.

The router forwards the translated packet through its external interface. A reply returns to the translated address and port, and the NAT/PAT table delivers it to 192.168.1.100.

Summary of private addressing

RFC 1918 defines three blocks for local addressing: 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16. NAT can translate traffic between these ranges and public addresses. Loopback supports communication inside a host, link-local supports communication on one link, and 0.0.0.0/0 describes a default route.

IPv6 provides a much larger address space and can assign a global unicast address according to the operator's policy. Organizations can also use local IPv6 prefixes for internal communication. Special addresses, filtering, and routing rules still remain necessary for the behavior of a particular network.

Related articles