IP Country Database


Overview

Ever wonder what country a specific IP address comes from? Our IP to Country Database which is a part of our Geo Standard, helps you figure that out for any IPv4 or IPv6 address. We've packed it with all the details you'd want, not just the country name, but ISO codes, the continent, capital, dialing codes, currencies, languages, and TLDs. It even supports multiple languages, so you can get localized results right away, no extra steps needed.

We're pretty committed to having the most up-to-date information, which is why our databases are updated daily so that you're always working with the latest changes. We also make sure that the files are super light and easy to use. You can literally just drop them into your systems without a fuss.

You'll find everything you need to know in our documentation. We walk you through what's in the archives, the file structure, how to verify your downloads before you import them, just to be safe, and we’ve also included a few examples.


Available Database Formats

CSV
CSVCSV
  • File Size: 241.38 MB
  • Entries: 41.0M
  • Fields: 3
  • Last Updated: Today
MMDB
MMDBMMDB
  • File Size: 23.47 MB
  • Entries: 41.0M
  • Fields: 3
  • Last Updated: Today

CSV Database Documentation


1. Overview

The CSV version is delivered as a ZIP archive that includes Gzip-compressed files with IP ranges, location details, and multilingual place names. It’s well-suited for bulk imports and easy integration into relational databases.


2. Archive Content

After downloading and extracting the IP to Country CSV database archive, you'll find the following files (with their types noted):

db-country.csv.gz
db-country.csv.gzdb-country.csv.gz

Standardized country and continent metadata with codes, currency, calling codes, TLDs, and languages.

  • File Size: 9.67 KB
  • Entries: 254
  • Fields: 15
db-place.csv.gz
db-place.csv.gzdb-place.csv.gz

Multilingual place names for cities, districts, states, countries, and continents.

  • File Size: 32.36 KB
  • Entries: 690
  • Fields: 13
db-ip-country.csv.gz
db-ip-country.csv.gzdb-ip-country.csv.gz

IP ranges mapping to country IDs for linking each address block with standardized country details and metadata.

  • File Size: 241.34 MB
  • Entries: 41.0M
  • Fields: 3
README.md
README.mdREADME.md

Documentation for dataset contents, schema, usage, and support.

  • File Size: 8.00 KB
checksum.txt
checksum.txtchecksum.txt

SHA-256 checksums for verifying file integrity.

  • File Size: 329 Bytes

Schema

This section describes the schema of each file included in the IP to Country Database archive. For every file, you'll find its purpose, field definitions, and examples to help with integration.


1. db-ip-country.csv.gz

This file contains standardized country and continent details and metadata. It includes various codes (ISO-2/ISO-3/IOC), place IDs for names and capitals, currency details, international calling codes, top-level domains (TLDs), and language tags.

FieldTypeDescriptionCan be empty?Example
start_ipstringThe starting IP address of the range in IPv4 or IPv6 format.No192.168.0.1
end_ipstringThe ending IP address of the range in IPv4 or IPv6 format.No192.168.0.255
country_idnumberThe unique identifier for the country associated with the IP range.No192

I. Example Records

Example
start_ip,end_ip,country_id
72.78.171.5,72.78.171.5,172
87.0.171.170,87.0.171.170,80
188.36.125.202,188.36.125.202,72
14.19.59.73,14.19.59.73,35
69.70.85.229,69.70.85.229,29
77.103.140.7,77.103.140.7,58
5.246.176.27,5.246.176.27,143
2601:2c5:4485:d050:146:f651:45e4:26b4,2601:2c5:4485:d050:146:f651:45e4:26b4,172
85.108.232.6,85.108.232.6,166
199.187.181.28,199.187.181.28,172

2. db-place.csv.gz

This file contains multilingual names for countries, continents, states, districts, and cities worldwide. It serves as the reference dictionary for the IP Location Database, allowing you to resolve place IDs into multilingual responses across different regions and languages.

