Subnetting in Minutes: The Cheatsheet That Sticks
One trick — the block size — answers 95% of subnet questions. Masks, ranges, host counts, and design, in one page you'll actually use.
The cheat sheet table — /24 to /30
| Prefix | Subnet mask | Wildcard mask | Block size | Usable hosts |
|---|---|---|---|---|
| /24 | 255.255.255.0 | 0.0.0.255 | 256 | 254 |
| /25 | 255.255.255.128 | 0.0.0.127 | 128 | 126 |
| /26 | 255.255.255.192 | 0.0.0.63 | 64 | 62 |
| /27 | 255.255.255.224 | 0.0.0.31 | 32 | 30 |
| /28 | 255.255.255.240 | 0.0.0.15 | 16 | 14 |
| /29 | 255.255.255.248 | 0.0.0.7 | 8 | 6 |
| /30 | 255.255.255.252 | 0.0.0.3 | 4 | 2 |
Worked split: 192.168.1.0/24 into four /26s
Need four separate networks from one /24? Borrow 2 bits from the host part — 22 = 4 — and the prefix becomes /26. Each new subnet is a block of 64 addresses, so the blocks start at .0, .64, .128 and .192, and in each block the first address names the network and the last is its broadcast.
| Subnet | Usable range | Broadcast |
|---|---|---|
| 192.168.1.0/26 | 192.168.1.1–192.168.1.62 | 192.168.1.63 |
| 192.168.1.64/26 | 192.168.1.65–192.168.1.126 | 192.168.1.127 |
| 192.168.1.128/26 | 192.168.1.129–192.168.1.190 | 192.168.1.191 |
| 192.168.1.192/26 | 192.168.1.193–192.168.1.254 | 192.168.1.255 |
The apartment building analogy
Think of 192.168.7.0/24 as an apartment building at 192.168.7 Street with 256 units:
- The network address is the building itself — 192.168.7.0. It names the block; no device can use it.
- The broadcast address is the building's PA system — 192.168.7.255. Shout here and every unit hears you. Also not assignable.
- Usable hosts are the actual apartments — .1 through .254, where devices live.
The mask (the /24) is the architect's decision about how big the building is. Change it to /26 and you have split the building into four smaller ones of 64 units each. That splitting is subnetting.
Under the hood, addresses are 32 binary digits (bits). The mask is 32 bits too: a run of 1s (the network part) followed by 0s (the host part). /24 means "the first 24 bits are the network." Everything below follows from that one sentence.
Try it: the mask stepperPress the buttons and watch what happens to the bits. Green bits are the network part (locked); amber bits are the host part. Each extra mask bit doubles the number of subnets and halves the hosts per subnet.