Subnet calculator
Calculator
The calculator needs JavaScript. The tables below give the same numbers for common cases.
How it is worked out
- The mask has 26 leading 1 bits: 255.255.255.192.
- Network = address AND mask; broadcast = network OR the wildcard (inverted mask).
- Usable hosts = 2^(32 − 26) − 2 (network and broadcast addresses excluded; /31 and /32 are special cases).
| Inputs | Answer |
|---|---|
| IPv4 address: 192.168.10.37; Prefix length: 26 | 192.168.10.37/26 is in the network 192.168.10.0/26 with 62 usable host addresses. |
| IPv4 address: 10.0.0.1; Prefix length: 8 | 10.0.0.1/8 is in the network 10.0.0.0/8 with 16,777,214 usable host addresses. |
| IPv4 address: 172.16.5.130; Prefix length: 20 | 172.16.5.130/20 is in the network 172.16.0.0/20 with 4,094 usable host addresses. |
How to use it
An IPv4 subnet is defined by an address and a prefix length: /26 means the first 26 bits are the network. The subnet mask has that many leading 1 bits (255.255.255.192 for /26). The network address is the address AND the mask, the broadcast address is the network with all host bits set, and the usable hosts are everything in between: 2^(32 − prefix) − 2.
For 192.168.10.37/26 the network is 192.168.10.0/26, the broadcast address is 192.168.10.63 and there are 62 usable hosts. /31 and /32 are special cases.
Frequently asked questions
How many hosts are in a /24?
254 usable addresses (256 minus the network and broadcast addresses).
What is the subnet mask for /26?
255.255.255.192.
What is CIDR notation?
Writing an address with its prefix length, such as 192.168.10.0/26.
Method: standard arithmetic shown step by step; no outside data is used. Checked 2026-11-12.
About · How we verify this · Editorial policy · Corrections
General information only. Results are plain arithmetic on the numbers you enter; check anything important (money, health, school work) against your own records or the official source.