Subnet Calculator

IPv4 CIDR, host range and masks

IP Address
You can also paste 192.168.0.10/24
Network
192.168.0.0/24
Usable hosts 254
Network address192.168.0.0
Broadcast address192.168.0.255
Usable host range192.168.0.1 ~ 192.168.0.254
Subnet mask255.255.255.0
Wildcard mask0.0.0.255
Class · typeC
IP (binary)
Mask (binary)
CIDR Subnet Chart (/16 to /32)
CIDRSubnet maskAddressesUsable hosts
/16255.255.0.065,53665,534
/17255.255.128.032,76832,766
/18255.255.192.016,38416,382
/19255.255.224.08,1928,190
/20255.255.240.04,0964,094
/21255.255.248.02,0482,046
/22255.255.252.01,0241,022
/23255.255.254.0512510
/24255.255.255.0256254
/25255.255.255.128128126
/26255.255.255.1926462
/27255.255.255.2243230
/28255.255.255.2401614
/29255.255.255.24886
/30255.255.255.25242
/31255.255.255.25422
/32255.255.255.25511

Usable hosts exclude the network and broadcast addresses. A /31 uses both addresses for point-to-point links (RFC 3021); a /32 is a single host.

Private & Special Ranges
RangeUse
10.0.0.0/8Private (large networks)
172.16.0.0/12Private
192.168.0.0/16Private (home and office routers)
100.64.0.0/10Carrier-grade NAT
127.0.0.0/8Loopback
169.254.0.0/16Link-local (no DHCP)
Formulas & Sources
🌐 RFC 1918 — Address Allocation for Private Internets
Last reviewed: 2026-10-19
FAQ
How many hosts are in a /24?
A /24 (255.255.255.0) has 256 addresses, of which 254 are usable after removing the network and broadcast addresses.
How do I get the subnet mask from CIDR?
Set that many leading bits to 1. /26 means 26 ones: 255.255.255.192.
What are the network and broadcast addresses?
AND the IP with the mask to get the network address; set all host bits to 1 for the broadcast address. Neither can be assigned to a device.
Which IP ranges are private?
10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 (RFC 1918). 100.64.0.0/10 is carrier-grade NAT.
What is a wildcard mask?
The inverse of the subnet mask, used in router ACLs and OSPF to match address ranges.

How subnetting works

A subnet splits an IPv4 address into a network part and a host part. The CIDR prefix (/24, /26 …) is the number of network bits; the remaining bits set how many hosts fit.

Enter an IP and prefix to get the network and broadcast addresses, usable range and host count, subnet and wildcard masks and the binary form — for router setup, firewalls and network exams.

Share