Networking Fundamentals

Subnet Calculator — Network, Broadcast, Host Range and Mask

G Gurpreet Singh July 28, 2026 4 min read
IPv4 address shown in binary with the 24 network bits highlighted and the 8 host bits dimmed
1 Enter the network


Any address inside the subnet works


/24

0 to 32

2 Calculate


Subnet details
Network address
Subnet mask
Broadcast address
Usable hosts
Usable host range
Wildcard mask
Binary subnet mask
Address type

How to Use This Subnet Calculator

Enter your IP address in the first field (for example 192.168.1.0), set the CIDR prefix length using the number box or the slider (for example /24), then press Calculate. Results update instantly, and pressing Enter in the IP field works too.

The calculator validates the address strictly, an octet above 255 is rejected rather than silently wrapped, so you always know when your input is wrong.

Common Subnet Reference Table

Quick reference for the most commonly used CIDR prefixes in networking:

CIDRSubnet MaskUsable HostsCommon Use
/8255.0.0.016,777,214Large ISP, Class A networks
/16255.255.0.065,534Large enterprise networks
/24255.255.255.0254Most common, home & office LAN
/25255.255.255.128126Medium-sized LAN segment
/26255.255.255.19262Small office segment
/27255.255.255.22430Small department/VLAN
/28255.255.255.24014Small branch office
/29255.255.255.2486Point-to-point WAN link
/30255.255.255.2522Router-to-router link
/31255.255.255.2542Point-to-point (RFC 3021)
/32255.255.255.2551Host route / loopback

Worked Example: Subnetting 192.168.10.0/24 into /27s

Suppose you have 192.168.10.0/24 and need separate segments for five departments of about 25 devices each. A /27 gives 30 usable hosts, which fits.

A /27 block is 32 addresses, so each subnet starts 32 addresses after the previous one:

SubnetNetworkFirst hostLast hostBroadcast
1192.168.10.0/27192.168.10.1192.168.10.30192.168.10.31
2192.168.10.32/27192.168.10.33192.168.10.62192.168.10.63
3192.168.10.64/27192.168.10.65192.168.10.94192.168.10.95
4192.168.10.96/27192.168.10.97192.168.10.126192.168.10.127
5192.168.10.128/27192.168.10.129192.168.10.158192.168.10.159

The /24 had 256 addresses, so it splits into eight /27 blocks. Using five leaves three spare for future growth. Plan the whole layout with our VLAN calculator if each department also needs its own VLAN.

What is Subnetting?

Subnetting is the process of dividing a large IP network into smaller, more manageable sub-networks. It improves network performance by shrinking broadcast domains, enhances security by isolating segments, and makes IP address management far more efficient. It is a core skill tested in the CCNA, Network+, and other networking certifications.

Understanding CIDR Notation

CIDR (Classless Inter-Domain Routing) notation represents an IP address together with its network prefix length. In 192.168.1.0/24, the first 24 bits are the network portion, leaving 8 bits for hosts, which gives 254 usable addresses. The higher the CIDR number, the smaller the subnet.

Key Subnet Terms Explained

  • Network Address: The first address in a subnet, identifies the subnet itself. Cannot be assigned to a host.
  • Subnet Mask: A 32-bit number that separates the network and host portions of an IP address.
  • Broadcast Address: The last address in a subnet, used to send data to all hosts in that subnet. Cannot be assigned to a host.
  • Usable Hosts: Total addresses minus 2 (network + broadcast). These are the addresses you can assign to devices.
  • Wildcard Mask: The exact inverse of the subnet mask, used in Cisco ACLs and OSPF network statements.
  • Prefix Length: The number after the slash, how many leading bits belong to the network.

Frequently Asked Questions

What is a /24 subnet?

A /24 subnet has a subnet mask of 255.255.255.0 and provides 254 usable host addresses. It is the most common subnet size in home and small office networks. If you are working in IPv6 instead, host counting stops mattering entirely, and our IPv6 subnet calculator explains why.

How many hosts can a /24 subnet support?

254 usable hosts, 256 total addresses minus the network address and the broadcast address.

What is the difference between a subnet mask and a wildcard mask?

A subnet mask uses 1s for the network portion and 0s for the host portion. A wildcard mask is the exact inverse, 0s for the network portion and 1s for the host portion. Wildcard masks appear in Cisco router ACLs and OSPF area definitions.

Can I subnet a /32 address?

No. A /32 is a host route representing a single IP address with no room to subdivide. It is used for loopback interfaces and specific host routes in routing tables.

Why does /31 show two usable hosts instead of zero?

Normally a subnet loses its first and last address to the network and broadcast addresses, which would leave a /31 with nothing. RFC 3021 makes an exception for point-to-point links, where both addresses in a /31 are usable. That is why this calculator reports 2 hosts and no broadcast address for a /31.

How do I calculate the number of subnets I can create?

Subtract the original prefix from the new prefix and raise 2 to that power. Splitting a /24 into /27s is 27 minus 24 = 3, so 2³ = 8 subnets. Splitting a /16 into /24s is 24 minus 16 = 8, so 256 subnets.

What is the difference between a public and a private IP address?

Private ranges, 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 (RFC 1918), are reserved for internal networks and are not routed on the public internet. This calculator labels them for you in the Address Type box. Everything else is public and globally routable.

Related Tools and Guides

Plan a full multi-VLAN network with our VLAN calculator, convert addresses bit by bit with the IP to binary converter, or read the fundamentals in What is an IPv4 address and VLAN vs Subnet. See all our free networking tools.

GU
Written by

Gurpreet Singh

Hey! I"m Gurpreet Singh and I Have 7+ Years of experience in the Network & Security Domain as well as the Cloud Infra Domain. I am Certified with Cisco ( CCNA ), CheckPoint ( CCSA ), 1xAWS, 3xAZURE, and 3xNSE. So I love to share my tech knowledge with you.

Leave a Reply

Your email address will not be published. Required fields are marked *