How Many Hosts Per Subnet? The Complete Guide

One of the most common subnetting questions is: "How many devices can I fit in this subnet?" The answer is simpler than you might think.

The Simple Formula

Usable Hosts = 2(32 - CIDR) - 2

Here's why we subtract 2:

Reference Table

CIDRSubnet MaskTotal IPsUsable Hosts
/30255.255.255.25242
/29255.255.255.24886
/28255.255.255.2401614
/27255.255.255.2243230
/26255.255.255.1926462
/25255.255.255.128128126
/24255.255.255.0256254
/23255.255.254.0512510
/22255.255.252.010241022
/21255.255.248.020482046
/20255.255.240.040964094
/16255.255.0.065,53665,534
/8255.0.0.016,777,21616,777,214

Quick Memory Trick

Want to remember the pattern? Each step from /24 down (adding 1 to the CIDR) halves the hosts:

CIDRUsable Hosts
/24254
/25126
/2662
/2730
/2814
/296
/302
💡 Pattern: Going from /24 to /30, the hosts go: 254 → 126 → 62 → 30 → 14 → 6 → 2. Each step roughly halves the count (minus 2).

Practical Examples

Home Network

Typical home has 10-20 devices.
Use /24 (254 hosts) - plenty of room!

Small Office

50 employees with computers and phones.
Use /26 (62 hosts) - fits with room to grow.

Warehouse IoT

50 sensors, scanners, cameras.
Use /26 or split into /27 (30 hosts each).

Point-to-Point Link

Router-to-router connection.
Use /30 (2 hosts only).

Data Center

500 servers.
Use /23 (510 hosts).

Planning for Growth

Always give yourself buffer. If you need 50 hosts today:

Better to allocate slightly larger subnets now than rush to reconfigure later.

👉 Instant Host Count Calculator


← Back to Blog | Privacy Policy | Contact Us