CIDR Calculator

CIDR (RFC 4632) writes a prefix length after an address: 192.168.10.0/24 is 256 addresses, one network, one broadcast, 254 usable on a typical IPv4 LAN. This page computes network, broadcast, host range, and wildcard mask so a change ticket is arithmetic, not a guess. It does not assign addresses on your router.

What the CIDR calculator is for

A slash and a number (10.0.0.0/16) is how operators describe a block of IPv4 addresses. Getting the network, broadcast and host range wrong is how you overlap two VPCs or lock yourself out of a firewall change.

This page does the arithmetic locally: mask, wildcard, first and last usable host, and host count — including the /31 and /32 special cases used on point-to-point links.

Common uses

  • Planning a new VLAN or cloud subnet before you click Create
  • Checking whether an address sits inside a documented range
  • Explaining prefix length to someone who still thinks in class A/B/C

What the output means in the real world

The network, broadcast, first/last host, and mask rows describe the block you typed. Copy them into a firewall rule or a VPC diagram. Overlapping two calculated blocks on the same fabric causes asymmetric routing, not a warning from this page. IPv4 only here; do not treat the host count as a DHCP lease guarantee.

How this fits into real work

Cloud security groups and on-prem ACLs fail when someone writes /24 and meant /28. A /28 is 16 addresses (14 usable in the classic model). Run the numbers before you punch a hole to 0.0.0.0/0 'just for testing'.

RFC 1918 mergers collide because two companies both used 10.0.0.0/8. The calculator shows how small a NAT or a re-address would need to be. It will not negotiate the political half.

Wildcard masks in Cisco ACLs are the inverse of the subnet mask. Pasting the wrong one opens the adjacent /24. Check the wildcard row before you paste into a production ASA or IOS box.

How to use this tool

  1. Type an IPv4 address and prefix, such as 192.168.10.0/24 or 172.16.5.20/28.
  2. Read network and broadcast first. Those two addresses are not assignable on prefixes shorter than /31.
  3. Use the host count when sizing DHCP pools. A /24 is 254 usable hosts, not 256.

Tips

  • A /32 is a single host. A /31 is two addresses, both usable on a point-to-point link (RFC 3021).
  • This tool does not look up the public internet. It will happily compute a documentation prefix.

Privacy & how it works

Everything happens inside your browser. The values you type are held in page memory only, are never sent to a server, and disappear when you close the tab. You can confirm this in your browser's network tab: the only request a tool makes is one that names the tool for a usage count, with nothing you typed in it. The tools also work with the internet disconnected.

Frequently asked questions

Does this work for IPv6?
Not on this page. IPv6 CIDR is 128 bits and a different UI. Use an IPv6-specific calculator for those prefixes.

Browse other tools

All tools run entirely in your browser — nothing you type is sent to a server, except the optional HIBP 5-character hash prefix.