IPv4 CIDR Subnet Calculator

Calculate usable IP ranges, broadcast addresses, wildcard masks, and binary bit allocations with instant client-side computation.

100% Client-Side RFC 4632 Compliant Real-Time Binary Visualizer
CIDR Notation 192.168.1.100/24
Subnet Mask (Netmask) 255.255.255.0
Wildcard Mask 0.0.0.255
Network Address (ID) 192.168.1.0
Broadcast Address 192.168.1.255
Usable Host IP Range 192.168.1.1 - 192.168.1.254
Total IP Addresses 256
Usable Host Count 254
IPv4 Class & Scope Class C Private (RFC 1918)
32-Bit Binary Allocation (Network vs Host Bits)
IP Address: 11000000.10101000.00000001.01100100
Subnet Mask: 11111111.11111111.11111111.00000000
Network ID: 11000000.10101000.00000001.00000000

Understanding IPv4 Subnetting and Classless Inter-Domain Routing (CIDR)

In computer networking, an Internet Protocol Version 4 (IPv4) address consists of a 32-bit numeric value partitioned into four 8-bit octets separated by dots (dotted-decimal notation). Originally defined under RFC 791, IPv4 partitioned addresses into strict classes (Class A, B, and C). However, exponential internet growth in the early 1990s quickly depleted Class B blocks, prompting the Internet Engineering Task Force (IETF) to introduce Classless Inter-Domain Routing (CIDR) under RFC 1519 and RFC 4632.

1. Anatomy of the Subnet Mask and Host Formula

A subnet mask demarcates where the network portion of an address ends and the host portion begins. In CIDR notation, the suffix (e.g. /24) denotes the count of contiguous 1-bits from left to right. The formula to calculate usable hosts in standard subnets is:

Usable Hosts = 2^(32 - Prefix) - 2

Two addresses are subtracted because:

2. Common CIDR Subnet Cheat Sheet

CIDR Prefix Subnet Mask Wildcard Mask Total Addresses Usable Hosts Typical Application
/30 255.255.255.252 0.0.0.3 4 2 Point-to-point router links
/28 255.255.255.240 0.0.0.15 16 14 Small server rack / DMZ subnet
/24 255.255.255.0 0.0.0.255 256 254 Standard office LAN / Wi-Fi subnet
/16 255.255.0.0 0.0.255.255 65,536 65,534 Corporate campus / AWS VPC default

3. Related Developer & Infrastructure Tools

Frequently Asked Questions

Classless Inter-Domain Routing (CIDR) notation expresses an IP address and its associated routing prefix using a slash followed by the number of leading binary 1-bits in the subnet mask (e.g., 192.168.1.0/24).

In standard IPv4 subnets (/30 and larger), the first address is reserved as the Network Identifier (representing the wire), and the final address is reserved as the Directed Broadcast Address (delivering packets to all hosts on the subnet). The usable host count is calculated as 2^(32 - prefix) - 2.

RFC 1918 reserves three address blocks for private internal networks: 10.0.0.0/8 (10.0.0.0 - 10.255.255.255), 172.16.0.0/12 (172.16.0.0 - 172.31.255.255), and 192.168.0.0/16 (192.168.0.0 - 192.168.255.255).