Skip to main content
Networking
Published 8 min read

CIDR Calculator Guide: Find Network, Broadcast and Usable IP Addresses

Here's exactly what a CIDR calculator computes, walked through with three real address blocks.

A CIDR calculator takes one input - an IP address with a prefix length, like 192.168.1.0/24 - and returns everything meaningful about that network: where it starts, where it ends, and which addresses in between are actually usable. Here's what each output means, walked through with three real examples.

What gets calculated

OutputMeaning
Network addressThe first address in the block - identifies the network itself, not assignable to a host
Broadcast addressThe last address in the block - reserved for broadcasting to every host on the network
Subnet maskThe dotted-decimal equivalent of the prefix length
Wildcard maskThe inverse of the subnet mask, used in some router/ACL configurations
First usable / last usableThe actual assignable range for hosts
Total / usable host countHow many addresses exist, and how many can be assigned

Example 1: 192.168.1.0/24

FieldValue
Network address192.168.1.0
Broadcast address192.168.1.255
Usable range192.168.1.1 - 192.168.1.254
Usable hosts254
Subnet mask255.255.255.0

Example 2: 10.0.0.0/16

FieldValue
Network address10.0.0.0
Broadcast address10.0.255.255
Usable range10.0.0.1 - 10.0.255.254
Usable hosts65,534
Subnet mask255.255.0.0

Example 3: 172.16.10.0/24

FieldValue
Network address172.16.10.0
Broadcast address172.16.10.255
Usable range172.16.10.1 - 172.16.10.254
Usable hosts254
Subnet mask255.255.255.0

What if the IP you enter isn't the network address?

This is one of the more useful things a calculator handles automatically: if you enter 192.168.1.130/24, the calculator still correctly identifies 192.168.1.0 as the network address and 192.168.1.255 as the broadcast address for that block - it rounds down to the actual network boundary regardless of which specific host address you started from.

When this matters in practice

  • Provisioning a cloud VPC or subnet and needing to confirm the exact usable range before assigning IPs
  • Writing a firewall rule scoped to a specific block and needing the precise network/broadcast boundaries
  • Documenting network architecture and needing accurate subnet boundaries, not estimates
  • Troubleshooting connectivity issues where a device's IP doesn't match the expected subnet

The CIDR Calculator produces all of this instantly for any IPv4 block, along with a binary breakdown showing exactly which bits are network vs. host.

Common mistakes

  • Assuming the network address is always "x.x.x.0" - that's only true for /24 and larger; for smaller subnets like /26, network addresses can end in 0, 64, 128, or 192.
  • Trying to assign the network or broadcast address to a device.
  • Forgetting that /31 and /32 don't follow the standard network/broadcast pattern at all.

For the underlying math behind these calculations, see How to Calculate the Number of IP Addresses in a CIDR Block and What Is CIDR? A Complete Guide to Classless Inter-Domain Routing.

Summary

A CIDR calculator turns one input (address + prefix) into the complete picture of a network: its boundaries, its usable range, and its size - work that's straightforward for a /24 but genuinely error-prone to do by hand for less common prefixes.

Frequently asked questions

What does a CIDR calculator actually calculate?
Given an IP address and a prefix length, it computes the network address, broadcast address, subnet mask, wildcard mask, and the range of usable host addresses in between.
Why can't I just do this math manually every time?
You can for common prefixes like /24, but for less common ones - /21, /27, /29 - manual binary math is slow and easy to get wrong, especially under time pressure while provisioning infrastructure.
Does a CIDR calculator work for any starting IP address, or only round numbers?
Any valid IPv4 address works. The calculation rounds down to find the network address for that block, regardless of which specific address within the range you started from.

The tool that pairs with this guide.

Did this make subnetting easier?

If these free developer tools save you time, consider buying me a byte. Your support helps keep DevCraftKit free and growing.

Buy me a byte 💾