LocalityAPI
Get API Key

IP Geolocation

IP address to full location, currency and ISP.

GET

Parameters

ParameterTypeRequiredDescription
ipstringOptionalIP address to look up (omit to auto-detect caller IP)

Request Example

curl "https://api.localityapi.com/v1/ip?ip=8.8.8.8" \
  -H "X-API-Key: lapi_your_key"

Response

json
{
  "ip": "8.8.8.8",
  "country": "US",
  "country_name": "United States",
  "city": null,
  "timezone": "America/Chicago",
  "current_time": "2026-06-02 13:33:51",
  "currency": "USD",
  "currency_symbol": "$",
  "phone_code": "+1",
  "languages": ["English"],
  "isp": "Google LLC",
  "asn": "AS15169",
  "is_eu": false,
  "query_ms": 9
}

Response Fields

ipstringThe IP address
countrystringISO2 country code
country_namestringFull country name
citystring|nullCity name if available
timezonestringIANA timezone identifier
current_timestringCurrent local time
currencystringCurrency code
currency_symbolstringCurrency symbol
phone_codestringPhone dialing code
languagesarrayOfficial languages
ispstringInternet Service Provider
asnstringAutonomous System Number
is_eubooleanWhether in European Union
query_msintegerQuery execution time in milliseconds