IP to Location
Location + network info for any IP โ country, region, city, lat/lon, timezone, ISP. Caller IP auto-detect also supported.
Endpointโ
GET/ip
Auto-detect caller IP + location.
GET/ip?ip=8.8.8.8
Specific IP lookup.
Query Parametersโ
| Parameter | Required | Description |
|---|---|---|
ip / q | โ | Target IP โ omit to auto-detect caller IP |
Exampleโ
# Your IP
curl "https://api.apimitra.in/ip"
# Specific IP
curl "https://api.apimitra.in/ip?ip=8.8.8.8"
{
"status": "ok",
"api": "ip",
"ip": "8.8.8.8",
"location": {
"country": "United States",
"country_code": "US",
"region": "Virginia",
"region_code": "VA",
"city": "Ashburn",
"zip": "20149",
"lat": 39.03,
"lon": -77.5,
"timezone": "America/New_York"
},
"network": {
"isp": "Google LLC",
"org": "Google Public DNS",
"as": "AS15169 Google LLC"
}
}
Indian IP Exampleโ
curl "https://api.apimitra.in/ip?ip=49.36.110.10"
{
"ip": "49.36.110.10",
"location": { "city": "Mumbai", "region": "Maharashtra", "country": "India" },
"network": { "isp": "Reliance Jio Infocomm Limited" }
}
note
24h cache โ instant repeats. Invalid IP โ 400. Caller IP extracted from X-Forwarded-For header (spoof-safe).