Loading Techie Utils…

VLSM Calculator

Plan subnets by the number of hosts each one needs, with VLSM. Free, and runs entirely in your browser — nothing you enter is uploaded or stored.

About Subnet Calculator

Enter a block in either family — 10.20.0.0/22, 192.168.1.10 255.255.255.0 or 2001:db8::/48 — and get the network address, mask, range, host counts and what the block is reserved for. It answers the questions that come up while writing firewall rules, security groups and DHCP scopes.

The counter-intuitive part of IPv4 is that two addresses in every ordinary subnet are unusable: the network address itself and the broadcast address. A /30 has four addresses and exactly two usable hosts, which is why point-to-point links are usually /30, or /31 where both ends may be used. IPv6 has no broadcast address and reserves nothing, so a /64 really does hold 2^64 addresses.

Beyond the summary it will list the addresses themselves in a table, from either end of the block, and split a block into equal children at a longer prefix. Two optional questions sit alongside: whether a particular address or block falls inside it — or only partly overlaps it — and which is the smallest prefix that would hold a given number of hosts.

Planning views. *Plan subnets by host count* takes a list such as web 120 and database 50 and carves each a right-sized subnet out of the block, largest first so nothing is wasted, then says what is left. *Summarise a list* merges CIDRs, single addresses and start - end ranges into the fewest blocks that cover exactly the same addresses, and names the entries that overlap. *Neighbouring blocks* shows the previous and next block, the sibling it would merge with, and the blocks that enclose it; *Binary* draws the address and mask bit by bit with the network part marked; *Reverse DNS zones* lists the in-addr.arpa or ip6.arpa zones the block needs, including RFC 2317 delegation for anything smaller than a /24.

Where it helps

  • Both address families, including IPv6 compression, expansion and the count of /64s inside a prefix.
  • Every field a firewall or routing rule asks for, including the wildcard mask and the usable range stated explicitly.
  • Lists the addresses themselves, and splits a block into equal children for VLSM planning.
  • Names what a block is reserved for, from RFC 1918 and carrier-grade NAT through to IPv6 documentation and unique-local space.
  • Answers the two planning questions directly: is this address inside the block, and what prefix fits this many hosts?

Limits

  • It does no overlap analysis between two separate blocks, which is a different planning question.
  • Cloud providers reserve extra addresses in each subnet — AWS takes five — which this does not model.
  • Address and subnet listings are capped, at 512 and 256 rows, because a /8 cannot be listed and would not be read.
  • It describes addressing, not reachability: routes, ACLs and security groups decide what can actually talk.

Frequently asked questions

Why does a /24 have 254 usable hosts rather than 256?

The first address identifies the network and the last is the broadcast address. Neither can be assigned to a host.

Does the same reservation apply to IPv6?

No. IPv6 has no broadcast address, so every address in the prefix is usable; the first is the subnet-router anycast address, which routers answer to rather than it being lost.

How many addresses does each prefix hold?

Two to the power of the bits left over: 32 minus the prefix for IPv4, 128 minus it for IPv6. A /24 has 256, a /64 has 2^64.

What is the wildcard mask for?

It is the inverted subnet mask, used by Cisco access lists and some routing protocols where a normal mask is not accepted.

Why should an IPv6 subnet be a /64?

Stateless address autoconfiguration assumes 64 bits of interface identifier. A longer prefix works for point-to-point links but leaves hosts needing DHCPv6 or static addresses, and the tool says so when you enter one.

Which private ranges should I use?

10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 for IPv4, and a randomly chosen fd00::/8 prefix for IPv6. Plan for growth and avoid overlapping with networks you may later peer with.

Related tools

More Calculators tools