Skip to content
GridRouterhome

Search

Search providers, capabilities and pages

Geolocate an IP API

ip.geolocate

Country, region, city, ASN and connection type for an IP address.
providers document it
11

Providers

11 providers document geolocate an ip in their own API docs. None routes it through GridRouter yet. Scores appear as calls are routed.

What counts as a hit:
A country is returned for the IP.

API

Same input for every provider. Set provider.sort to route by price, reliability or latency, or provider.only to pin providers; X-Grid-Max-Cost caps what one call can spend.

Inputs for ip.geolocate
InputDescription
ip*IPv4 or IPv6 address (required)
Request
curl https://api.gridrouter.io/v1/run/ip.geolocate \
  -H "Authorization: Bearer $GRID_API_KEY" \
  -H "Content-Type: application/json" \
  -H "X-Grid-Max-Cost: 0.05" \
  -d '{"input":{"ip":"8.8.8.8"},"provider":{"sort":"price"}}'

Fields

The normalized output every provider maps into. Suppliers come from integrated endpoint mappings (verified) or field names in each provider's API docs (claimed by the provider).

Every capability's fields
Output fields for Geolocate an IP
FieldTypePIIDescriptionSupplied by
ipstring · ipIdentifierIP addressIP2Location.ioipapi.coIPGeolocation.ioIPinfo
country_codestring · countryLocationCountryIP2Location.ioipapi.coIPGeolocation.ioIPinfo
regionstringLocationRegion or stateIP2Location.ioipapi.co
citystringLocationCityIP2Location.ioipapi.coIPGeolocation.io
latitudenumberLocationLatitudeIP2Location.ioipapi.coIPGeolocation.io
longitudenumberLocationLongitudeIP2Location.ioipapi.coIPGeolocation.io
timezonestringNoneIANA timezoneIP2Location.ioipapi.coIPGeolocation.io
asnstringNoneAutonomous system numberIP2Location.ioipapi.coIPGeolocation.ioIPinfoKickFire
orgstringNoneNetwork ownerIP2Location.ioipapi.coIPGeolocation.ioIPinfo
is_proxybooleanNoneVPN, proxy or TorIP2Location.ioIPGeolocation.io