Global IP Database

This site provides a combination of multiple IP ranges as a single JSON file.

Download (63.1 MB)
URL for automation: https://cable.ayra.ch/ip/global.json

We provide an application that uses the list to block ranges in Windows named AnyBlock

API

The chapters below describe how to automatically download the list

HTTP Caching

This download supports HTTP caching and is generated at most once every 24 hours. We recommend you implement HTTP caching using the If-Modified-Since header. Alternatively, this server also sends the Expires header.

User Agent

Be sure to send a proper User Agent string to avoid being blocked. The bare minimum should be the name of your application, a version number and a public URL or E-mail address to contact you in case of problems. Example: ExampleBlock/1.3 +https://example.com/URL/To/Repository. We retain the right to block User agents that:

3rd Party License

The country database is provided by a 3rd party, which licensed it under the Creative Commons License type CC BY-SA 4.0 By using the country list you accept these terms. More details can be found here.

File Format

The JSON structure is stacked three levels deep as explained below.

First Level: Category

The first level is the category. Current categories are (not necessarily in this order):

Second Level: Subcategory

The subcategory is provided by the list itself. If none is available, the category name is repeated to keep the file format consistent. Subcategories are currently only provided by Amazon and Azure. For the asn list, the subcategory is the name of the owner.

Third Level: Location

The third level is the location/description of the range. For the countries, this would be the country code. The value of each entry is an array of IP address ranges in CIDR notation.
Cloudflare provides seperate lists for v4 and v6 addresses so they are delivered this way.

Example

{
	"category1": {
		"subcategory1": {
			"range1": ["ip/cidr", "ip/cidr", ...],
			...
		},
		...
	},
	...
}

CIDR Notation

IP addresses are always listed using CIDR notation, even if an entry contains only a single address. In that case the mask will be 32 for IPv4 or 128 for IPv6. The address is given as provided to us, we do not check if it's the lowest IP of the given range.

Special Entries

The country list has to be treated specially. The country code "__" contains all IP ranges that are not assigned to a country. This includes private IP ranges. The IP list for each country includes IPv6 entries. These entries contain the IPv4 mapped addresses too (::FFFF:W.X.Y.Z).

The tor list contains duplicates. The list is divided into categories, but an IP address can have multiple categories, in which case it appears in all of them.

The asn list has as owner _ the range AS0. This range contains all unassigned and reserved blocks, this includes private addresses.

This site or product includes IP2Location LITE data available from ip2location