FieldTypeDescriptionCan be empty?Example
idnumberThe unique identifier for the place.No5375480
place_englishstringThe name of the place in English.NoMountain View
place_germanstringThe name of the place in German.YesMountain View
place_russianstringThe name of the place in Russian.YesМаунтин-Вью
place_koreanstringThe name of the place in Korean.Yes마운틴 뷰
place_portuguesestringThe name of the place in Portuguese.YesMountain View
place_japanesestringThe name of the place in Japanese.Yesマウンテンビュー
place_persianstringThe name of the place in Farsi.Yesماونتین ویو
place_frenchstringThe name of the place in French.YesMountain View
place_chinesestringThe name of the place in Chinese.Yes山景城
place_spanishstringThe name of the place in Spanish.YesMountain View
place_czechstringThe name of the place in Czech.YesMountain View
place_italianstringThe name of the place in Italian.YesMountain View

I. Example Records

Example
id,place_english,place_german,place_russian,place_korean,place_portuguese,place_japanese,place_persian,place_french,place_chinese,place_spanish,place_czech,place_italian
447,Eastern Province,Ostprovinz,Восточная провинция,,,東部州(東部),,Province de l'Est,东部省,Východní provincie,Východní provincie,Provincia Orientale
24142,Dammam,Dammam,Даммам,Dammam,Dammam,ダンマーム,دمام,Dammam,达曼,Dammam,Dammam,Dammam
5,Asia,Asien,Азия,Ásia,Ásia,アジア, آسیا,Asie,亚洲,Asia,Asie,Asia
560,Turin,Turin,Турин,Turim,Turim,トリノ,,Turin,都灵,Turín,Turín,Torino
6,North America,Nordamerika,Северная Америка,América do Norte,América Do Norte,北アメリカ, امریکای شمالی,Amérique du Nord,北美洲,Norteamérica,Severní Amerika,America del Nord
7,Europe,Europa,Европа,Europa,Europa,ヨーロッパ, اروپا,Europe,欧洲,Europa,Evropa,Europa
12,China,China,Китай,China,China,中国,چین,Chine,中国,China,Čína,Cina
240014,Republic of Turkey,,,,,,,,,,,
784,Budapest,Budapest,Будапешт,부다페스트,,ブダペスト,,Budapest,布达佩斯,Budapešť,Budapešť,Budapest
5397,Laval,Laval,Лаваль,Laval,,ラヴァル,,Laval,拉瓦勒,Laval,Laval,Laval
240018,United States of America,,,,,,,,,,,
275,Beijing,Peking,Пекин,,,北京,,Municipalité de Pékin,北京,Peking,Peking,Pechino
240019,"Washington, D.C.",,,,,,,,,,,
28,United States,USA,США,Estados Unidos,Estados Unidos,アメリカ合衆国,ایالات متحدهٔ امریکا,États-Unis,美国,Estados Unidos,Spojené státy americké,Stati Uniti d'America
239901,People’s Republic of China,,,,,,,,,,,
1462,Tekirdag,Tekirdağ,Текирдаг,테키르다 주,,テキルダー県,استان تکیرداغ,Tekirdağ,泰基尔达省,Tekirdag,Tekirdag,Tekirdag
35,Italy,Italien,Италия,Itália,Itália,イタリア共和国,ایتالیا,Italie,意大利,Italia,Itálie,Italia
36,United Kingdom,Vereinigtes Königreich,Великобритания,Reino Unido,Reino Unido,イギリス,بریتانیا,Royaume-Uni,英国,Reino Unido,Spojené království Velké Británie a Severního Irska,Regno Unito
4360,Philadelphia,Philadelphia,Филадельфия,필라델피아 군,,フィラデルフィア郡,,Comté de Philadelphie,費城縣,Filadelfie,Filadelfie,Filadelfia
41,Turkey,Türkei,Турция,Turquia,Turquia,トルコ共和国,ترکیه,Turquie,土耳其,Turquía,Turecko,Turchia
2091,Riyadh,Riad,Эр-Рияд,Riade,Riade,リヤド,ریاض,Riyad,利雅德,Riad,Rijád,Riad
413,Piedmont,Piemont,Пьемонт,피에몬테 주,,ピエモンテ州,پیمونت,Piémont,皮埃蒙特,Piamonte,V Piemontu,Piemonte
239922,United Kingdom of Great Britain and Northern Ireland,,,,,,,,,,,
4487,Houston,Houston,Хьюстон,,Condado de Houston,ヒューストン郡,شهرستان هیوستون، آلاباما,Comté de Houston,休斯敦县,Z Houstonu,Z Houstonu,Houston
143812,Çorlu,Çorlu,Чорлу,,,チョルル,,Çorlu,乔卢,Çorlu,Çorlu,Corlu
9334,Corlu,Corlu,Корлу,,,コール,,Corlu,柯卢,Corlu,Corlu,Corlu
373,Texas,Texas,Техас,텍사스 주,,テキサス州,تگزاس,Texas,德克萨斯州,Texas,Texas,Texas
240079,Dammam Principality,,,,,,,,,,,
4500,Jackson County,Jackson,Джексон,,Condado de Jackson,ジャクソン郡,شهرستان جکسون، اورگن,Comté de Jackson,傑克遜縣,Джексон,Jackson County (Texas),Contea di Jackson
60,Saudi Arabia,Saudi-Arabien,Саудовская Аравия,Arábia Saudita,Arábia Saudita,サウジアラビア王国,عربستان سعودی,Arabie saoudite,沙特阿拉伯,Arabia Saudí,Saúdská Arábie,Arabia Saudita
65,Canada,Kanada,Канада,Canadá,Canadá,カナダ,کانادا,Canada,加拿大,Canadá,Kanada,Canada
239939,Republic of Italy,,,,,,,,,,,
598,Quebec,Quebec,Квебек,Quebeque,Quebeque,ケベック州,,Québec,魁北克省,Quebec,Quebec,Quebec
23827,Guangzhou,Guangzhou,Гуанчжоу,Cantão,Cantão,広州,گوانگ‌ژو,Canton,广州,Cantón,Kanton,Canton
270,Guangdong,Guangdong,Гуандун,,,広東省,,Province de Guangdong,广东,Guangdong,Guangdong,Guangdong
724,Ankara,Ankara,Анкара,Ancara,Ancara,アンカラ,,Ankara,安卡拉省,Provincia de Ankara,Ankara,Ankara
381,Pennsylvania,Pennsylvania,Пенсильвания,Pensilvânia,Pensilvânia,ペンシルベニア州,پنسیلوانیا,Pennsylvanie,宾夕法尼亚州,Pensilvania,Pensylvánie,Pennsylvania
43774,Torquay,Torquay,Торки,토키,,トーキー,تورکی,Torquay,托基,Torquay,Torquay,Torquay
599,Oregon,Oregon,Орегон,Oregão,Oregão,オレゴン州,اورگن,Oregon,俄勒冈州,Oregón,Oregon,Oregon
240077,Provincia di Torino,,,,,,,,,,,
784,Budapest,Budapest,Будапешт,부다페스트,,ブダペスト,,Budapest,布达佩斯,Budapešť,Budapešť,Budapest
7493,Ashland,Ashland,Ашленд,,Condado de Ashland,アシュランド,شهرستان اشلند، ویسکانسین,Comté dAshland,阿什兰,Ashland,Ashland,Ashland
240078,Borough of Torbay,,,,,,,,,,,
4525,Harris County,Harris,Харрис,,Condado de Harris,ハリス郡,شهرستان هریس، تگزاس,Comté de Harris,哈里斯縣,Харрис,Harris County (Texas),Contea di Harris
107,Hungary,Ungarn,Венгрия,Hungria,Hungria,ハンガリー共和国,مجارستان,Hongrie,匈牙利,Hungría,Maďarsko,Ungheria
4588,Ottawa,Ottawa,Оттава,Otava,Condado de Ottawa,オタワ,شهرستان اتاوا، اکلاهما,Ottawa,渥太華縣,Ottawa,Ottawa,Ottawa
3952,Rome,Rom,Рим,,,ローマ,,Rome,罗马,Roma,Řím,Roma
360,England,England,Англия,Inglaterra,Inglaterra,イングランド,انگلستان,Angleterre,英格兰,Inglaterra,Anglie,Inghilterra
1650,London,London,Лондон,London,,ロンドン,,London,伦敦,London,Londýn,Londra
239994,Kingdom of Saudi Arabia,,,,,,,,,,,

