IP Range to CIDR
Beta: this tool hasn't been fully reviewed yet. Double-check results before relying on them.
Inputs
One per line (or separated by commas): 10.0.0.1-10.0.0.6, 192.168.0.0/24, 2001:db8::/48.
Results
- CIDR blocks
- —
- Addresses covered
- —
Merged ranges
| From | To | Addresses | CIDR blocks |
|---|
Your input is too long to share as a link, so the page address no longer includes it.
Firewalls, cloud security groups and route tables want CIDR blocks (like 10.0.0.0/24), not ranges. A range rarely fits in one block: it has to be split into blocks that each start on a power-of-two boundary. This tool does that split, and also merges overlapping or neighboring entries so your list is as short as possible.
How to use it
- Paste your ranges, addresses or CIDR blocks, one per line.
- Copy the resulting CIDR list.
- Check the merged ranges table to see which entries were combined.
Examples: the range 10.0.0.1-10.0.0.6 needs 4 blocks: 10.0.0.1/32, 10.0.0.2/31, 10.0.0.4/31 and 10.0.0.6/32. The blocks 10.0.0.0/24 and 10.0.1.0/24 merge into 10.0.0.0/23.
Questions and answers
Why does one range need several CIDR blocks?
A CIDR block always holds a power of two addresses (1, 2, 4, 8…) and starts at a multiple of its size. A range like .1 to .6 has 6 addresses that don’t start on such a boundary, so it takes several blocks.
Does merging change which addresses are covered?
No. The output covers exactly the same addresses as the input, without duplicates. Only overlapping or touching entries are combined.
Can I mix IPv4 and IPv6?
Yes. They’re handled separately and the IPv4 blocks are listed first. A range must have the same version at both ends.
Link with pre-filled values
Add # and these parameters to the end of this page's address to open the tool with values already filled in.
| Parameter | What it sets |
|---|---|
ranges | Ranges, addresses or CIDR blocks, comma- or newline-separated. |
Example: https://toolabelle.com/ip-range-to-cidr/#ranges=10.0.0.0%2F24%2C10.0.1.0%2F24