Subnetting looks like math. It's really just memorizing eight numbers and knowing which column to look in. Here's the table, then the trick.
| CIDR | Subnet mask | Addresses | Usable hosts |
|---|---|---|---|
| /30 | 255.255.255.252 | 4 | 2 |
| /29 | 255.255.255.248 | 8 | 6 |
| /28 | 255.255.255.240 | 16 | 14 |
| /27 | 255.255.255.224 | 32 | 30 |
| /26 | 255.255.255.192 | 64 | 62 |
| /25 | 255.255.255.128 | 128 | 126 |
| /24 | 255.255.255.0 | 256 | 254 |
| /23 | 255.255.254.0 | 512 | 510 |
| /22 | 255.255.252.0 | 1,024 | 1,022 |
| /21 | 255.255.248.0 | 2,048 | 2,046 |
| /20 | 255.255.240.0 | 4,096 | 4,094 |
| /16 | 255.255.0.0 | 65,536 | 65,534 |
| /8 | 255.0.0.0 | 16,777,216 | 16,777,214 |
Usable hosts are always two fewer than total addresses — one goes to the network ID, one to the broadcast. The exceptions: /31 is a special case for point-to-point links (2 usable, no broadcast, per RFC 3021), and /32 is a single host, used for loopbacks and host routes.
Every mask octet is one of these: 128, 192, 224, 240, 248, 252, 254, 255. Each step doubles the subnets and halves the hosts. If you know that row, you know subnetting.
/26 (mask 192): 256 − 192 = 64. So subnets start at .0, .64, .128, .192. That's the whole method.Question: what network is 192.168.1.100/26 in, and what's its range?
That's it. No binary conversion, no calculator. Find the block size, count up in it, back up one.
Work backwards with 2ⁿ − 2, where n is the number of host bits left:
| Range | What it is |
|---|---|
| 10.0.0.0/8 | Private (RFC 1918) — the big one |
| 172.16.0.0/12 | Private — covers 172.16 through 172.31 |
| 192.168.0.0/16 | Private — home and small office |
| 169.254.0.0/16 | Link-local (APIPA). Seeing this means DHCP failed. |
| 127.0.0.0/8 | Loopback |
Subnetting & CIDR Cheat Sheet + Practice Problems. One page to pin up, plus worked problems to drill before an exam or interview.
Get the sheet — $4 →Pairs well with the ports and protocols reference — the other thing you'll be asked to recite.