3. db-country.csv.gz

This file contains standardized country metadata for the IP Location Database. It includes continent codes and names, ISO-2/ISO-3/IOC country codes, country and official names (as place IDs), capital (place ID), currency (code, name, symbol), international calling codes, top-level domains (TLDs), and supported language tags.

FieldTypeDescriptionCan be empty?Example
idnumberThe unique identifier for the country.No192
continent_codestringThe continent code associated with the country.NoNA
continent_name_place_idnumberThe unique identifier for the continent place.No6255148
country_code2stringThe ISO 3166-1 alpha-2 code of the country.NoUS
country_code3stringThe ISO 3166-1 alpha-3 code of the country.NoUSA
country_code_iocstringThe IOC country code.NoUSA
country_name_place_idnumberThe unique identifier for the country place.No6252001
country_name_official_place_idnumberThe unique identifier for the official country place.No6252001
country_capital_place_idnumberThe unique identifier for the capital place.No5375480
currency_codestringThe ISO 4217 currency code of the country.NoUSD
currency_namestringThe name of the currency used in the country.NoUnited States Dollar
currency_symbolstringThe symbol of the currency used in the country.No$
calling_codestringThe international calling code of the country.No+1
tldstringThe top-level domain (TLD) of the country.No.us
languagesstringThe official languages spoken in the country, represented as a comma-separated list of ISO 639-1 codes.Noen,es

