IP to location APIs

Convert IP address to city and/or longitude+latitude

IP geolocation APIs tell you where an IP address is: country, region, city, time zone and often the network provider. Use them to show local content, pre-fill a country field or spot suspicious log-ins; several work without a key for modest use.

Abstract IP Geolocation API

Abstract's IP Geolocation API returns the location of any IP address worldwide: city, region, country, postal code, coordinates and time zone, plus the currency, the network (ASN) and connection type, and flags for VPN and proxy ...

API, HTTP-GET, JSON, REST

country.is

country.is does one thing: it tells you the country of an IP address, as a two-letter country code in a tiny JSON response. Call it without an address to get the country of the visitor, for example to preselect a country in a ...

API, HTTP-GET, JSON, REST

HostIP.info API

This is an easy HTTP oriented API to locate IP addresses and Geocode them. If you don't supply the "?ip=aa.bb.cc.dd" bit, then the ip address lookup of the calling machine will be located instead (here, the aa,bb,cc,dd are ...

HTTP-GET

ip-api

ip-api finds the location of an IP address or domain: country, region, city, ZIP code, coordinates, time zone, ISP, organisation and AS number, and whether it is a mobile, proxy or hosting address. Responses are JSON, XML, CSV or ...

API, HTTP-GET, JSON, REST

ipapi.co

ipapi.co returns the location and details of an IP address: city, region, country, postal code, coordinates, time zone, currency, calling code, languages and the network (ASN and organisation). Ask for one field or the full ...

API, CSV, HTTP-GET, JSON, REST, XML

ipify

ipify returns the public IP address of whoever calls it, as plain text, JSON or JSONP, over IPv4 or IPv6. Handy for scripts, dynamic DNS clients and apps that need to know their own public address. Free and open source, no key ...

API, HTTP-GET, JSON, REST

ipinfo.io

ipinfo.io returns data about any IP address: city, region, country, coordinates, postal code, time zone, hostname and the organisation or network (ASN) it belongs to. A simple request like ipinfo.io/8.8.8.8/json is enough to ...

API, HTTP-GET, JSON, MCP, REST

IPInfoDB IP Location API

The IPInfoDB IP Location API finds the location of an IP address: country, region, city, ZIP code, latitude, longitude and time zone. Use the country-only call for speed or the city call for full detail. Responses are JSON or ...

API, HTTP-GET, JSON, REST, XML

ipquery.io

ipquery.io returns information about an IP address: country, region, city, postal code, time zone and coordinates, the ISP and AS number, and risk flags that show whether the address is mobile, a VPN, Tor or a proxy, with a risk ...

API, HTTP-GET, JSON, REST, XML

ipwho.is

ipwho.is gives IP geolocation data for IPv4 and IPv6 addresses: continent, country, region, city, coordinates, postal code, time zone, currency, flag and the network (ASN, ISP). One GET request per address, JSON responses. Free ...

API, HTTP-GET, JSON, REST

Compare the IP geolocation APIs

ServiceAPI keyFormatsFree use
Abstract IP Geolocation API Needed, free JSON Free plan with a monthly request limit; paid plans for more requests and features.
country.is Not needed JSON Free and open source, no key needed.
HostIP.info API Not needed – –
ip-api Not needed JSON Free for non-commercial use without a key, at up to 45 requests per minute over HTTP; commercial use and HTTPS need the paid Pro plan.
ipapi.co Not needed JSON, XML, CSV Free without a key up to about 1,000 requests per day; paid plans for more.
ipify Not needed JSON Free and open source, no key and no usage limit.
ipinfo.io Needed, free JSON A free account with a token raises the limits; paid plans add details such as privacy detection (VPN, proxy, Tor) and company data.
IPInfoDB IP Location API Needed, free JSON, XML Free with a free API key.
ipquery.io Not needed JSON, XML Free, no key needed, within a rate limit.
ipwho.is Not needed JSON Free without a key for non-commercial use; the paid ipwhois.io plans are for commercial use and higher volumes.

Questions

Which free IP geolocation APIs work without an API key?

country.is, HostIP.info API, ip-api, ipapi.co, ipify, ipquery.io and ipwho.is work without a key, according to their documentation. Most keyless services ask you to keep the number of requests reasonable, and some ask for a User-Agent that names your app.

Are these IP geolocation APIs really free?

The services here can be used without paying, at least on a free plan or free tier, often with limits such as a number of requests per day or non-commercial use only. The table above quotes what each service says about its free use; check the provider's own terms before you rely on it.

How up to date is this list?

The address of every service is checked about once a week, and services that stop working or stop being free are removed. This list last changed on November 11th, 2026.