CIDR and subnet calculator
Type an IP with a prefix or mask to get the network, broadcast, host range, host count, netmask and wildcard. IPv6 works too.
Questions
Why are there 2 fewer usable hosts than addresses?
In an IPv4 subnet the first address names the network and the last is the broadcast address, so neither can be given to a host. The exceptions are /31, used for point-to-point links where both addresses are usable (RFC 3021), and /32, a single host.
What is a wildcard mask?
The inverse of the netmask: 0 bits must match and 1 bits can be anything. Cisco access lists and OSPF use it. For a /24 the netmask is 255.255.255.0 and the wildcard is 0.0.0.255.
How does IPv6 differ?
IPv6 has no broadcast address, so the range runs from the network address to the last address. Subnets are usually /64, which holds 18,446,744,073,709,551,616 addresses.