IP Geolocation Lookup avatar

IP Geolocation Lookup

Pricing

Pay per event

Go to Apify Store
IP Geolocation Lookup

IP Geolocation Lookup

This actor performs IP geolocation lookups for IP addresses and domain names. It resolves domains to IPs, then looks up country, city, region, coordinates, timezone, ISP, and organization. Uses certificate transparency and public APIs.

Pricing

Pay per event

Rating

0.0

(0)

Developer

Stas Persiianenko

Stas Persiianenko

Maintained by Community

Actor stats

0

Bookmarked

2

Total users

1

Monthly active users

17 hours ago

Last modified

Categories

Share

Look up IP geolocation for domains and IP addresses. Find country, city, ISP, and coordinates.

What does IP Geolocation Lookup do?

This actor performs IP geolocation lookups for IP addresses and domain names. It resolves domains to IPs, then looks up country, city, region, coordinates, timezone, ISP, and organization for each address. You can pass in a mix of IP addresses and domain names and get structured geolocation data for every target. Uses public geolocation APIs for accurate, up-to-date results.

Use cases

  • Security investigators -- geolocate suspicious IP addresses from server logs or threat intelligence feeds to identify attack origins
  • Compliance teams -- verify that servers and services are hosted in specific countries to meet data residency requirements
  • DevOps engineers -- confirm hosting locations for your infrastructure and verify CDN edge server placement
  • Competitive analysts -- discover where competitor websites are hosted and which ISPs or cloud providers they use
  • Network analysts -- map IP addresses to physical locations for traffic analysis and capacity planning

Why use IP Geolocation Lookup?

  • Domains and IPs accepted -- pass domain names or IP addresses interchangeably; domains are automatically resolved
  • Rich geolocation data -- returns country, region, city, latitude/longitude, timezone, ISP, and organization
  • Batch processing -- look up hundreds of targets in a single run
  • Pay-per-event pricing -- only $0.001 per lookup, keeping costs low for bulk analysis
  • Structured JSON output -- every result is formatted consistently for easy parsing and integration
  • No API keys required -- runs on Apify cloud with built-in geolocation lookups, no third-party API keys to manage

Input parameters

ParameterTypeRequiredDefaultDescription
targetsarray of stringsYes--List of IP addresses or domain names to look up geolocation for. Example: ["8.8.8.8", "google.com"]
{
"targets": [
"8.8.8.8",
"google.com",
"github.com"
]
}

Output example

Each target produces a result object with the following fields:

FieldTypeDescription
querystringThe original input (IP or domain)
ipstringThe resolved IP address
countrystringCountry name
countryCodestringISO 3166-1 alpha-2 country code
regionNamestringRegion or state name
citystringCity name
latnumberLatitude coordinate
lonnumberLongitude coordinate
timezonestringIANA timezone identifier
ispstringInternet Service Provider name
orgstringOrganization name
errorstring/nullError message if the lookup failed
checkedAtstringISO 8601 timestamp of the check
{
"query": "google.com",
"ip": "142.250.80.46",
"country": "United States",
"countryCode": "US",
"regionName": "California",
"city": "Mountain View",
"lat": 37.4056,
"lon": -122.0775,
"timezone": "America/Los_Angeles",
"isp": "Google LLC",
"org": "Google LLC",
"error": null,
"checkedAt": "2026-03-01T12:00:00.000Z"
}

How much does it cost?

EventPriceDescription
Start$0.035One-time per run
IP looked up$0.001Per IP/domain looked up

Example costs:

  • 10 targets: $0.035 + 10 x $0.001 = $0.045
  • 100 targets: $0.035 + 100 x $0.001 = $0.135
  • 1,000 targets: $0.035 + 1,000 x $0.001 = $1.035

Using the Apify API

You can start IP Geolocation Lookup programmatically from your own applications using the Apify API. The following examples show how to run the actor and retrieve results.

Node.js

import { ApifyClient } from 'apify-client';
const client = new ApifyClient({ token: 'YOUR_TOKEN' });
const run = await client.actor('automation-lab/ip-geolocation').call({
targets: ['8.8.8.8', 'google.com'],
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Python

from apify_client import ApifyClient
client = ApifyClient('YOUR_TOKEN')
run = client.actor('automation-lab/ip-geolocation').call(run_input={
'targets': ['8.8.8.8', 'google.com'],
})
items = client.dataset(run['defaultDatasetId']).list_items().items
print(items)

Integrations

IP Geolocation Lookup works with all major integration platforms supported by Apify. Connect it to Make (formerly Integromat), Zapier, n8n, or Slack to build automated geolocation workflows. Export results directly to Google Sheets for collaborative mapping or use webhooks to trigger alerts based on geographic location. You can also chain this actor with the IP Address Validator to first validate addresses and then geolocate only the valid public IPs.

Common integration patterns include:

  • Google Sheets -- export geolocation results to a spreadsheet and use the coordinates to create maps
  • Slack -- receive alerts when geolocation runs detect traffic from unexpected countries or regions
  • Zapier / Make -- automatically geolocate IP addresses from server logs or security feeds and route results to your SIEM
  • Webhooks -- receive results via POST request for real-time geographic filtering in your applications

Tips and best practices

  • Pass domains directly -- you do not need to resolve domains to IPs first. The actor handles DNS resolution automatically and returns both the resolved IP and its geolocation.
  • Combine with IP Address Validator -- run the IP Address Validator first to filter out private and invalid addresses, then pass only valid public IPs to this actor for geolocation.
  • Use coordinates for mapping -- the lat and lon fields can be used to plot results on a map for visual geographic analysis of your infrastructure or traffic.
  • Batch your lookups -- running one actor call with many targets is cheaper than many separate runs, since the $0.035 start fee is charged only once.
  • Be aware of CDN IPs -- domains behind CDNs (like Cloudflare) may resolve to edge server IPs that do not reflect the origin server's true location. The geolocation will show the CDN edge location instead.

FAQ

How accurate is the geolocation data? IP geolocation is generally accurate to the city level for most commercial ISPs. For cloud providers and CDNs, the location typically reflects the data center rather than the end user. Country-level accuracy is above 99% for most providers.

Can I look up private IP addresses? Private IP addresses (e.g., 192.168.x.x, 10.x.x.x) do not have meaningful geolocation data since they are used on internal networks. The actor will return an error or empty location fields for private addresses.

What happens if a domain cannot be resolved? If DNS resolution fails for a domain, the actor returns a result with an error field describing the failure. The IP and location fields will be null. The run continues processing remaining targets.

Can I use the coordinates to plot results on a map? Yes. The lat and lon fields are standard decimal coordinates that work with any mapping service or GIS tool. Export results to Google Sheets and use the coordinates with Google Maps, Mapbox, or any other mapping platform to visualize the geographic distribution of your targets.

What is the difference between ISP and organization? The isp field shows the Internet Service Provider that owns the IP address range (e.g., "Google LLC", "Amazon Technologies"). The org field shows the organization currently using that IP address, which may differ from the ISP if the IP is assigned to a customer or subsidiary.