AxiomBlueprint

IPv4 subnet calculator with a VLSM planner

Subnetting is easy to understand and easy to get wrong at 2 a.m. This page has two tools. The first takes any IPv4 address and prefix length and shows the network address, broadcast address, subnet mask, wildcard mask, first and last usable host, and the number of usable hosts.

The second plans variable length subnet masks (VLSM). Give it a parent block and the number of hosts each VLAN needs. It sorts the requests from largest to smallest, gives each one the smallest block that fits, and lays them out without overlap so the leftover space stays in one piece.

Subnet details

VLSM planner

How the math works

  • A prefix of /p leaves 32 - p host bits, which is 2 to that power addresses in the block.
  • Usable hosts are the block size minus 2 (the network and broadcast addresses). A /31 is a special case for point-to-point links and uses both addresses. A /32 is a single host.
  • VLSM picks the smallest power of two with room for the hosts, then aligns each block to its own size.

Leave room to grow. If a VLAN needs 100 hosts today, plan for the next size up.

Worked example

192.168.1.130/26 is in the network 192.168.1.128, with broadcast 192.168.1.191 and mask 255.255.255.192. The usable range is .129 to .190, which is 62 hosts. For VLSM, split 192.168.0.0/24 for 100, 50, 25 and 10 hosts. You get 192.168.0.0/25, 192.168.0.128/26, 192.168.0.192/27 and 192.168.0.224/28, which uses 240 of the 256 addresses.

Questions people ask

Why are two addresses unusable?

The first address names the subnet and the last is the broadcast address. Hosts cannot use either, except in /31 and /32 blocks.

Why does VLSM sort largest first?

Big blocks need big alignment. Placing them first avoids gaps that waste space.

Does this handle IPv6?

Not yet. This page is IPv4 only.

Guides

More free tools

Estimates only. Built with AI assistance and checked with automated tests. Not tax, legal, financial or engineering advice.