Subnet calculator
Enter an IP address and a prefix (or a notation like 192.168.1.10/24) and instantly see the network address, broadcast, mask, wildcard, range and the number of usable hosts. Useful for network design and learning. Everything is computed in your browser. The basics are in What is an IP address, and subnets and prefixes in detail in What is a subnet and CIDR.
Frequently asked questions
What is a CIDR prefix (for example /24)?
It says how many bits of the address define the network. /24 means 24 bits for the network and 8 for hosts, which is the mask 255.255.255.0 and 254 usable addresses.
Why are there two fewer usable hosts?
The first address in a subnet is the network address and the last is the broadcast, and those are not assigned to devices. This does not apply to /31 (point-to-point) and /32 (single host).
What is the difference between a private and a public IP?
Private ranges (10.x, 172.16-31.x, 192.168.x) are used inside networks and are not routable on the internet. There is more in our What is an IP address article.
What is a wildcard mask?
It is the opposite of a subnet mask, the bits are inverted (0s and 1s swapped). It is used, for example, in access lists on Cisco routers, where you write a wildcard mask instead of a subnet mask.
How do I know how many subnets I get by splitting a larger network?
The number of new subnets is 2 to the power of the added mask bits. For example, splitting a /24 into /26 adds 2 bits, giving you 4 subnets with 62 usable hosts each.
How do I know if two devices are on the same network?
If they have the same network address for a given mask, they are on the same subnet and can connect directly. If the network addresses differ, the traffic has to go through a router.
