Stax

IP Subnet Calculator

Calculate IPv4 subnet details from CIDR notation.

Enter IP and prefix length, e.g. 10.0.0.1/16

Network Address192.168.1.0
Broadcast Address192.168.1.255
First Usable Host192.168.1.1
Last Usable Host192.168.1.254
Subnet Mask255.255.255.0
Wildcard Mask0.0.0.255
Binary Mask11111111.11111111.11111111.00000000
Total Hosts256
Usable Hosts254
IP ClassC
ScopePrivate (RFC 1918)
Common subnet sizes
CIDRSubnet MaskUsable HostsUse case
/24255.255.255.0254Small LAN (254 hosts)
/23255.255.254.0510Medium LAN (510 hosts)
/22255.255.252.01,022Office network (1022 hosts)
/16255.255.0.065,534Large network (65534 hosts)
/28255.255.255.24014Small segment (14 hosts)
/30255.255.255.2522Point-to-point link (2 hosts)

Click a row to load that prefix into the calculator.

IPv4 subnet calculator for network engineers

Enter any IPv4 address in CIDR notation (e.g., 10.0.0.0/16) to instantly calculate the network address, broadcast address, usable host range, subnet mask, wildcard mask, total hosts, IP class, and whether the address is private or public.

Common subnet sizes reference

The reference table below lists the most commonly used CIDR prefixes with their subnet masks and usable host counts. Click any row to load it into the calculator.

Frequently asked questions

What is CIDR notation?
CIDR (Classless Inter-Domain Routing) notation expresses an IP address and its subnet mask together, e.g. 192.168.1.0/24. The number after the slash indicates how many bits are in the network prefix.
What is the difference between network address and broadcast address?
The network address is the first address in a subnet (all host bits = 0). The broadcast address is the last address (all host bits = 1). Neither can be assigned to a host.
How are usable hosts calculated?
Usable hosts = 2^(32−prefix) − 2. We subtract 2 for the network and broadcast addresses. A /30 has 4 total addresses and 2 usable hosts. /31 and /32 are treated specially for point-to-point and loopback.
What is a wildcard mask?
A wildcard mask is the inverse of the subnet mask. It is used in ACL rules and OSPF configuration to specify which bits to ignore. E.g., subnet mask 255.255.255.0 has wildcard 0.0.0.255.
Which are private IP ranges?
RFC 1918 defines three private ranges: 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16. Addresses in these ranges are not routable on the public internet. 127.0.0.0/8 is reserved for loopback.

Related tools