IP Geolocation API

Get country, city, timezone, and ISP from any IP address. Cached for speed, simple REST interface.

<100ms
Cached Response
7-day
Cache TTL
Auto-detect
Caller IP

How It Works

Step 1
Send IP
Pass an IP address or auto-detect from request
Step 2
We Lookup
Check cache first, then resolve via geolocation DB
Step 3
Get Location
Receive country, city, timezone, ISP as JSON

Playground

3 free requests/day without API key

Enter an IP and click Geolocate

API Documentation

Base URL
https://ip-geo-tau.vercel.app
Authentication
X-API-Key: your_key (header) or ?key=your_key (query)Get your free key below
GET/api/geolocate?ip=8.8.8.8

Get geolocation data for an IP address. Omit the ip parameter to auto-detect the caller's IP.

Parameters

ParameterTypeRequiredDescription
ipstringnoIPv4 or IPv6 address. If omitted, detects caller IP

Response

{
  "ip": "8.8.8.8",
  "country": "United States",
  "country_code": "US",
  "city": "Mountain View",
  "region": "California",
  "timezone": "America/Los_Angeles",
  "isp": "Google LLC",
  "lat": 37.4056,
  "lon": -122.0775,
  "cached": true
}

Error Responses

// 400 — Bad Request
{ "error": "Invalid IP address" }

// 401 — Unauthorized
{ "error": "Invalid API key" }

// 429 — Rate Limited
{ "error": "Daily limit reached. Upgrade your plan." }

// 502 — Service Error
{ "error": "Geolocation service error: ..." }

Get API Key

Get a free API key for 6 requests/day. No credit card required.

Usage

  • Add header: X-API-Key: your_key
  • Or query param: ?key=your_key

Limits

  • Playground (no key): 3 req/day
  • Free tier (with key): 6 req/day
  • Paid plans: see pricing below

Pricing

Start free. Pay only when you need more.

Free
$0
  • 6 requests/day
  • All fields
  • 7-day cache
Starter
🚀 Launch Price
$12$5/mo
  • 500 requests/day
  • All fields
  • Priority
Business
🚀 Launch Price
$79$39/mo
  • 50,000 requests/day
  • All fields
  • Priority support