100% Free No Sign-Up Unlimited Use No Limits Secure & Private
PDF Tools Calculators Categories Guides Contact No Sign-Up Needed to Use This Site
Result
--
Enter values to calculate.
Summary
--
Waiting for input
Detail
--
Waiting for input

Decode any IPv4 address with CIDR notation into its network address, subnet mask, broadcast address, and usable host range — a core task for network setup and troubleshooting.

How It Works

How IP Subnet Calculator Works

The calculator converts the four IP address octets and the CIDR prefix (the number after the slash) into 32-bit binary numbers. It builds the subnet mask by setting the first "prefix" number of bits to 1 and the rest to 0, then applies that mask to the IP address to find the network address (the first address in the subnet).

The broadcast address — the last address in the subnet, reserved for sending to every device on it — is found by taking the network address and setting every bit outside the mask to 1. The usable host range is everything between the network and broadcast addresses, excluding both, since those two addresses can't be assigned to individual devices.

Total usable hosts is calculated as 2 raised to the number of remaining (host) bits, minus 2 for the network and broadcast addresses — except for /31 and /32 prefixes, which are special cases with no separate broadcast address.

Worked Example

See It In Action

The address 192.168.1.10/24 belongs to network 192.168.1.0 with subnet mask 255.255.255.0, broadcast address 192.168.1.255, and 254 usable hosts ranging from 192.168.1.1 to 192.168.1.254.
Real-World Use Cases

Who Uses IP Subnet Calculator and Why

  • Working out how many usable host addresses a given /24 or /28 network actually provides before assigning IP addresses to office equipment.
  • Planning how to split a larger allocated block into smaller subnets for different departments or VLANs without overlapping ranges.
  • Double-checking a router or firewall's subnet mask configuration matches what a network diagram or ISP documentation specifies.
  • Studying for a networking certification exam where converting between CIDR notation and dotted-decimal subnet masks comes up repeatedly.
Common Mistakes

Mistakes to Avoid

  • Assuming the number of usable hosts equals 2 raised to the host-bit count — it's always two less than that, since the first address in the range identifies the network itself and the last is reserved as the broadcast address.
  • Confusing the CIDR prefix length with a host count directly — a /24 doesn't mean 24 hosts, it means 24 bits are reserved for the network, leaving 8 bits (254 usable hosts) for hosts.
  • Entering an IP address without the /prefix suffix and expecting a subnet calculation — the CIDR notation is what defines the subnet boundary, so the address alone isn't enough information.
Pro Tips

Tips for Best Results

  • If you're planning subnets ahead of time, start from the largest block you've been allocated and work out how a /25, /26, or /27 split would divide it before committing to a scheme.
  • Remember that a /32 refers to a single address, not a range — useful when you need to route or filter traffic to one exact device rather than a whole subnet.
Troubleshooting

Fixing Common Problems

The broadcast address the calculator shows doesn't match what I expected. — Recheck the CIDR prefix you entered — a common error is off-by-one prefix lengths (e.g., entering /25 when you meant /24), which shifts the entire range including the broadcast address.

I need to know how many subnets I can carve out of a larger block, not just the range of one subnet. — Calculate the target subnet's prefix length, then divide the size of your larger block by the size of each smaller subnet — this tool calculates one CIDR block at a time rather than a full subnetting plan.

Glossary

Terms Explained

CIDR (Classless Inter-Domain Routing): A notation that specifies an IP address alongside a prefix length (like /24), indicating how many bits of the address are reserved for the network portion.

Broadcast address: The last address in a subnet's range, reserved for sending a message to every device on that subnet at once — never assignable to an individual device.

Host bits: The bits of an IPv4 address not reserved for the network portion, which determine how many individual device addresses the subnet can hold.

FAQ

Frequently Asked Questions

Why are 2 addresses subtracted from the total host count?
The first address in a subnet is always reserved as the network address and the last as the broadcast address — neither can be assigned to an individual device, so they're excluded from the usable host count.
What's different about /31 and /32 subnets?
/32 identifies a single host with no room for a network or broadcast address, and /31 is a special two-address case (commonly used for point-to-point links) where both addresses are usable and there's no separate broadcast address, per RFC 3021.
How does the CIDR prefix relate to the subnet mask?
The CIDR prefix (like /24) is just a shorthand for how many bits of the subnet mask are set to 1 — /24 means the first 24 bits are 1, which corresponds to the subnet mask 255.255.255.0.
What if I enter an invalid IP address or prefix?
The calculator checks that each octet is between 0 and 255 and the prefix is between 0 and 32, and shows an error if the CIDR notation doesn't follow the correct format.