IPv4 Range Expander

How to use this IPv4 range expander

  1. Type a start and end IP address defining your range.
  2. The tool calculates the minimal set of CIDR blocks that exactly cover that range.
  3. Use the result in firewall rules or routing configuration.

Why does a range need multiple CIDR blocks?

CIDR blocks must start on an address boundary aligned to their size (a /24 must start at a multiple of 256, for example). Arbitrary ranges rarely align perfectly, so they're split into the largest possible aligned blocks that fit.

Why do I sometimes get many small CIDR blocks instead of one?

This happens when the range doesn't align to a clean power-of-2 boundary — the algorithm has to break it into the fewest aligned blocks possible, which can still be several for odd ranges.

Can I use this for firewall rules directly?

Yes, most firewalls and cloud security groups (AWS, Cloudflare, etc.) accept CIDR notation directly, so you can paste the generated blocks as-is.