IPv4 geolocation

2,150
0
Updated:
Files:1
Size:31.9 MB
Formats:csv
License:odc-pddl

Database of IPv4 address networks with their respective geographical location. Based on GeoLite2 Country Free Downloadable Databases as of Apr 21, 2015 http://dev.maxmind.com/geoip/geoip2/geolite2/...

API Access

Access dataset files directly from scripts, code, or AI agents.

Browse dataset files
Dataset Files

Each file has a stable URL (r-link) that you can use directly in scripts, apps, or AI agents. These URLs are permanent and safe to hardcode.

/core/geoip2-ipv4/
https://datahub.io/core/geoip2-ipv4/_r/-/LICENSE
https://datahub.io/core/geoip2-ipv4/_r/-/README.md
https://datahub.io/core/geoip2-ipv4/_r/-/data/geoip2-ipv4.csv
https://datahub.io/core/geoip2-ipv4/_r/-/datapackage.json
Key Files

Start with these files — they give you everything you need to understand and access the dataset.

datapackage.jsonmetadata & schema
https://datahub.io/core/geoip2-ipv4/_r/-/datapackage.json
README.mddocumentation
https://datahub.io/core/geoip2-ipv4/_r/-/README.md
Typical Usage
  1. 1. Fetch datapackage.json to inspect schema and resources
  2. 2. Download data resources listed in datapackage.json
  3. 3. Read README.md for full context

Data Files

Explore with AI

geoip2-ipv4

Loading data...

Download

Download CSV

About

Last updated
3 May 2026
Total rows
...
Format
CSV
File size
31.9 MB

About this dataset

badge

Database of IPv4 address networks with their respective geographical location.

Data

Based on GeoLite2 Country Free Downloadable Databases as of Apr 21, 2015 http://dev.maxmind.com/geoip/geoip2/geolite2/

Two files were used to generate this dataset:

GeoLite2-Country-Blocks-IPv4.csv  
GeoLite2-Country-Locations-en.csv  

with the following considerations:

  • Where geoname_id was not available, registered_country_geoname_id was used.
  • Where geoname_id and registered_country_geoname_id where empty, geoname_id, continent_code, continent_name, country_iso_code and country_name are empty.

Preparation

Process is recorded and automated in python script:

# Install the requirements
pip install -r scripts/requirements.txt

# Make sure to add your own Account_ID and License_key password as env variables
username = os.getenv('MAXMIND_USERNAME')
password = os.getenv('MAXMIND_PASSWORD')

# Run the code 
python scripts/process.py

Automation

Up-to-date (auto-updates every week) geoip2-ipv4 dataset could be found on the datahub.io: https://datahub.io/core/geoip2-ipv4

License

Datapackage: Creative Commons Zero

Original CSV: This dataset includes GeoLite2 data created by MaxMind, available from www.maxmind.com