Subnet Cheat Sheet: CIDR, Subnet Masks and Host Counts

Subnetting splits an IP network into smaller pieces. Most of the time you just need the mask, the host range and how many devices fit.

🧮Free IP Subnet Calculator
CIDR, subnet mask, broadcast and host range.
Open tool →

Common CIDR sizes

/30 = 255.255.255.252, 2 hosts · /29 = .248, 6 · /28 = .240, 14 · /27 = .224, 30 · /26 = .192, 62 · /25 = .128, 126 · /24 = 255.255.255.0, 254 · /23 = 255.255.254.0, 510 · /22 = 255.255.252.0, 1,022 · /16 = 255.255.0.0, 65,534.

Private ranges

10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 are private (RFC 1918) and not routed on the internet.

Network, broadcast and hosts

The first address is the network ID and the last is the broadcast; everything in between is usable (except /31 and /32 special cases). Enter any address like 10.20.30.40/22 in the IP Subnet Calculator to get all of these instantly.

Quick trick

Hosts = 2^(32 – prefix) – 2. A /26 has 2^6 – 2 = 62 usable hosts.

Frequently asked questions

What is CIDR notation?

Address/prefix, where the prefix is how many bits are the network.

What is a wildcard mask?

The inverse of the subnet mask, used in ACLs: /24 = 0.0.0.255.

Does it support IPv6?

Not yet – IPv6 subnets are usually /64.

🧮Free IP Subnet Calculator
CIDR, subnet mask, broadcast and host range.
Open tool →

More guides