Skip to content

Subnet Calculator

Get the network address, broadcast, host range and masks of any IPv4 CIDR block, and split it into smaller subnets.

Address and prefix

Write it as address/prefix, or pick a subnet mask below.
Shows the first 64 subnets of the new size.
Usable hosts -
Network address
-
Broadcast address
-
First usable host
-
Last usable host
-
Subnet mask
-
Wildcard mask
-
Total addresses
-
Address type
-
Mask in binary
-
Subnets
SubnetUsable rangeBroadcast

How to use it

Type an address with its prefix, such as 192.168.10.37/26, or pick a subnet mask from the list. The calculator shows:

  • the network address (the first address of the block),
  • the broadcast address (the last one),
  • the first and last usable host,
  • the number of usable hosts,
  • the subnet mask and wildcard mask (used in Cisco ACLs and OSPF),
  • whether the address is private, public, loopback or another special range.

The split option breaks the block into smaller subnets and lists the first 64 of them.

How subnetting works, in one example

An IPv4 address has 32 bits. The prefix (/26) says how many of them name the network; the rest name hosts inside it.

For 192.168.10.37/26:

  • 26 bits for the network leaves 6 bits for hosts: 2⁶ = 64 addresses.
  • Blocks of 64 start at .0, .64, .128 and .192. The address .37 sits in the first one.
  • Network address: 192.168.10.0. Broadcast: 192.168.10.63.
  • Usable hosts: 192.168.10.1 to 192.168.10.62, which is 62 hosts: the network and broadcast addresses cannot be given to a device.
  • Subnet mask: 255.255.255.192. Wildcard: 0.0.0.63.

Common prefixes

Prefix Mask Addresses Usable hosts
/8 255.0.0.0 16,777,216 16,777,214
/16 255.255.0.0 65,536 65,534
/20 255.255.240.0 4,096 4,094
/22 255.255.252.0 1,024 1,022
/24 255.255.255.0 256 254
/26 255.255.255.192 64 62
/28 255.255.255.240 16 14
/29 255.255.255.248 8 6
/30 255.255.255.252 4 2
/31 255.255.255.254 2 2 (point-to-point links)
/32 255.255.255.255 1 1 (a single host)

Each step down in prefix doubles the size of the block.

Private ranges

These are reserved for internal networks and never routed on the internet (RFC 1918):

  • 10.0.0.0/8: 10.0.0.0 to 10.255.255.255
  • 172.16.0.0/12: 172.16.0.0 to 172.31.255.255
  • 192.168.0.0/16: 192.168.0.0 to 192.168.255.255

100.64.0.0/10 is used by internet providers for carrier-grade NAT, and 169.254.0.0/16 is what a device gives itself when DHCP fails.

Planning subnets in the cloud

On AWS, Azure and Google Cloud, a VPC is a CIDR block you split into subnets per zone and tier. A common layout is a /16 for the VPC, split into /20 or /24 subnets. Note that AWS reserves 5 addresses in every subnet, not 2, so a /24 gives you 251 usable addresses there. Leave room to grow: it is much easier to start with a larger block than to renumber later.

Frequently asked questions

How many hosts are in a /24 subnet?
256 addresses, of which 254 can be given to devices. The first (.0) is the network address and the last (.255) is the broadcast address.
What is a wildcard mask?
The subnet mask with every bit flipped. For 255.255.255.0 it is 0.0.0.255. Cisco access lists and OSPF use wildcard masks to say which bits must match.
Why does a /31 have 2 usable hosts?
/31 subnets are meant for point-to-point links between two routers (RFC 3021). There is no need for network or broadcast addresses on such a link, so both addresses are usable.
How do I find the network address from an IP and mask?
Do a bitwise AND of the address and the mask. In practice: find the block size (256 minus the last non-255 octet of the mask), and round the address down to the nearest multiple of it. For .37 with a /26 (block of 64), that is .0.
Does this calculator support IPv6?
Not yet; it covers IPv4. IPv6 subnets are almost always /64 for a single network, with larger blocks such as /48 or /56 assigned to sites.

Sources

The rules and figures in this tool come from these official sources, last checked November 12, 2026.

  1. RFC 4632: Classless Inter-domain Routing (CIDR) rfc-editor.org
  2. RFC 1918: address allocation for private internets rfc-editor.org