Azlaan Electric AC Solar Center — Solar, CCTV, AC & electrical work, Faisalabad Call: 0300-8987448

IP Subnet Calculator

Calculate every subnet detail from an IPv4 address and CIDR prefix in one go. Get the network and broadcast addresses, usable host range, wildcard and subnet masks - plus the binary breakdown, all computed instantly.

Enter a valid IPv4 address (four parts, each part 0–255). The result updates live when you change the prefix.

Network Address—
Broadcast Address—
Netmask—
Wildcard Mask—
First Usable Host—
Last Usable Host—
Total Hosts—
Usable Hosts—
IP Class—
Type—

Binary representation

IP Address—
Netmask—

How it works

The CIDR prefix tells how many of the first bits of the IP are the network part; the rest are for hosts. AND-ing the netmask with the IP gives the network address, and adding the wildcard (the mask's inverse) gives the broadcast. Normally usable hosts = total hosts − 2 (network and broadcast are reserved).

Example 1: 192.168.1.10/24 — network 192.168.1.0, broadcast 192.168.1.255, usable hosts 192.168.1.1 – 192.168.1.254, 254 usable in total.

Example 2: a /30 subnet has 4 addresses in total but only 2 usable — that is why /30 is commonly used for router-to-router links. /31 and /32 are special cases: this calculator shows usable hosts as 0 for them (the network/broadcast concept does not apply there / a /32 is a single host route).

How to use

  1. Type your IPv4 address in the address box (four parts, each 0 to 255).
  2. Pick the CIDR prefix / netmask from the dropdown — the result updates live.
  3. Read the network address, broadcast address, usable host range and masks.
  4. Check the binary representation and the worked examples for common cases like /24 and /30.

Tips

  • The usable host count excludes the network and broadcast addresses - a /24 gives 254 usable hosts, not 256.
  • Use the binary view to understand which bits belong to the network versus the host portion.
  • For point-to-point links, a /31 (or /30) is enough; do not waste a whole /24 on two devices.
  • Double-check the CIDR before configuring routers - one wrong digit can take a network offline.