🌐 Network & Internet Calculators β€Ί IP Addressing

IP Subnet & CIDR Calculator

Convert CIDR prefixes to subnet masks, find network address, broadcast address, first/last host, and total usable IPs for IPv4 and IPv6 ranges.

IP Subnet Calculator β€” interactive calculator, computed instantly in your browser.

πŸ“š Authoritative Educational Guide

IP Subnetting Guide: CIDR, Subnet Masks, and Address Planning

IP subnetting divides a single IPv4 block into smaller isolated networks so each VLAN, office floor, or cloud VPC gets its own broadcast domain. Every subnet decision comes down to one number: the CIDR prefix (e.g. /24), which sets how many leading bits identify the network and how many trailing bits identify hosts.

1. The Four Core Calculations

mask = 2^32 βˆ’ 2^(32βˆ’prefix) Β· network = IP AND mask Β· broadcast = network OR (NOT mask)
  • Subnet mask: /24 β†’ 255.255.255.0 (24 ones, 8 zeros)
  • Network address: bitwise AND of the IP and mask strips the host bits
  • Broadcast address: OR with the wildcard flips all host bits to 1
  • Usable hosts: 2^(32βˆ’prefix) βˆ’ 2 (reserving network and broadcast)

2. Worked Example: 192.168.1.10/24

  1. Mask: /24 β†’ 255.255.255.0, wildcard 0.0.0.255
  2. Network: 192.168.1.10 AND 255.255.255.0 = 192.168.1.0
  3. Broadcast: 192.168.1.0 OR 0.0.0.255 = 192.168.1.255
  4. Hosts: 2^8 βˆ’ 2 = 254 usable (192.168.1.1 β†’ 192.168.1.254)

3. Private Ranges & Prefix Selection

RFC 1918 reserves 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16 for internal use β€” never routable on the public internet. Choose /30 for point-to-point links (2 hosts), /29 for 6-host segments, /24 for typical LANs, and /16 for larger sites. For IPv6, /64 is the mandatory standard for any end-host LAN because it enables SLAAC stateless autoconfiguration.

πŸ”— Network Addressing Cross-References

Subnetting splits a single IPv4 block into smaller networks so VLANs and office segments stay isolated and routable. Explore our 🌐 Tech & Network Hub for more networking utilities.

Plan bandwidth once addressing is settled β€” estimate monthly streaming consumption or test live throughput with the tools below.

Frequently Asked Questions (IP Subnet Calculator)

What is the difference between a subnet mask and a CIDR prefix?

They express the same thing in different notations. CIDR /24 means 24 leading network bits, which equals the dotted subnet mask 255.255.255.0. Engineers prefer /prefix for brevity; routers and OS tools accept both.

Why are two addresses always unusable in an IPv4 subnet?

The lowest address is the network identifier (all host bits 0) and the highest is the broadcast address (all host bits 1) β€” neither can be assigned to a host. Exceptions are /31 point-to-point links (RFC 3021) and /32 host routes.

What is the difference between public and private IP addresses?

Public IPs are globally routed by ISPs; private addresses (10.x, 172.16-31.x, 192.168.x per RFC 1918) are only reachable inside a local network and share public IPs through NAT at the router.

How many hosts fit in a /26 subnet?

A /26 leaves 6 host bits: 2^6 = 64 total addresses, minus the network and broadcast addresses = 62 usable hosts, spanning from x.x.x.1 to x.x.x.62.