๐ IP Subnet Calculator
Calculate subnet masks, IP ranges, and host counts from any CIDR block.
Our free IP Subnet Calculator computes the network address, broadcast address, subnet mask, first and last usable host IP, and total host count for any IPv4 CIDR block. Essential for network planning, cloud security group configuration, and firewall rule management.
Understanding CIDR Notation
CIDR (Classless Inter-Domain Routing) expresses a network as an IP address followed by a prefix length: 192.168.1.0/24. The prefix length (/24) indicates how many bits are the network portion โ the remaining bits identify individual hosts.
/26 โ 26 network bits, 6 host bits โ 2โถ = 64 total addresses โ 62 usable hosts
Two addresses in every subnet are always reserved: the network address (all host bits = 0) and the broadcast address (all host bits = 1).
Common CIDR Subnets Quick Reference
- /32: 1 address โ single host route
- /30: 4 addresses, 2 usable โ point-to-point links
- /29: 8 addresses, 6 usable โ very small segments
- /28: 16 addresses, 14 usable โ small VLANs
- /27: 32 addresses, 30 usable
- /26: 64 addresses, 62 usable
- /25: 128 addresses, 126 usable
- /24: 256 addresses, 254 usable โ standard office subnet
- /23: 512 addresses, 510 usable
- /22: 1,024 addresses, 1,022 usable
- /16: 65,536 addresses, 65,534 usable
Private IP Address Ranges
These ranges are reserved for private networks and are never routed on the public internet:
- 10.0.0.0/8 โ 10.x.x.x โ 16.7 million addresses (Class A private)
- 172.16.0.0/12 โ 172.16.x.x through 172.31.x.x โ 1 million addresses (Class B private)
- 192.168.0.0/16 โ 192.168.x.x โ 65,536 addresses (Class C private, most home networks)
Subnet Calculation Step by Step
For 10.0.1.0/26:
- Host bits: 32 โ 26 = 6 | Block size: 2โถ = 64
- Network address: 10.0.1.0
- Broadcast address: 10.0.1.0 + 64 โ 1 = 10.0.1.63
- First usable host: 10.0.1.1 | Last usable host: 10.0.1.62
- Usable hosts: 64 โ 2 = 62
🌐 Calculate any subnet instantly with our free IP Subnet Calculator.
Open Subnet Calculator →Frequently Asked Questions
What does /24 mean in an IP address?
/24 is a CIDR prefix length indicating that 24 of the 32 bits in the IP address are the network portion. A /24 subnet contains 256 IP addresses (254 usable for hosts, plus network and broadcast addresses). The equivalent subnet mask is 255.255.255.0.
What is 0.0.0.0/0 in a firewall rule?
0.0.0.0/0 represents all possible IPv4 addresses โ essentially "the entire internet." A firewall rule with source 0.0.0.0/0 allows connections from any IP address. Only use this for ports like 80 (HTTP) and 443 (HTTPS) that should be publicly accessible. Never open database ports (3306, 5432, 27017) to 0.0.0.0/0.
What is 169.254.x.x?
The 169.254.0.0/16 range is the APIPA (Automatic Private IP Addressing) range. A device assigns itself an address in this range when it cannot get a DHCP lease. If you see a 169.254.x.x address, it means your device couldn't reach a DHCP server โ check your network connection and DHCP settings.