Subnet calculator
Enter any IPv4 address and prefix to get the network, broadcast, usable host range, netmask and wildcard. With the network and host bits laid out in binary so the math is visible, not magic. Then split the network into smaller subnets for VLSM planning.
Network
- Network
- —
- Broadcast
- —
- First usable host
- —
- Last usable host
- —
- Usable hosts
- —
- Total addresses
- —
- Netmask
- —
- Wildcard
- —
Binary breakdown
Bits: network host. The prefix length is simply how many bits belong to the network.
Subnets ()
| # | Network | Host range | Broadcast | Hosts |
|---|
Showing the first 128 subnets. Export or narrow the split to see the rest.
How subnetting works
An IPv4 address is 32 bits. The prefix (the /24 in CIDR notation) says how many of those bits identify the network; the rest identify hosts inside it. The netmask is the same information written as an address: /24 = 255.255.255.0, i.e. 24 ones followed by 8 zeros. The wildcard mask is its inverse, used in ACLs and OSPF configuration.
The network address is the input address with all host bits set to zero (IP AND mask); the broadcast sets them all to one. Everything in between is usable by hosts, which is why a subnet holds 2^(host bits) − 2 addresses. Minus network and broadcast. Two special cases: /31 keeps both addresses for point-to-point links (RFC 3021), and /32 is a single host route.
Splitting a network borrows host bits to create more, smaller networks: each extra prefix bit doubles the subnet count and halves their size. That's all VLSM is. Choosing a different split per branch so address space matches actual need.