How do you subnet a /8 prefix to create roughly 1000 subnets (e.g. an ISP using 10.0.0.0/8)?
Borrow 10 bits (2^10 = 1024 ≥ 1000) → /18; a /8 has 24 host bits, of which up to 22 can be borrowed.
When you need a target number of subnets, you find the smallest number of borrowed bits n where 2^n meets or exceeds that target — powers of two rarely land exactly on a round number, so you round up. For 1000 subnets, 2^9 = 512 is too few but 2^10 = 1024 covers it, so you borrow 10 bits. Adding those 10 bits to the /8 starting prefix gives /18. A /8 starts with a generous 24 host bits (the 2nd, 3rd and 4th octets), so even after borrowing 10 you still have 14 host bits left, yielding 2^14 − 2 = 16,382 hosts per subnet. The reason you can borrow at most 22 of those 24 bits is that every subnet must keep at least 2 host bits — one address for the network ID and one for the broadcast — so the longest usable prefix is /30. This trade-off (more subnets costs hosts-per-subnet, and vice versa) is exactly how large ISPs slice a single /8 into thousands of customer networks.
Working:
- 10.0.0.0/8 has 24 host bits (2nd, 3rd, 4th octets).
- Need ≥ 1000 subnets → smallest n with 2^n ≥ 1000 is n = 10 (2^10 = 1024).
- New prefix = /8 + 10 = /18.
- Host bits left = 24 − 10 = 14 → 2^14 − 2 = 16,382 usable hosts per subnet.
Key point: with a /8 you have huge flexibility — up to 22 host bits can be borrowed (the final 2 must stay as host bits). This is how large ISPs carve a single big block into many client networks.
Go deeper:
IPv4 address exhaustion (Wikipedia) — why even huge /8 blocks ran out and how ISPs slice them.
ipcalc (jodies.de) — enter 10.0.0.0/18 to confirm the 16,382 hosts per subnet.