What is CIDR and why does it matter?
CIDR stands for Classless Inter-Domain Routing. It is the standard way to describe an IP network and its size using the /prefix notation. For example, in 192.168.1.0/24, the /24 means the first 24 bits identify the network, and the remaining bits identify hosts.
A CIDR range calculator saves time when planning subnets, configuring routers, defining firewall policies, creating cloud VPCs, or documenting IP plans. Instead of manually converting subnet masks to binary, you can instantly see network address, broadcast address, first and last usable IP, and host capacity.
How this CIDR range calculator works
Enter any valid IPv4 CIDR block, click Calculate Range, and the tool computes:
- Subnet mask (for example, 255.255.255.0)
- Wildcard mask (the inverse of subnet mask)
- Network address (first address in the block)
- Broadcast address (last address in the block)
- Usable host range and usable host count
- Address type (private, public, loopback, link-local, etc.)
This calculator supports every prefix length from /0 through /32. It also handles edge cases like /31 and /32, which are commonly used for point-to-point links and single-host routes.
Quick CIDR reference for common subnet sizes
| CIDR | Subnet Mask | Total Addresses | Usable Hosts* |
|---|---|---|---|
| /24 | 255.255.255.0 | 256 | 254 |
| /25 | 255.255.255.128 | 128 | 126 |
| /26 | 255.255.255.192 | 64 | 62 |
| /27 | 255.255.255.224 | 32 | 30 |
| /28 | 255.255.255.240 | 16 | 14 |
| /29 | 255.255.255.248 | 8 | 6 |
| /30 | 255.255.255.252 | 4 | 2 |
| /31 | 255.255.255.254 | 2 | 2 |
| /32 | 255.255.255.255 | 1 | 1 |
*Traditional usable host rule is total minus 2, except /31 and /32 special cases.
Example: calculating a subnet by hand
Input: 10.20.30.40/20
A /20 prefix corresponds to subnet mask 255.255.240.0. That means the third octet increments in blocks of 16: 0, 16, 32, 48, and so on. Since the third octet is 30, this host belongs to the block that starts at 16.
- Network: 10.20.16.0
- Broadcast: 10.20.31.255
- Usable host range: 10.20.16.1 - 10.20.31.254
- Total addresses: 4096
- Usable hosts: 4094
That is exactly the sort of mental load this calculator removes from daily network engineering tasks.
Where CIDR calculations are used
- Cloud networking: AWS VPC, Azure VNets, Google Cloud subnets
- On-prem infrastructure: VLAN planning, DHCP scopes, route summaries
- Security: firewall ACLs, VPN split tunnels, zero-trust segmentation
- Operations: IP address management (IPAM), documentation, audits
Common mistakes to avoid
1) Confusing subnet mask and wildcard mask
Subnet mask identifies network bits. Wildcard mask is its inverse and is often used in ACL syntax.
2) Forgetting network and broadcast reservations
For most subnets, first and last addresses are not host addresses. Exception: many modern systems allow /31 point-to-point usage.
3) Picking overlapping ranges
Overlapping CIDR blocks create route conflicts and unexpected traffic behavior. Always validate your plan.
Final thoughts
A reliable CIDR calculator is one of the highest-leverage tools for anyone working with IPv4 networking. Use it to move faster, avoid mistakes, and communicate subnet details clearly across engineering teams.