I. Example Records

Example
id,continent_code,continent_name_place_id,country_code2,country_code3,country_code_ioc,country_name_place_id,country_name_official_place_id,country_capital_place_id,currency_code,currency_name,currency_symbol,calling_code,tld,languages
29,NA,6,CA,CAN,CAN,65,65,4588,CAD,Canadian Dollar,C$,+1,.ca,"en-CA,fr-CA,iu"
58,EU,7,GB,GBR,GBR,36,239922,1650,GBP,Pound Sterling,£,+44,.uk,"en-GB,cy-GB,gd"
143,AS,5,SA,SAU,KSA,60,239994,2091,SAR,Saudi Riyal,,+966,.sa,ar-SA
166,AS,5,TR,TUR,TUR,41,240014,724,TRY,Turkish Lira,,+90,.tr,"tr-TR,ku,diq,az,av"
72,EU,7,HU,HUN,HUN,107,107,784,HUF,Forint,Ft,+36,.hu,hu-HU
80,EU,7,IT,ITA,ITA,35,239939,3952,EUR,Euro,,+39,.it,"it-IT,de-IT,fr-IT,sc,ca,co,sl"
35,AS,5,CN,CHN,CHN,12,239901,275,CNY,Yuan Renminbi,¥,+86,.cn,"zh-CN,yue,wuu,dta,ug,za"
172,NA,6,US,USA,USA,28,240018,240019,USD,US Dollar,$,+1,.us,"en-US,es-US,haw,fr"

4. File Relationship Diagram

The diagram below illustrates the relationships between the various files included in the CSV database package. It shows how the main CSV file connects to reference tables for countries, states, districts, and cities, ensuring consistent and accurate geolocation data across different regions and languages.

Image

File Format & Encoding

All IP to Country CSV datasets are provided in UTF-8 encoding, comma-separated, and compressed with Gzip (.csv.gz). Each file includes a header row listing the field names for clarity and consistency.

Field values are unquoted by default, with quotes applied only in the following cases:

  • Line breaks within text fields.
  • Commas inside a value (e.g., addresses).
  • Lists of values (e.g., languages).
  • Spaces that may be auto-quoted by export tools.

MMDB Database Documentation


1. Overview

The MMDB version of our IP to Country is delivered as a ZIP archive that includes a single MMDB file with all geolocation data (including multilingual place fields), a README file, and a checksum file. It's optimized for fast lookups in applications and services, making it ideal for real-time queries and direct integration into your systems.


2. Archive Content

After downloading and extracting the IP to Country MMDB database archive, you'll find the following files (with their types noted):

db-ip-country.mmdb
db-ip-country.mmdbdb-ip-country.mmdb

Country-level geolocation database with IP ranges, multilingual country names, codes, capital, currency, languages, and related metadata.

  • File Size: 23.46 MB
  • Entries: 41.0M
README.md
README.mdREADME.md

Documentation for dataset contents, schema, usage, and support.

  • File Size: 8.48 KB
checksum.txt
checksum.txtchecksum.txt

SHA-256 checksums for verifying file integrity.

  • File Size: 161 Bytes

Response Schema

This section describes the structure of the data returned from the IP to Country MMDB file. Each field is detailed with its type, meaning, and example values to help you interpret responses and integrate them into your applications.


1. db-ip-country.mmdb

This file contains standardized country and continent details. It includes multilingual country and capital names, ISO codes (ISO-2/ISO-3/IOC), currency details, international calling codes, top-level domains (TLDs), and language tags.


