Subnet CIDR Calculator Tool

Network 10.0.0.0/24
Netmask 255.255.255.0
Broadcast10.0.0.255
Usable Addresses10.0.0.1 - 10.0.0.254
Total addresses256
Private addressesTrue
Multicast addressesFalse

How to Calculate Subnets (IPv4 Subnetting Step-by-Step)

Subnetting means dividing one big network into smaller sub-networks (subnets).

Most common exam question types:
• How many subnets can I create?
• How many hosts per subnet?
• What are the subnet addresses / broadcast addresses / usable range?

Key Formulas You Must Memorize

Number of subnets = 2ⁿ where n = number of bits borrowed from host part Number of hosts per subnet = 2ʰ − 2 where h = remaining host bits (we subtract 2 because network address and broadcast address are not usable)

Fast Reference Table – Class C (/24) Most Common

Subnet Mask CIDR Bits borrowed Number of subnets Usable hosts per subnet Increment (block size)
255.255.255.128/2512126128
255.255.255.192/26246264
255.255.255.224/27383032
255.255.255.240/284161416
255.255.255.248/2953268
255.255.255.252/3066424

Step-by-Step Example

Question: You have network 192.168.10.0/24.
You need at least 5 subnets with as many hosts as possible in each subnet.

Step 1: How many bits do we need to borrow?
2² = 4 subnets → too few
2³ = 8 subnets → enough (we borrow 3 bits)

Step 2: New subnet mask = /24 + 3 = /27
Subnet mask = 255.255.255.224

Step 3: Block size (increment) = 256 − 224 = 32

Step 4: Subnet ranges:
  • 192.168.10.0 – 192.168.10.31 (/27)
  • 192.168.10.32 – 192.168.10.63
  • 192.168.10.64 – 192.168.10.95
  • 192.168.10.96 – 192.168.10.127
  • 192.168.10.128 – 192.168.10.159
  • 192.168.10.160 – 192.168.10.191
  • 192.168.10.192 – 192.168.10.223
  • 192.168.10.224 – 192.168.10.255
Usable hosts per subnet: 2⁵ − 2 = 30 hosts

Quick Cheat Method (most used in exams)

  1. Write down original network + mask (example: 172.16.0.0 /16)
  2. Decide how many subnets OR how many hosts you need
  3. Find the smallest power of 2 that satisfies the requirement
  4. Calculate new /CIDR → new mask
  5. Calculate block size: 256 − last octet of mask
  6. Add block size repeatedly to find each subnet address

Practice with different class B and class C networks — after ~10 examples it becomes automatic!