DEVELOPER API

Free IP Geolocation API

One GET request returns country, city, coordinates, timezone, ASN, ISP and hostname for any IPv4 or IPv6 address. JSON, CORS-enabled, no SDK needed.

  • 1,000 requests/day free with an instant key — no card
  • 100 requests/day with no key at all
  • Paid plans from $9/month, cancel any time
  • Data: DB-IP (monthly) + ipinfo enrichment, live reverse DNS
GET /api/v1/ip/8.8.8.8 example
{
  "ip": "8.8.8.8",
  "version": 4,
  "is_private": false,
  "city": "Mountain View",
  "region": "California",
  "country": "United States",
  "country_code": "US",
  "continent": "North America",
  "continent_code": "NA",
  "latitude": 37.4056,
  "longitude": -122.0775,
  "timezone": "America/Los_Angeles",
  "postal": null,
  "is_eu": false,
  "asn": "AS15169",
  "org": "Google LLC",
  "hostname": "dns.google"
}

Live request against the real endpoint. Leave blank to look up your own IP.

Get a free API key

Instant. 1,000 requests per day. We only use your email for quota notices and billing.

Usage dashboard

Paste a key to see today's usage, plan and billing options.

Documentation

Base URL: https://www.ipaddressdetails.com/api/v1

Caller's IP

GET /api/v1/ip

Returns details for the IP making the request. Ideal for "what is my IP" widgets.

Any IP

GET /api/v1/ip/{ip}

IPv4 or IPv6. Cached for one hour at the edge.

Single field, plain text

GET /api/v1/ip/{ip}/{field}

e.g. /api/v1/ip/1.1.1.1/country_codeAU. Handy for shell scripts.

Authentication

Send your key as ?key=ipad_… or the X-API-Key header. Every response includes X-RateLimit-Limit-Day and X-RateLimit-Remaining-Day. Over quota returns HTTP 429 with a JSON error.

Examples

curl "https://www.ipaddressdetails.com/api/v1/ip/8.8.8.8?key=YOUR_KEY"

# just the country code
curl "https://www.ipaddressdetails.com/api/v1/ip/8.8.8.8/country_code"

Response fields

ipThe address that was looked up.
version4 or 6.
is_privatetrue for RFC1918 / loopback / link-local ranges (no geo data).
city, region, countryEnglish names. May be null for sparse ranges.
country_codeISO 3166-1 alpha-2, e.g. "US".
continent, continent_codeContinent name and two-letter code.
latitude, longitudeApproximate coordinates (city centroid).
timezoneIANA timezone when available, e.g. "Europe/Berlin".
is_eutrue when the country is in the European Union.
asnAutonomous system number, e.g. "AS13335".
orgOrganisation / ISP that announces the prefix.
hostnameReverse DNS (PTR) record, or null.

Errors

400 invalid_ip — the path segment is not a valid IPv4/IPv6 address.

401 invalid_key — key unknown or disabled.

429 quota_exceeded — daily quota used; upgrade or wait for the UTC reset.

429 rate_limited — more than 120 requests in one minute.

Pricing

Daily quotas reset at 00:00 UTC. All plans include every field and IPv6.

Free

$0/month

  • 1,000 requests / day
  • ~30,000 / month
  • 120 requests / minute burst
  • Community support
Get free key
MOST POPULAR

Starter

$9/month

  • 30,000 requests / day
  • ~900,000 / month
  • 120 requests / minute burst
  • Email support

Pro

$29/month

  • 150,000 requests / day
  • ~4,500,000 / month
  • 120 requests / minute burst
  • Email support

Need more than 150,000/day or a bulk CSV export? Talk to us.

Frequently asked questions

Is the IP geolocation API really free?

Yes. Without a key you get 100 requests per day per IP. A free key raises that to 1,000 requests per day, no credit card required. Paid plans exist for production workloads.

How accurate is the location data?

Country is accurate for the vast majority of addresses. City-level accuracy is typically within 25–50 km for residential broadband and less reliable for mobile carriers, VPNs and corporate networks. Never use IP geolocation for anything that needs a street address.

Where does the data come from?

Geolocation and ASN data come from the DB-IP Lite database (updated monthly) with fallback enrichment from ipinfo.io. Reverse DNS hostnames are resolved live.

Does the API support IPv6?

Yes. Pass any IPv4 or IPv6 address, or call /api/v1/ip with no address to get details for the caller.

Can I call the API from a browser?

Yes. CORS is enabled for all origins. For browser apps use the anonymous endpoint or a key you are comfortable exposing (usage limits protect you).

Can I cancel a paid plan?

Any time from the billing portal. Your key immediately drops back to the free tier at the end of the billing period.