IPv4 subnet calculator

    Work out network address, broadcast, mask, host range and size from CIDR.

    Loading tool…

    About the ipv4 subnet calculator

    Works out the network and broadcast addresses, usable host range, host count, wildcard mask and address class from any CIDR block or address-and-mask pair. A binary view shows exactly where the prefix boundary falls, and /31 and /32 are handled correctly.

    Frequently asked questions

    Why are two addresses unusable in a subnet?

    The first identifies the network itself and the last is the broadcast address. A /24 therefore offers 254 usable hosts out of 256. Point-to-point /31 links are the documented exception.

    How many hosts does a /22 hold?

    1024 addresses, 1022 usable. Each bit you take from the prefix doubles the block, so /23 is 512 and /21 is 2048.