2. Field Reference

The following reference lists all fields available in the MMDB response. Each entry includes the field path, its description, data type, and example value to help you understand how to parse and integrate the data.

Showing 0 of 18
Select a field to view details

I. Example Records

Example
{
  "location": {
    "country": {
      "capital": {
        "cs": "",
        "de": "",
        "en": "Washington, D.C.",
        "es": "",
        "fa": "",
        "fr": "",
        "it": "",
        "ja": "",
        "ko": "",
        "pt": "",
        "ru": "",
        "zh": ""
      },
      "code2": "US",
      "code3": "USA",
      "code_ioc": "USA",
      "continent": {
        "code": "NA",
        "name": {
          "cs": "Severní Amerika",
          "de": "Nordamerika",
          "en": "North America",
          "es": "Norteamérica",
          "fa": " امریکای شمالی",
          "fr": "Amérique du Nord",
          "it": "America del Nord",
          "ja": "北アメリカ",
          "ko": "América do Norte",
          "pt": "América Do Norte",
          "ru": "Северная Америка",
          "zh": "北美洲"
        }
      },
      "currency": {
        "code": "USD",
        "name": {
          "en": "US Dollar"
        },
        "symbol": "$"
      },
      "metadata": {
        "calling_code": "+1",
        "languages": "en-US,es-US,haw,fr",
        "tld": ".us"
      },
      "name": {
        "cs": "Spojené státy americké",
        "de": "USA",
        "en": "United States",
        "es": "Estados Unidos",
        "fa": "ایالات متحدهٔ امریکا",
        "fr": "États-Unis",
        "it": "Stati Uniti d'America",
        "ja": "アメリカ合衆国",
        "ko": "Estados Unidos",
        "pt": "Estados Unidos",
        "ru": "США",
        "zh": "美国"
      },
      "name_official": {
        "cs": "",
        "de": "",
        "en": "United States of America",
        "es": "",
        "fa": "",
        "fr": "",
        "it": "",
        "ja": "",
        "ko": "",
        "pt": "",
        "ru": "",
        "zh": ""
      }
    }
  }
}

Database Integrity & Authenticity Verification

There are two methods of verifying the integrity and authenticity of our Database:


1. Using the Signature File (Recommended)

IPGeolocation.io signs every database release to ensure its authenticity and integrity. This allows customers to verify that a downloaded IP to Country database file originates directly from IPGeolocation.io and has not been altered, corrupted, or tampered with during transfer or storage.

Each database update includes a corresponding signature file, generated using our private signing key. Customers can validate the database using the provided public verification key. To verify a database file, you need:

  1. Database file (the downloaded archive)
  2. Signature file (the matching signature for that archive)
  3. Public key (public-key.pem)

These files are available via official IPGeolocation.io download endpoints and are also shared in database update notifications.


2. Using the Checksum File (Legacy)

Each database archive includes a checksum.txt file containing the SHA-256 checksums for the files packaged in the archive. You can use this file to validate that the extracted contents are complete and unchanged.


Data Format & Constraints

  • All fields defined in the schema are always present in the IP to Country MMDB response.
  • Fields may contain empty strings (""), but never null, so null checks are not required.
  • Place names such as countries, states, districts, and cities are available in multiple translations.
  • All text values are encoded in UTF-8.
  • Field names and response structure remain stable across updates for backward compatibility.

Database Updates & Delivery

When you subscribe to our IP to Country database, we'll send you static download links. These links never change, so you can use them both for your initial download and for all future updates. You will receive:

  1. Database Archive URL : downloads the latest release of your subscribed database (CSV, MMDB or requested formats).
  2. Signature File URL : downloads the matching signature file for the latest release (used for authenticity verification).
  3. Public Key URL : downloads the public verification key (used with the signature file).
  4. Status Endpoint URL : returns the database's most recent update timestamp.

Our databases are updated continuously and shipped on a daily or weekly cycle depending on your plan, ensuring you always have access to the most current data. Each time your subscribed dataset is updated, you'll also receive an email notification so you don't miss a release.

For automated workflows, you can check our status endpoint to see the last update timestamp. When the date changes, simply re-fetch the archive using your static download URL to pull the latest version into your system.

Subscribe to Our Newsletter

Get the latest in geolocation tech, straight to your inbox.