Bulk IP Geolocation Lookup API - Instantly Geolocate Thousands of IP Addresses
Effortlessly manage your geolocation needs with our Bulk IP Geolocation Lookup API. Tailored for both developers and businesses, our API streamlines the process of obtaining precise geolocation data for thousands of IP addresses in real-time. Whether you are analyzing large datasets, strengthening your cybersecurity measures, or refining your targeted marketing strategies, our API delivers accurate and reliable geolocation data in your preferred language, perfectly aligning with your specific requirements.
Our Bulk IP Geolocation Lookup API simplifies the management and processing of bulk IP data, enhancing your operational efficiency and providing actionable insights with ease. Benefit from seamless integration and robust performance, all backed by our dedication to delivering consistent and reliable geolocation information whenever you need it.
Features
Multilingual Support
Our Bulk IP Geolocation Lookup API supports multiple languages, delivering geolocation data in your preferred language. Enhance user experience and cater to a global audience effortlessly.
50K IPs per Request
Our API supports bulk lookup of up to 50,000 IP addresses in a single request, streamlining large-scale geolocation tasks with ease. Effortlessly handle extensive data with speed and accuracy.
Response Filtration
Specify the desired fields in your query parameter to receive only the data you need. Our response filtration feature applies your filters to each individual IP response, optimizing processing time, reducing bandwidth usage, and enhancing overall API response speed. This ensures you get precise and efficient results tailored to your requirements.
IP Security Information
Our Bulk IP Geolocation Lookup API provides comprehensive IP security data alongside geolocation information for each IP address. In addition to accurate location details, receive valuable security insights such as threat intelligence and risk assessments for every IP in your batch. Enhance your data analysis with detailed security context to improve decision-making and safeguard your network.
IP Hostname Lookup
Our API offers flexible IP hostname lookup options alongside geolocation data. You can obtain hostname information through three methods: live sources, our extensive database, or a combination of both. This flexibility ensures you get the most accurate and up-to-date hostname data for each IP address in your bulk IP lookup, enhancing your data analysis and operational efficiency.
User-Agent Insights
Gain a deeper understanding of IPs by parsing their user-agent strings alongside geolocation data. This powerful combination empowers you to optimize your website, application, or service for better user experience, while also providing valuable context for security and analytics.
IP Abuse Contact Information
Identify and mitigate potential security threats with our IP Abuse contact information feature. Get the abuse contact details for each IP address in your bulk lookup and take proactive measures to safeguard your network and infrastructure.
IP Time Zones Information
Effortlessly adjust your services to match the time zones with our accurate time zone information. This feature is particularly useful for scheduling, billing, and general user experience optimization.
API Endpoint
$ pip install requestsimport requests
import json
url = "https://api.apifreaks.com/v2.0/geolocation/lookup?lang=en&excludes=hostname&include=security%2ChostnameFallbackLive"
payload = json.dumps({
"ips": [
"8.8.8.8",
"1.1.1.1",
"dns.google.com"
]
})
headers = {
'Content-Type': 'application/json',
'X-apiKey': 'API-KEY'
}
response = requests.request("POST", url, headers=headers, data=payload)
print(response.text)
A maximum of 50,000 IP-addresses/host-names can be included in the request body for a bulk lookup request.
How-To-Guides
Lookup by IPv4, IPv6 address or hostname
Provide IPv4, IPv6, or hostnames in the request body. Our API will return the geolocation information corresponding to each input, delivering accurate and comprehensive data tailored to your needs.
#Response [ { "ip": "1.1.1.1", "location": { "continent_code": "OC", "continent_name": "Oceania", "country_code2": "AU", "country_code3": "AUS", "country_name": "Australia", "country_name_official": "Commonwealth of Australia", "country_capital": "Canberra", "state_prov": "Queensland", "state_code": "AU-QLD", "district": "Brisbane", "city": "South Brisbane", "zipcode": "4101", "latitude": "-27.47301", "longitude": "153.01425", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/au_64.png", "geoname_id": "10113228", "country_emoji": "🇦🇺" }, "country_metadata": { "calling_code": "+61", "tld": ".au", "languages": [ "en-AU" ] }, "network": { "connection_type": "", "route": "1.1.1.0/24", "is_anycast": true }, "currency": { "code": "AUD", "name": "Australian Dollar", "symbol": "A$" }, "asn": { "as_number": "AS13335", "organization": "Cloudflare, Inc.", "country": "US", "type": "BUSINESS", "domain": "cloudflare.com", "date_allocated": "2010-07-14", "rir": "ARIN" }, "company": { "name": "APNIC Research and Development", "type": "", "domain": "" }, "time_zone": { "name": "Australia/Brisbane", "offset": 10, "offset_with_dst": 10, "current_time": "2026-07-08 20:52:51.556+1000", "current_time_unix": 1783515171.556, "current_tz_abbreviation": "AEST", "current_tz_full_name": "Australian Eastern Standard Time", "standard_tz_abbreviation": "AEST", "standard_tz_full_name": "Australian Eastern Standard Time", "is_dst": false, "dst_savings": 0, "dst_exists": false, "dst_tz_abbreviation": "", "dst_tz_full_name": "", "dst_start": {}, "dst_end": {} } }, { "domain": "dns.google.com", "ip": "8.8.4.4", "location": { "continent_code": "NA", "continent_name": "North America", "country_code2": "US", "country_code3": "USA", "country_name": "United States", "country_name_official": "United States of America", "country_capital": "Washington, D.C.", "state_prov": "California", "state_code": "US-CA", "district": "Santa Clara", "city": "Mountain View", "zipcode": "94043-1351", "latitude": "37.42240", "longitude": "-122.08421", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/us_64.png", "geoname_id": "6301403", "country_emoji": "🇺🇸" }, "country_metadata": { "calling_code": "+1", "tld": ".us", "languages": [ "en-US", "es-US", "haw", "fr" ] }, "network": { "connection_type": "", "route": "8.8.4.0/24", "is_anycast": true }, "currency": { "code": "USD", "name": "US Dollar", "symbol": "$" }, "asn": { "as_number": "AS15169", "organization": "Google LLC", "country": "US", "type": "BUSINESS", "domain": "google.com", "date_allocated": "2000-03-30", "rir": "ARIN" }, "company": { "name": "Google LLC", "type": "HOSTING", "domain": "google.com" }, "time_zone": { "name": "America/Los_Angeles", "offset": -8, "offset_with_dst": -7, "current_time": "2026-07-08 03:52:51.579-0700", "current_time_unix": 1783515171.579, "current_tz_abbreviation": "PDT", "current_tz_full_name": "Pacific Daylight Time", "standard_tz_abbreviation": "PST", "standard_tz_full_name": "Pacific Standard Time", "is_dst": true, "dst_savings": 1, "dst_exists": true, "dst_tz_abbreviation": "PDT", "dst_tz_full_name": "Pacific Daylight Time", "dst_start": { "utc_time": "2026-03-08 TIME 10:00", "duration": "+1.00H", "gap": true, "date_time_after": "2026-03-08 TIME 03:00", "date_time_before": "2026-03-08 TIME 02:00", "overlap": false }, "dst_end": { "utc_time": "2026-11-01 TIME 09:00", "duration": "-1.00H", "gap": false, "date_time_after": "2026-11-01 TIME 01:00", "date_time_before": "2026-11-01 TIME 02:00", "overlap": true } } }, { "ip": "2001:4860:4860:0:0:0:0:1", "location": { "continent_code": "NA", "continent_name": "North America", "country_code2": "US", "country_code3": "USA", "country_name": "United States", "country_name_official": "United States of America", "country_capital": "Washington, D.C.", "state_prov": "California", "state_code": "US-CA", "district": "Santa Clara", "city": "Mountain View", "zipcode": "94043-1351", "latitude": "37.42240", "longitude": "-122.08421", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/us_64.png", "geoname_id": "6301403", "country_emoji": "🇺🇸" }, "country_metadata": { "calling_code": "+1", "tld": ".us", "languages": [ "en-US", "es-US", "haw", "fr" ] }, "network": { "connection_type": "", "route": "8.8.4.0/24", "is_anycast": true }, "currency": { "code": "USD", "name": "US Dollar", "symbol": "$" }, "asn": { "as_number": "AS15169", "organization": "Google LLC", "country": "US", "type": "BUSINESS", "domain": "google.com", "date_allocated": "2000-03-30", "rir": "ARIN" }, "company": { "name": "Google LLC", "type": "HOSTING", "domain": "google.com" }, "time_zone": { "name": "America/Los_Angeles", "offset": -8, "offset_with_dst": -7, "current_time": "2026-07-08 03:52:51.579-0700", "current_time_unix": 1783515171.579, "current_tz_abbreviation": "PDT", "current_tz_full_name": "Pacific Daylight Time", "standard_tz_abbreviation": "PST", "standard_tz_full_name": "Pacific Standard Time", "is_dst": true, "dst_savings": 1, "dst_exists": true, "dst_tz_abbreviation": "PDT", "dst_tz_full_name": "Pacific Daylight Time", "dst_start": { "utc_time": "2026-03-08 TIME 10:00", "duration": "+1.00H", "gap": true, "date_time_after": "2026-03-08 TIME 03:00", "date_time_before": "2026-03-08 TIME 02:00", "overlap": false }, "dst_end": { "utc_time": "2026-11-01 TIME 09:00", "duration": "-1.00H", "gap": false, "date_time_after": "2026-11-01 TIME 01:00", "date_time_before": "2026-11-01 TIME 02:00", "overlap": true } } } ]curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "1.1.1.1", "dns.google.com", "2001:4860:4860::1" ] }'
JSON / XML Response Format
To customize the response format of your Bulk IP Geolocation Lookup API, use the format parameter in your request. If you do not specify a format, the default response will be in JSON. To receive the response in XML format, simply include the format query parameter with the value xml. This flexibility ensures you receive the bulk IP geolocation data in the format that best suits your needs, providing seamless integration and convenience, whether you prefer JSON or XML.
#Response <ArrayList> <item> <ip>1.1.1.1</ip> <location> <continent_code>OC</continent_code> <continent_name>Oceania</continent_name> <country_code2>AU</country_code2> <country_code3>AUS</country_code3> <country_name>Australia</country_name> <country_name_official>Commonwealth of Australia</country_name_official> <country_capital>Canberra</country_capital> <state_prov>Queensland</state_prov> <state_code>AU-QLD</state_code> <district>Brisbane</district> <city>South Brisbane</city> <zipcode>4101</zipcode> <latitude>-27.47306</latitude> <longitude>153.01421</longitude> <is_eu>false</is_eu> <country_flag>https://ipgeolocation.io/static/flags/au_64.png</country_flag> <geoname_id>10113228</geoname_id> <country_emoji>🇦🇺</country_emoji> </location> </item> </ArrayList>curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup?format=xml&fields=location' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "1.1.1.1" ] }'
Response Filtration
The Bulk IP Geolocation Lookup API is designed for precise and efficient geolocation data retrieval. By specifying desired fields in the query parameters, you can tailor the response to include only the information you need for each IP address. This customization enhances the efficiency of your IP lookup and geolocation tasks by delivering targeted and relevant data. You can customize the API response in two effective ways:
- Include Specific Fields: Use the fields query parameter with a comma-separated list of desired fields to ensure only those are included in the response for each IP address.
- Exclude Unwanted Fields: Use the excludes query parameter with a comma-separated list of fields to omit from the response, streamlining the data to focus on what's most important for your needs.
#Response [ { "ip": "1.1.1.1", "location": { "city": "South Brisbane" } }, { "ip": "8.8.8.8", "location": { "city": "Mountain View" } } ] # Get the geolocation and exclude the continent information# Get city information only curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup?fields=location.city' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "1.1.1.1", "8.8.8.8" ] }'#Response [ { "ip": "1.1.1.1", "location": { "continent_code": "OC", "continent_name": "Oceania", "country_code2": "AU", "country_code3": "AUS", "country_name": "Australia", "country_name_official": "Commonwealth of Australia", "country_capital": "Canberra", "state_prov": "Queensland", "state_code": "AU-QLD", "district": "Brisbane", "city": "South Brisbane", "zipcode": "4101", "latitude": "-27.47306", "longitude": "153.01421", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/au_64.png", "geoname_id": "10113228", "country_emoji": "🇦🇺" }, "country_metadata": { "calling_code": "+61", "tld": ".au", "languages": [ "en-AU" ] }, "network": { "asn": { "as_number": "AS13335", "organization": "Cloudflare, Inc.", "country": "US", "asn_name": "CLOUDFLARENET", "type": "BUSINESS", "domain": "cloudflare.com", "date_allocated": "", "allocation_status": "assigned", "num_of_ipv4_routes": "2507", "num_of_ipv6_routes": "3297", "rir": "ARIN" }, "connection_type": "", "company": { "name": "APNIC Research and Development", "type": "", "domain": "" } }, "currency": { "code": "AUD", "name": "Australian Dollar", "symbol": "A$" }, "geo": "Field 'geo' is not supported" }, { "ip": "111.111.111.111", "location": { "continent_code": "AS", "continent_name": "Asia", "country_code2": "JP", "country_code3": "JPN", "country_name": "Japan", "country_name_official": "Japan", "country_capital": "Tokyo", "state_prov": "Tokyo", "state_code": "JP-13", "district": "Chiyoda", "city": "Tokyo", "zipcode": "102-0000", "latitude": "35.69495", "longitude": "139.75398", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/jp_64.png", "geoname_id": "1864529", "country_emoji": "🇯🇵" }, "country_metadata": { "calling_code": "+81", "tld": ".jp", "languages": [ "ja" ] }, "network": { "asn": { "as_number": "AS2516", "organization": "KDDI CORPORATION", "country": "JP", "asn_name": "APNIC-AS-X-BLOCK", "type": "ISP", "domain": "kddi.com", "date_allocated": "", "allocation_status": "assigned", "num_of_ipv4_routes": "521", "num_of_ipv6_routes": "12", "rir": "JPNIC" }, "connection_type": "", "company": { "name": "KDDI CORPORATION", "type": "Business", "domain": "kddi.com" } }, "currency": { "code": "JPY", "name": "Yen", "symbol": "¥" }, "geo": "Field 'geo' is not supported" } ]curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup?fields=geo&excludes=continent_code' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "1.1.1.1", "111.111.111.111" ] }'
IP Security Information
The Bulk IP Geolocation Lookup API also offers valuable IP-Security information, which is not included by default. To receive detailed IP-Security insights along with your geolocation data, simply add the include=security query parameter to your request. This addition ensures that you get comprehensive security details for each IP address, significantly enhancing the value and utility of your geolocation results and providing a more complete view of your IP data.
#Response [ { "ip": "223.226.83.58", "location": { "continent_code": "AS", "continent_name": "Asia", "country_code2": "IN", "country_code3": "IND", "country_name": "India", "country_name_official": "Republic of India", "country_capital": "New Delhi", "state_prov": "Uttar Pradesh", "state_code": "IN-UP", "district": "Gautam Buddha Nagar", "city": "Noida", "zipcode": "201304", "latitude": "28.53552", "longitude": "77.39103", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/in_64.png", "geoname_id": "10107465", "country_emoji": "🇮🇳" }, "security": { "threat_score": 0, "is_tor": false, "is_proxy": false, "proxy_provider_names": [], "proxy_confidence_score": 0, "proxy_last_seen": "", "is_residential_proxy": false, "is_vpn": false, "vpn_provider_names": [], "vpn_confidence_score": 0, "vpn_last_seen": "", "is_relay": false, "relay_provider_name": "", "is_anonymous": false, "is_known_attacker": false, "is_spam": false, "is_bot": false, "is_cloud_provider": false, "cloud_provider_name": "" } }, { "ip": "8.8.8.8", "location": { "continent_code": "NA", "continent_name": "North America", "country_code2": "US", "country_code3": "USA", "country_name": "United States", "country_name_official": "United States of America", "country_capital": "Washington, D.C.", "state_prov": "California", "state_code": "US-CA", "district": "Santa Clara", "city": "Mountain View", "zipcode": "94043-1351", "latitude": "37.42240", "longitude": "-122.08421", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/us_64.png", "geoname_id": "6301403", "country_emoji": "🇺🇸" }, "security": { "threat_score": 5, "is_tor": false, "is_proxy": false, "proxy_provider_names": [], "proxy_confidence_score": 0, "proxy_last_seen": "", "is_residential_proxy": false, "is_vpn": false, "vpn_provider_names": [], "vpn_confidence_score": 0, "vpn_last_seen": "", "is_relay": false, "relay_provider_name": "", "is_anonymous": false, "is_known_attacker": false, "is_spam": false, "is_bot": false, "is_cloud_provider": true, "cloud_provider_name": "Google LLC" } }, { "ip": "217.9.247.116", "location": { "continent_code": "EU", "continent_name": "Europe", "country_code2": "AL", "country_code3": "ALB", "country_name": "Albania", "country_name_official": "Republic of Albania", "country_capital": "Tirana", "state_prov": "Tirana", "state_code": "AL-11", "district": "Tirana", "city": "Tirana", "zipcode": "1010", "latitude": "41.32232", "longitude": "19.82517", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/al_64.png", "geoname_id": "10115263", "country_emoji": "🇦🇱" }, "security": { "threat_score": 45, "is_tor": false, "is_proxy": false, "proxy_provider_names": [], "proxy_confidence_score": 0, "proxy_last_seen": "", "is_residential_proxy": false, "is_vpn": true, "vpn_provider_names": ["SurfShark VPN"], "vpn_confidence_score": 75, "vpn_last_seen": "2026-07-02", "is_relay": false, "relay_provider_name": "", "is_anonymous": true, "is_known_attacker": false, "is_bot": false, "is_spam": false, "is_cloud_provider": false, "cloud_provider_name": "" } } ]curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup?fields=location&include=security' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "223.226.83.58", "8.8.8.8", "217.9.247.116" ] }'
IP Hostname lookup
The Bulk IP Geolocation Lookup API includes hostname lookup capabilities, though this feature is not enabled by default. To enhance your geolocation data with detailed hostname information, use the include query parameter with one of the following options:
- hostname: Retrieves hostname information from the IP-Hostname database. If no hostname is found, the response for that IP will return the queried IP address.
- liveHostname: Fetches the most current hostname information by performing a lookup from live sources.
- hostnameFallbackLive: First attempts a hostname lookup from the IP-Hostname database. If no hostname is found, it then queries live sources to provide the most recent information.
By incorporating these parameters, you can enrich your bulk IP lookups with precise hostname data, enhancing the depth and accuracy of your IP geolocation results.
#Response [ { "ip": "1.1.1.1", "hostname": "one.one.one.one", "location": { "continent_code": "OC", "continent_name": "Oceania", "country_code2": "AU", "country_code3": "AUS", "country_name": "Australia", "country_name_official": "Commonwealth of Australia", "country_capital": "Canberra", "state_prov": "Queensland", "state_code": "AU-QLD", "district": "Brisbane", "city": "South Brisbane", "zipcode": "4101", "latitude": "-27.47301", "longitude": "153.01425", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/au_64.png", "geoname_id": "10113228", "country_emoji": "🇦🇺" } }, { "ip": "8.8.8.8", "hostname": "dns.google", "location": { "continent_code": "NA", "continent_name": "North America", "country_code2": "US", "country_code3": "USA", "country_name": "United States", "country_name_official": "United States of America", "country_capital": "Washington, D.C.", "state_prov": "California", "state_code": "US-CA", "district": "Santa Clara", "city": "Mountain View", "zipcode": "94043-1351", "latitude": "37.42240", "longitude": "-122.08421", "is_eu": false, "country_flag": "https://ipgeolocation.io/static/flags/us_64.png", "geoname_id": "6301403", "country_emoji": "🇺🇸" } } ]curl -X 'POST' 'https://api.apifreaks.com/v2.0/geolocation/lookup?fields=location&include=hostname' -H 'Content-Type: application/json' -H 'X-apiKey: API-KEY' -d '{ "ips": [ "1.1.1.1", "8.8.8.8" ] }'
Pricing
To use the Bulk IP Geolocation Lookup API, API credits are required. Charges apply only for successful queries, defined by a 2xx status code. If a request results in a 4xx or 5xx status code, no credits will be deducted, and any charges incurred will be refunded. Credits are charged based on each IP address specified in your request. If an error occurs with a specific IP address, credits will be refunded for that IP, and you will be charged only for successfully geolocated IP addresses.
| Service | Credits |
|---|---|
| Basic IP Geolocation Data per IP | 2 |
| + IP Security per IP (include=security) | 6 |
| + Abuse Contact per IP (include=abuse) | 6 |
| + IP Security + Abuse per IP (include=security,abuse) | 10 |
| + All Additional Modules (include=*) | 10 |
Utilize the Credits Usage API to efficiently monitor your recent consumption of both one-off and subscription credits. This API provides a streamlined way to track and manage your credit usage, ensuring you stay informed about your remaining balance and can optimize your resource allocation effectively.