How to use the cidr converter
- Choose direction: CIDR → range, or range → CIDR.
- Enter the input. The tool returns first IP, last IP, total count, and CIDR notation.
- For range → CIDR it finds the minimum spanning prefix.
Convert between CIDR notation and subnet details, or convert a subnet mask to prefix length.
/24 has 256 addresses. The range is 192.168.1.0 through 192.168.1.255, with usable hosts 192.168.1.1 to 192.168.1.254.
Convert both endpoints to binary, find the longest common prefix, then take that prefix as the CIDR. The block size must be a power of 2 and the start must align to it.
A CIDR block has to start on a boundary that is a multiple of its size. If your range starts in the middle of a block or spans uneven sizes, you need multiple CIDRs.
CIDR removed fixed class A / B / C boundaries and let prefixes have any length from /1 to /32. This unlocked variable-length subnet masking and route aggregation.