Skip to main content
networking

CIDR (Classless Inter-Domain Routing)

CIDR notation expresses an IP address range using a base address and a prefix length (e.g., 192.168.1.0/24). The /24 means the first 24 bits are fixed – the network address – leaving 8 bits for hosts (256 addresses). CIDR replaced the old fixed class system (Class A/B/C) to allow more flexible IP allocation.

Definition

CIDR notation: IP_address/prefix_length. The prefix length is the number of bits in the network portion. /24 = 256 addresses (2^8), /16 = 65536 addresses (2^16), /32 = exactly 1 address. Common subnets: /8 (16M addresses, e.g., 10.0.0.0/8 – private), /16 (65K addresses, e.g., 172.16.0.0/16 – private), /24 (256 addresses – typical office subnet). IPv6 uses the same notation: 2001:db8::/32 is a documentation prefix. Cloud security groups and firewall rules use CIDR for IP allowlisting.

Examples

  • 192.168.1.0/24 – 256 addresses (192.168.1.0 to 192.168.1.255)
  • 10.0.0.0/8 – 16 million addresses (private network)
  • 0.0.0.0/0 – all IPv4 addresses (allow any)

Related Protocols

Related Terms