How to Use This Tool
Enter a block and get the addresses. The reserved ones are labelled rather than silently included, and you can choose to leave them out entirely.
Why a /24 gives 254 and not 256
Two addresses in every ordinary subnet are reserved:
- The network address, all host bits zero, identifies the subnet itself. It appears in routing tables and is not assigned to a machine.
- The broadcast address, all host bits one, reaches every host on the subnet at once. It is not a single machine either.
So usable hosts are total minus two. A /24 gives 254, a /28 gives 14, a /30 gives 2. Iterating the full range in a script means two addresses that nothing will ever answer on, which wastes scan time and looks like failed connections in logs.
The /31 and /32 exceptions
Applying minus-two to a /31 gives zero usable hosts, and to a /32 gives minus one. Both answers are wrong, and calculators that print them are applying a rule outside its range.
- /32 is a single host — one address, usable. It is how you express one machine in a firewall rule or a route.
- /31 is two addresses, and RFC 3021 allows both to be used, for point-to-point links between routers where there is nothing to broadcast to. It saves two addresses per link, which adds up across a large network.
When not to expand a block
Anything larger than about a /16 produces a list nobody wants. Sixty-five thousand lines is already awkward; a /8 is over sixteen million and would freeze the tab before it finished. Output here is capped, and the count is still reported so you know what you asked for.
More to the point, most tools that take addresses also take CIDR notation, and giving them the block is better in every way: shorter, self-documenting, and it does not need regenerating when the subnet changes. Expand when the target genuinely cannot parse a prefix — some older appliances, some spreadsheet work, some ad-hoc scripts.
Private ranges worth recognising
10.0.0.0/8— 16.7 million addresses, the largest private block.172.16.0.0/12— a million addresses; note it runs to 172.31, not 172.16 only.192.168.0.0/16— 65,536 addresses, the home-router range.169.254.0.0/16— link-local. An address here usually means DHCP failed.127.0.0.0/8— loopback. The whole /8, not just 127.0.0.1.
