Calculat.dev LogoCalculat.dev - All Calculators, One Place.devAll Calculators, One Place.
Technology CalculatorsPopular Tool Runs Locally

IP Subnet Calculator

Calculate IPv4 CIDR subnets (/0 to /32). Computes network address, broadcast address, first and last usable host IPs, wildcard mask, and binary subnet masks.

Network Address
192.168.1.0
/24
Broadcast Address
192.168.1.255
all 1s host
Usable Hosts
254
256 total
Scope & Class
Class C
Private (RFC 1918)
Usable Host Range: 192.168.1.1192.168.1.254
Subnet Mask: 255.255.255.0 (Wildcard: 0.0.0.255)
Binary Mask: 11111111.11111111.11111111.00000000
🎓

Did this calculation save you time?

Student Project

Hi! I'm a student developer building Calculat in my spare time. I was tired of searching for basic math tools and having to click through 10 spammy popups, loan ads, and cookie trackers.

I keep this website 100% free, private, and ad-free. If this helped you with your homework, project, or finances today, bookmarking this page or telling a friend helps me keep building more free tools!

Press ⌘ + D to Bookmark
Suggest What I Build Next

What Is a IP Subnet Calculator?

The IP Subnet Calculator performs IPv4 subnetting calculations based on Classless Inter-Domain Routing (CIDR). It calculates the network ID, broadcast address, usable host IP range, wildcard mask, and total usable host capacity for network engineers and system administrators.

How to Use This Calculator

  1. Enter an IPv4 address (e.g., 192.168.1.100 or 10.0.0.1).
  2. Select the CIDR prefix length (e.g., /24 for 255.255.255.0 or /16 for 255.255.0.0).
  3. Review the network address, broadcast address, first/last usable IP addresses, wildcard mask, and binary representation.

Usable Hosts & Network Bitwise Logic

N_{\text{hosts}} = 2^{32 - \text{prefix}} - 2, \quad \text{Network} = \text{IP} \ \& \ \text{Mask}, \quad \text{Broadcast} = \text{Network} \ | \ \sim\text{Mask}

In standard subnets (prefix ≤ 30), two addresses are reserved: all 0s for the network ID and all 1s for the broadcast address.

Worked Example

Scenario: Subnetting 192.168.1.100 with a /24 CIDR prefix (255.255.255.0)

CIDR prefix: /24 (32 - 24 = 8 host bits).

Total IP addresses: 2⁸ = 256.

Usable hosts: 256 - 2 = 254 hosts.

Network address: 192.168.1.0; Broadcast: 192.168.1.255.

Usable host range: 192.168.1.1 through 192.168.1.254.

Result: 254 usable host addresses on subnet 192.168.1.0/24.

Tips & Key Notes

  • /24 subnets (254 usable hosts) are the universal standard for home and office LAN segments.
  • For point-to-point router links, /30 (2 hosts) or /31 (2 hosts under RFC 3021) saves valuable IPv4 address space.
  • Wildcard masks are calculated by inverting the subnet mask (255.255.255.255 - Mask) and are used extensively in Cisco ACLs and OSPF.

Frequently Asked Questions

What is CIDR notation?

Classless Inter-Domain Routing (CIDR) represents an IP address and its associated subnet mask using a slash followed by the count of leading 1s in the mask (e.g., /24 means 24 mask bits or 255.255.255.0).

Why are 2 addresses subtracted from the host capacity?

The first address (where all host bits are 0) identifies the network itself. The last address (where all host bits are 1) is reserved as the local broadcast address.

What are RFC 1918 Private IP ranges?

Private IP addresses reserved for home and enterprise local networks: Class A: 10.0.0.0/8; Class B: 172.16.0.0/12; Class C: 192.168.0.0/16.

What is a /31 subnet used for?

Under RFC 3021, /31 subnets (with only 2 addresses total) are used for point-to-point router links without reserving network or broadcast addresses, conserving IPv4 space.

Related Calculators

Explore similar tools