A CIDR (10.20.4.0/22 or 2001:db8::/48), an address and mask (192.168.1.37 255.255.255.0), or a bare address.
Network bits Host bits
- CIDR
- 10.20.4.0/22
- Netmask
- 255.255.252.0
- Wildcard mask
- 0.0.3.255
- Network address
- 10.20.4.0
- Broadcast address
- 10.20.7.255
- First usable host
- 10.20.4.1
- Last usable host
- 10.20.7.254
- Usable host count
- 1022
- Total addresses
- 1024
- Binary netmask
- 11111111.11111111.11111100.00000000
- IP class
- A
- Address type
- Private (RFC 1918)
4 subnets of /24, 254 usable hosts each.
| Subnet | First host | Last host | Broadcast | Usable |
|---|---|---|---|---|
| 10.20.4.1 | 10.20.4.254 | 10.20.4.255 | 254 | |
| 10.20.5.1 | 10.20.5.254 | 10.20.5.255 | 254 | |
| 10.20.6.1 | 10.20.6.254 | 10.20.6.255 | 254 | |
| 10.20.7.1 | 10.20.7.254 | 10.20.7.255 | 254 |
Related tools
- DNS LookupQuery A, AAAA, MX, TXT, and other DNS records over DNS-over-HTTPS through Cloudflare, Google, or dns.sb, no server needed.
- HTTP Header InspectorSee exactly which HTTP request headers your browser sends, with a plain English explanation for User-Agent, Sec-CH-UA, and more.
- WebRTC DebuggerParse ICE candidates from SDP or JSON, classify each address, and interpret STUN and TURN reachability results.
- DMARC Report ViewerDrop a DMARC aggregate report and see who is sending as your domain.
- Browser Privacy CheckSee what your browser leaks: fingerprint surface, exposed APIs, and privacy signal irony, all analyzed on your device.
- DNS PropagationCompare live DNS answers from Cloudflare, Google, and dns.sb side by side.
What it does
Works out everything about an IPv4 or IPv6 network: network and broadcast address, usable host range, host count, netmask, wildcard mask, class, and scope such as private, carrier-grade NAT, link-local, or documentation. A bit view draws the boundary between network and host bits, and a slider moves the prefix length live. It also splits a network into equal subnets, plans variable length subnets (VLSM) from a list of host counts, merges a list of CIDRs into the fewest routes, checks whether an address belongs to a network, and shows the neighboring blocks.
How to use it
Type a CIDR like 192.168.1.0/24 or 2001:db8::/48, an address and mask like 192.168.1.37 255.255.255.0, or a bare address. Drag the prefix slider to resize the network, or enter how many hosts you need and apply the suggested prefix. Then pick a planning tool: split into a number of equal subnets, list host counts one per line for a VLSM plan, paste CIDRs to aggregate, or enter an address to test. Any subnet in a result can be clicked to calculate it, and tables copy or download as CSV.
Why this one
Most online subnet calculators only handle IPv4, bury the answer under ads, or cap how many subnets you can split into. This one covers IPv4 and IPv6 in the same box, shows the bits so the math is visible, plans VLSM and supernets in the same place, works offline, and your files and inputs never leave your device.
FAQ
- Why does a /31 show 2 usable hosts instead of 0?
- RFC 3021 allows /31 networks on point-to-point links to use both addresses as hosts, since there is no room for a separate network and broadcast address. This tool follows that rule, and a /32 is treated as a single host address.
- How does the VLSM planner choose subnet sizes?
- Each line is a host count, optionally after a name. Every subnet gets the smallest block whose usable addresses cover that count, the blocks are placed largest first from the start of the network so they stay aligned with no gaps, and whatever is left over is listed as free CIDR blocks. If the counts do not fit, it says which subnet ran out of room.
- Is there an API, and does anything leave my browser?
- On the page all the address math runs locally in JavaScript, so your files and inputs never leave your device. A GET endpoint at /api/subnet-calculator exists for scripts and curl: it takes the same network text, or two CIDRs separated by a comma to compare them, and a split parameter for equal subnets.
Keyboard shortcuts: press ? anywhere on this page to see them.