Subnet Calculator
Work out the network, the host range, the broadcast address and the masks of an IPv4 or IPv6 subnet, and whether another address is in it.
How Subnets Work
What is a Subnet?
An IP address has two parts: the network it belongs to, and the host within that network. The prefix length says where the split falls. In 192.168.1.10/24 the first 24 bits, 192.168.1, name the network, and the last 8 bits name the host.
Every address that starts with the same network bits is in the same subnet and is reached directly. Anything else is reached through a router, usually the default gateway.
How to Use
- Type an address with its prefix, as 192.168.1.10/24, or with its netmask, as 192.168.1.10 255.255.255.0. IPv6 works the same way: 2001:db8::1/64.
- The result appears as you type: the network, the addresses hosts can use, the broadcast address, the masks, and the kind of address block according to IANA.
- Is an address in this subnet? takes a second address and says whether the two are on the same network, the first question when two devices cannot reach each other.
- A click on a value selects all of it, ready to copy. The address bar follows what you type, so a result can be shared or bookmarked as a link.
Worked Examples
| 192.168.1.10/24 | Network 192.168.1.0, hosts .1 to .254, broadcast .255 |
| 10.20.30.40/20 | Network 10.20.16.0, hosts up to 10.20.31.254, 4,094 of them |
| 203.0.113.8/31 | A point-to-point link: both addresses are usable |
| 2001:db8::1/64 | One IPv6 network of 18,446,744,073,709,551,616 addresses |
Important Notes
- In IPv4 the first address of a subnet names the network and the last is its broadcast address, so neither can be given to a host. A /31 and a /32 are the exceptions: a point-to-point link and a single address.
- IPv6 has no broadcast address. A /64 is the usual size of one IPv6 network, because address autoconfiguration (SLAAC) expects it.
- A netmask is one unbroken run of ones followed by zeros. 0.0.0.255 is a wildcard mask, the form access lists use, and the page says so rather than guessing.
- A number with a leading zero, such as 010, is refused. Some systems read it as octal, where 010 is 8, so the same text would name two different addresses.
- The address type comes from the IANA special-purpose address registries, as published on 13 September 2026.
Privacy & Security: every calculation runs in your browser. No address you enter is sent anywhere, and the tool works with the network disconnected.
Try
Address type
In binary
The network bits in colour, the host bits after them.