Labs ICT
Pro Login

IP Addressing

The addressing system that makes the internet possible.

The Internet's Addressing System

Every device on the internet needs a unique address — just like every house needs a unique mailing address. IP addressing is the system that gives every device on a network a logical address so data can find its way to the right place.

The most widely used version is IPv4, which uses 32-bit addresses written as four decimal numbers separated by dots.

IPv4 Address Format


  Dotted Decimal:     192.168.1.100
  Binary:             11000000.10101000.00000001.01100100
                      │←─ Network ─→││←── Host ──→│

An IPv4 address has two parts:

  • Network portion — Identifies which network the device is on. All devices on the same network share the same network portion.
  • Host portion — Identifies the specific device within that network.

The subnet mask determines where the network portion ends and the host portion begins. A common subnet mask is 255.255.255.0, which means the first three octets are the network and the last octet is the host.

IP Address Classes

IPv4 addresses were originally divided into classes based on the size of the network:


  Class │ First Octet │ Default Mask   │ Networks    │ Hosts/Network
  ──────┼─────────────┼────────────────┼─────────────┼──────────────
  A     │ 1-126       │ 255.0.0.0      │ 126         │ 16 million
  B     │ 128-191     │ 255.255.0.0    │ 16,384      │ 65,534
  C     │ 192-223     │ 255.255.255.0  │ 2 million   │ 254
  D     │ 224-239     │ N/A            │ N/A         │ Multicast
  E     │ 240-255     │ N/A            │ N/A         │ Reserved

Classful addressing was replaced by CIDR (Classless Inter-Domain Routing) in 1993, which allows more flexible subnet masks. But understanding the classes helps explain why certain address ranges look familiar.

Special IP Addresses

  • 127.0.0.1 — Loopback address (localhost). Refers to your own machine. Used for testing.
  • 10.0.0.0 - 10.255.255.255 — Private range for internal networks. Not routable on the internet.
  • 172.16.0.0 - 172.31.255.255 — Another private range.
  • 192.168.0.0 - 192.168.255.255 — The most common private range for home networks.
  • 255.255.255.255 — Broadcast address. Sends data to all devices on the local network.
  • 169.254.x.x — APIPA (Automatic Private IP Addressing). Assigned when DHCP fails.

Private addresses are why your home network can use 192.168.1.x even though millions of other homes use the same range. Your router translates between private addresses and your public IP using NAT (Network Address Translation).

Public vs. Private Addresses


  INTERNET (Public IPs only)
  ══════════════════════════════════════
        │
   ┌────┴────┐
   │  Router │  Public IP: 203.0.113.50
   └────┬────┘
        │ NAT
  ──────┼───────────────
  HOME NETWORK (Private IPs)
  │         │         │
  PC1       PC2       Phone
  192.168   192.168   192.168
  .1.10     .1.11     .1.12

Your router has one public IP address (assigned by your ISP) and gives private addresses to devices on your home network. When a device wants to access the internet, the router replaces the private source IP with its public IP using NAT.