deftools.io Domain & Network

CIDR / Subnet Calculator

Calculate IPv4 subnet details from CIDR notation: network address, broadcast, mask, wildcard, host range, usable hosts. Subnet list & VLSM split.

Try an example

About this tool

CIDR notation (Classless Inter-Domain Routing) is the compact way to describe an IP range. 192.168.1.0/24 means "the network 192.168.1.0 with a 24-bit mask" — the first 24 bits are fixed and the remaining 8 bits identify hosts. The suffix can be anything from /0 (the whole IPv4 space) to /32 (one single address).

From that one line you can derive everything about the subnet: the network address (first IP, where host bits are zero), the broadcast address (last IP, where host bits are all ones), the subnet mask and its inverse (the wildcard), the usable host range, and the total number of hosts. Example: 10.0.0.0/24 → network 10.0.0.0, broadcast 10.0.0.255, mask 255.255.255.0, 254 usable hosts (10.0.0.1–10.0.0.254).

This calculator also splits a block into smaller subnets using VLSM, useful when you are designing a network and need to fit subnets of different sizes (a /26 for 60 hosts, a /28 for 12, etc.) inside one larger block.

FAQ

How many usable hosts does a /24 have?

A /24 leaves 8 bits for hosts, so 2⁸ = 256 total addresses. Subtract the network address and the broadcast address and you get 254 usable hosts.

What is the difference between the subnet mask and the wildcard mask?

They are bitwise complements of each other. The mask 255.255.255.0 marks which bits are the network; the wildcard 0.0.0.255 marks which bits are the host. Firewalls and routing protocols like OSPF use the wildcard form.

Why can I not use the first and last address of a subnet?

By convention the all-zero host bits (the network address) identifies the subnet itself, and the all-ones host bits (the broadcast address) reaches every host on it. Neither can be assigned to a device.

How do I choose the right CIDR prefix for N hosts?

Find the smallest prefix whose host bits give you at least N+2 addresses (the +2 accounts for network and broadcast). For example 60 hosts need 62 addresses, which fits in 6 host bits — a /26.

Can I share a CIDR calculation with a colleague?

Yes. Click "Share" next to the input to copy a URL that encodes the current CIDR. Opening that link loads the same value and shows the full subnet breakdown immediately.

Related domain & network tools

Copied!