Developer Tools

IP Subnet Calculator

Work out an IPv4 subnet’s network, broadcast, host range and mask, and split it into smaller subnets.

By Nitin Raturi · Last reviewed

Input

How to use the IP Subnet Calculator

Work out the network, broadcast and host range of an IPv4 subnet.

  1. Type an address with /prefix or a mask.
  2. Read the network, broadcast, usable range and mask.
  3. Check what kind of address it is.
  4. Optionally split the network into smaller subnets.

Good to know

  • Tap the ⓘ next to any field for a short guide to it.

IPv4 CIDR arithmetic, with special-purpose ranges labelled from the IANA registry.

Runs in your browser. Nothing you type is uploaded or saved in the link.

Address and prefix

An IPv4 address with its prefix length (CIDR) or subnet mask.

How to fill it in

  • Type 192.168.1.10/24, or 192.168.1.10 255.255.255.0.
  • An address without a prefix is treated as a single host (/32).

Example

192.168.1.10/24 is in network 192.168.1.0 with 254 usable host addresses.

Split into

Divide the network into equal smaller subnets with a longer prefix.

How to fill it in

  • Choose a prefix longer than the current one. Up to 256 subnets are listed.

Example

Splitting 192.168.1.0/24 into /26 gives 4 subnets: 192.168.1.0, 192.168.1.64, 192.168.1.128, 192.168.1.192.

Result

192.168.1.0/24

Usable hosts
254
Host range
192.168.1.1 – 192.168.1.254
Broadcast
192.168.1.255
Subnet mask
255.255.255.0
Wildcard mask
0.0.0.255
Total addresses
256
Address type
Private (RFC 1918)
Mask in binary
11111111.11111111.11111111.00000000

How this calculator works

  1. Step 1Read the prefix/24The first bits name the network; the rest name hosts.
  2. Step 2Keep the network bits192.168.1.0All host bits set to 0.
  3. Step 3Fill the host bits192.168.1.255All host bits set to 1: the broadcast address.

An IPv4 address is 32 bits. The prefix says how many of them, from the left, identify the network. The remaining bits number the hosts inside it.

Worked example: a home network

192.168.1.10/24 sits in 192.168.1.0/24, which has 254 usable addresses.

Working out 192.168.1.10/24
Network
address AND mask
Broadcast
network OR wildcard
  1. Address in binary11000000.10101000.00000001.00001010
  2. Mask in binary11111111.11111111.11111111.00000000
  3. Network192.168.1.0
  4. Broadcast192.168.1.255
  5. Usable hosts: 2^8 − 2254

Reading the result

  • /30 and shorterTotal − 2 hostsThe first address is the network and the last is broadcast.
  • /31 links2 hostsPoint-to-point links use both addresses (RFC 3021).
  • Private10/8, 172.16/12 and 192.168/16, for internal networks.
  • Carrier-grade NAT100.64/10, used by ISPs that share one public address among customers.
  • DocumentationRanges reserved for examples, never on the internet.
  • Loopback and multicast127/8 and 224/4 are special.

Subnetting is binary arithmetic on addresses. Other tools help with the numbers and the network around it.

To check masks and addresses bit by bit, use the binary calculator or the hex calculator. For transfer times over a link, the bandwidth calculator handles GB vs GiB and Mbps vs MB/s.

Common mistakes

  • Mistake: Giving a host the network or broadcast address.

    Instead: Use only the host range shown.

  • Mistake: Using a mask such as 255.0.255.0.

    Instead: Masks must be ones followed by zeros.

  • Mistake: Treating a 100.64.x.x address as public.

    Instead: It is shared carrier space; you are behind your ISP’s NAT.

Read how we test our calculators, or browse more developer tools.

Frequently asked questions

How many hosts does a /24 have?

256 addresses, of which 254 can be given to hosts. The first is the network address and the last is broadcast.

Why does /31 show 2 usable hosts?

On point-to-point links both addresses can be used, as RFC 3021 allows, because no broadcast address is needed.

What is 100.64.0.0/10?

Shared address space for carrier-grade NAT. If your router shows such an address, your ISP is sharing a public address among many customers.

Does it support IPv6?

Not yet. It covers IPv4 only.

Is the address I type stored?

No. It stays in your browser and is not saved in the link.

Sources and methodology

The formulas are standard time-value-of-money results. We check every figure against golden values worked out independently, by closed form and by month-by-month simulation; see the methodology.

Written and maintained by Nitin Raturi, a software engineer (about the author). Last reviewed 27 Oct 2026; next review due by . Found an error? Tell us.

Changelog

  • : Initial release. Demand metrics remain unverified.