Subnet Calculator
Calculate network, broadcast, host range, and wildcard mask for any IPv4 or IPv6 CIDR. Runs entirely in your browser — nothing is sent to a server.
| Network | 192.168.1.0/24 |
| Prefix length | /24 |
| Subnet mask | 255.255.255.0 |
| Wildcard mask | 0.0.0.255 |
| Broadcast | 192.168.1.255 |
| First host | 192.168.1.1 |
| Last host | 192.168.1.254 |
| Total addresses | 256 |
| Usable host IPs | 254 |
| Scope | Private |
Note: For /31 and /32 IPv4 blocks, host range and broadcast concepts don't apply traditionally — RFC 3021 defines /31 as point-to-point with both addresses usable.
IPv4 subnet reference
Below is a table providing typical subnets for IPv4.
| Prefix size | Network mask | Usable hosts per subnet |
|---|---|---|
| /1 | 128.0.0.0 | 2.1B |
| /2 | 192.0.0.0 | 1.1B |
| /3 | 224.0.0.0 | 537M |
| /4 | 240.0.0.0 | 268M |
| /5 | 248.0.0.0 | 134M |
| /6 | 252.0.0.0 | 67.1M |
| /7 | 254.0.0.0 | 33.6M |
| Class A | ||
| /8 | 255.0.0.0 | 16.8M |
| /9 | 255.128.0.0 | 8.4M |
| /10 | 255.192.0.0 | 4.2M |
| /11 | 255.224.0.0 | 2.1M |
| /12 | 255.240.0.0 | 1.0M |
| /13 | 255.248.0.0 | 524K |
| /14 | 255.252.0.0 | 262K |
| /15 | 255.254.0.0 | 131K |
| Class B | ||
| /16 | 255.255.0.0 | 65.5K |
| /17 | 255.255.128.0 | 32.8K |
| /18 | 255.255.192.0 | 16.4K |
| /19 | 255.255.224.0 | 8.2K |
| /20 | 255.255.240.0 | 4.1K |
| /21 | 255.255.248.0 | 2.0K |
| /22 | 255.255.252.0 | 1.0K |
| /23 | 255.255.254.0 | 510 |
| Class C | ||
| /24 | 255.255.255.0 | 254 |
| /25 | 255.255.255.128 | 126 |
| /26 | 255.255.255.192 | 62 |
| /27 | 255.255.255.224 | 30 |
| /28 | 255.255.255.240 | 14 |
| /29 | 255.255.255.248 | 6 |
| /30 | 255.255.255.252 | 2 |
| /31 | 255.255.255.254 | 2 (point-to-point) |
| /32 | 255.255.255.255 | 1 |
Related reading
- Subnet calculator cheatsheet: CIDR, masks, and host countsA quick-reference for IPv4 subnet math — how to read a CIDR, what the mask actually means, and the easy way to count usable hosts.
- What is my IP address, and why does it matter?Your public IP is the address the rest of the internet uses to talk to you. Here's what it reveals, what it doesn't, and how to check it.
- How to read an open port (and when to actually worry)An 'open port' isn't a vulnerability by itself — it's information. Here's how to tell whether a port being open is fine, suspicious, or actively dangerous, and what to do about each case.