IP CIDR Range Check API - Free Subnet Matcher
Checks whether an IPv4 address falls within a given CIDR range. Returns network address, broadcast address, prefix length, and total hosts in the range.
Code examples
curl -X POST https://api.botoi.com/v1/ip/in-range \
-H "Content-Type: application/json" \
-d '{"ip":"192.168.1.50","range":"192.168.1.0/24"}'When to use this API
Allowlist corporate office IPs
Before granting access to an internal admin panel, verify that the incoming request IP falls within your company VPN CIDR block. Reject requests from IPs outside the range and log the attempt for security review.
Classify traffic by network origin
Tag incoming requests as "cloud provider", "residential", or "corporate" by checking each IP against known CIDR blocks for AWS, GCP, and Azure. Use the classification to apply different rate limits or bot detection rules.
Frequently asked questions
What CIDR notation formats are supported?
Standard IPv4 CIDR notation like 10.0.0.0/8, 172.16.0.0/12, or 192.168.1.0/24. The prefix length must be between 0 and 32.
Does this support IPv6 CIDR ranges?
This endpoint currently supports IPv4 addresses and CIDR ranges only. IPv6 support is planned for a future release.
What does total_hosts represent?
total_hosts is the total number of addresses in the CIDR block, including the network and broadcast addresses. For a /24 range, total_hosts is 256 (2^8).
Can I check multiple IPs against one range in a single call?
This endpoint checks one IP at a time. For bulk checks, send multiple parallel requests or loop through your IP list client-side.
Get your API key
Free tier includes 5 requests per minute with no credit card required. Upgrade for higher limits.