Subnet Calculator

IPv4 CIDR network, broadcast, mask, wildcard and usable host range — /31 and /32 included.

Calculate IPv4 Subnets and CIDR Ranges

Subnetting is bitwise arithmetic on a 32-bit number, and doing it in your head is entirely possible and entirely error-prone. A /26 gives 62 usable hosts, not 64, because the network and broadcast addresses are reserved — the kind of detail that produces an IP conflict weeks later.

This calculator takes an address with either a CIDR prefix or a dotted-decimal mask and returns everything: network, broadcast, first and last usable host, total and usable counts, wildcard mask and the binary breakdown.

Key features

  • CIDR or dotted mask — enter /24 or 255.255.255.0, whichever you have.
  • Complete range output — network, broadcast, first and last usable host addresses.
  • Wildcard mask — the inverted mask that Cisco ACLs and OSPF require.
  • Binary breakdown — the address and mask in binary, which is where subnetting finally makes sense.
  • Class and scope noted — whether the range is private, loopback, link-local or public.
100% client-side — no data leaves your machine

This tool runs entirely inside your browser using native Web APIs. Your files and text are never uploaded to a server, never logged and never shared with third parties.

How to use: Subnet Calculator

  1. Enter an IP address
    Any address inside the subnet you are interested in — it need not be the network address.
  2. Set the prefix or mask
    A CIDR prefix from /0 to /32, or the equivalent dotted-decimal mask.
  3. Read the results
    Network, broadcast, usable range and host counts all appear together.
  4. Check the binary
    The bit-level view shows exactly where the network and host portions divide.

Technical specifications

Processing locationEntirely in your browser — no server round trip
Data uploadedNone. Files and text never leave your device
PriceFree — no account, no trial, no usage cap
CategoryDeveloper
Works offlineYes, once the page has loaded
Browser supportChrome 90+, Edge 90+, Firefox 90+, Safari 15+
Interface languagesEnglish, 中文, हिन्दी, Español, العربية

Frequently asked questions

Why does a /24 have 254 usable hosts and not 256?

The first address in any subnet is the network identifier and the last is the broadcast address. Neither can be assigned to a host, so 256 total addresses give 254 usable.

What is a /31 for?

Point-to-point links. RFC 3021 allows both addresses in a /31 to be used because a two-node link has no need for a broadcast address. It saves two addresses per link, which adds up across a large network.

What is a wildcard mask?

The bitwise inverse of a subnet mask — /24 gives 0.0.0.255. Cisco access control lists and OSPF configuration use it instead of the subnet mask, and mixing the two up is a classic configuration error.

Which ranges are private?

10.0.0.0/8, 172.16.0.0/12 and 192.168.0.0/16 under RFC 1918, plus 169.254.0.0/16 for link-local and 127.0.0.0/8 for loopback. The tool flags these when your address falls in one.

Related tools

Back to all tools