webtrajans
en

Subnet Calculator (IPv4 CIDR)

Type an IP address with a prefix or subnet mask and see the network, broadcast address, host range and how to split it into smaller subnets.

Network address
Broadcast address
Usable hosts
Host range
Binary view

Network bits are bold, host bits are dimmed.

Split into subnets

subnets

#NetworkHost rangeBroadcast

IPv4 only. Everything is calculated in your browser.

Standards and sources

This tool runs entirely in your browser; your data is never sent to a server.

Written and reviewed by the Webin Agency Editorial Team · Last updated: December 1, 2026How we build our tools

How to use

  1. 1Enter an IPv4 address with a prefix, such as 192.168.1.10/24, or with a mask, such as 192.168.1.10 255.255.255.0.
  2. 2Or choose the prefix from the list; every prefix from /0 to /32 is shown with its dotted mask.
  3. 3Read the network and broadcast address, first and last host, usable host count, wildcard mask and address type.
  4. 4Open the binary view to see network and host bits, or pick a longer prefix to list the resulting subnets.

How subnetting works

An IPv4 address has 32 bits. The prefix length in CIDR notation (RFC 4632) says how many leading bits belong to the network; the rest identify hosts. The subnet mask is the same information in dotted form: /24 is 255.255.255.0. The network address has all host bits set to 0 and the broadcast address has them all set to 1 (RFC 950), so a /24 has 256 addresses and 254 usable hosts. In general, usable hosts = 2^(32 − prefix) − 2.

/31 and /32 are special

RFC 3021 allows /31 prefixes on point-to-point links: the two addresses are both usable and there is no network or broadcast address, which saves address space between routers. A /32 is a single host, often used for loopback interfaces, firewall rules and host routes. The calculator shows 2 and 1 usable hosts for these cases instead of the usual formula.

Private, CGNAT and other special ranges

The tool tells you which kind of address you entered. RFC 1918 reserves 10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 for private networks; RFC 6598 reserves 100.64.0.0/10 for carrier-grade NAT; and RFC 6890 lists other special blocks such as loopback (127.0.0.0/8), link-local (169.254.0.0/16) and multicast (224.0.0.0/4). The historical A–E class is shown for reference only, since routing has been classless since CIDR.

Splitting a network into subnets

Choosing a longer prefix divides the network into 2^(new − old) equal subnets. Splitting 192.168.1.0/24 into /26 gives four subnets of 64 addresses (62 hosts each): .0, .64, .128 and .192. The table lists each subnet with its host range and broadcast address, up to the first 256 rows. The wildcard mask (the inverted subnet mask) is what Cisco ACLs and OSPF network statements expect.

Frequently asked questions

How many hosts are in a /24?

256 addresses, of which 254 are usable hosts: the first is the network address and the last is the broadcast address.

What is the subnet mask for /26?

255.255.255.192. It gives 64 addresses per subnet and 62 usable hosts.

Can I use a /31 subnet?

Yes, on point-to-point links. RFC 3021 defines /31 with two usable addresses and no network or broadcast address.

What is a wildcard mask?

The bitwise inverse of the subnet mask, for example 0.0.0.255 for /24. Router access lists and OSPF use it to match address ranges.

Does it support IPv6?

No, this calculator is for IPv4 only.

Add this tool to your website

Paste the code below into your site’s HTML; the tool runs on your page and stays up to date automatically.

Widget builder →Free to use. Please keep the source link below the widget.

Not happy with the results?

Talk to Webin Agency about fast, SEO-friendly websites, e-commerce and Google Ads management.

Get free advice

Related tools