Subnet Calculator

Calculate IPv4 and IPv6 network ranges, masks and host counts from CIDR.

DNS and network Runs in your browser: nothing you enter is sent to a server.

About the Subnet Calculator

A subnet groups IP addresses that share a network prefix. CIDR notation such as 192.168.10.0/24 gives the address and the number of prefix bits.

The calculator shows the network and broadcast addresses, netmask, wildcard mask (used in Cisco ACLs), the usable host range and number of hosts, and whether the range is private or public. IPv6 prefixes are supported too.

How to use it

  1. Enter an address with prefix, e.g. 10.0.0.0/22 or 2001:db8::/48.
  2. Read the calculated values.
  3. Adjust the prefix to compare sizes.

Frequently asked questions

How many hosts does a /24 have?

A /24 has 256 addresses, of which 254 are usable for hosts: the first is the network address and the last the broadcast address. A /31 (RFC 3021) and /32 are special cases with 2 and 1 usable addresses.

What is a wildcard mask?

The inverse of the netmask: 0 bits must match, 1 bits are ignored. For /24 the netmask is 255.255.255.0 and the wildcard mask 0.0.0.255. Cisco ACLs and OSPF use wildcard masks.

Which IPv4 ranges are private?

10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 (RFC 1918). 100.64.0.0/10 is shared address space for carrier-grade NAT (RFC 6598).

All free tools