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 standard tier, 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: 188.12 MB
  • Entries: 31.1M
  • Fields: 3
  • Last Updated: Yesterday
MMDB
MMDBMMDB
  • File Size: 21.56 MB
  • Entries: 31.1M
  • 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: 188.08 MB
  • Entries: 31.1M
  • 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
164.0.195.172,164.0.195.172,91
165.227.194.83,165.227.194.86,172
183.240.196.54,183.240.196.54,35
114.5.220.8,114.5.220.8,73
88.251.16.23,88.251.16.23,166
73.170.240.82,73.170.240.82,172
41.135.216.13,41.135.216.13,180
16.98.101.9,16.98.101.9,172
138.201.227.176,138.201.227.180,41
65.25.104.21,65.25.104.21,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
221824,Nur-Sultan,Nur-Sultan,Нур-Султан,,,ヌル・スルタン,,Nur-Sultan,努尔苏丹,Nur-Sultán,sultánu,Nur-Sultano
270,Guangdong,Guangdong,Гуандун,,,広東省,,Province de Guangdong,广东,Guangdong,Guangdong,Guangdong
5,Asia,Asien,Азия,Ásia,Ásia,アジア, آسیا,Asie,亚洲,Asia,Asie,Asia
7,Europe,Europa,Европа,Europa,Europa,ヨーロッパ, اروپا,Europe,欧洲,Europa,Evropa,Europa
102273,Pacarkeling,Pacarkeling,Пагаркелинг,,,素晴らしいね,,Pacarkeling,包裹,Pacarkeling,Pacarkeling,Pacarkeling
6,North America,Nordamerika,Северная Америка,América do Norte,América Do Norte,北アメリカ, امریکای شمالی,Amérique du Nord,北美洲,Norteamérica,Severní Amerika,America del Nord
9,Africa,Afrika,Африка,África,África,アフリカ,افریقا,Afrique,非洲,África,Afrika,Africa
12,China,China,Китай,China,China,中国,چین,Chine,中国,China,Čína,Cina
240014,Republic of Turkey,,,,,,,,,,,
28314,Cincinnati,Cincinnati,Цинциннати,Cincinnati,Cincinnati,シンシナティ,سینسینتی، اوهایو,Cincinnati,辛辛那提,Cincinnati,Cincinnati,Cincinnati
913,Jakarta,Jakarta,Джакарта,,,ジャカルタ,,Jakarta,雅加达,Yakarta,Jakarta,Giacarta
240018,United States of America,,,,,,,,,,,
240019,"Washington, D.C.",,,,,,,,,,,
275,Beijing,Peking,Пекин,,,北京,,Municipalité de Pékin,北京,Peking,Peking,Pechino
529,Saxony,Sachsen,Саксония,작센 자유주,,ザクセン州,,Saxe,萨克森,Sachsen,Sasko,Sassonia
240026,Republic of South Africa,,,,,,,,,,,
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,,,,,,,,,,,
31782,North Bergen,Nord Bergen,Северный Берген,,,ノースベルゲン,برگن شمالی، نیوجرسی,Bergen Nord,北卑爾根,Bergenu,Bergenu,Bergen Nord
1270,East Java,Jawa Timur,Восточная Ява,Java Oriental,Java Oriental,東ジャワ州,جاوه شرقی,Java oriental,东爪哇省,Java Oriental,Východní Jáva,Giava Orientale
435,Pavlodar,Pawlodar,Павлодар,Pavlodar,,パヴロダル,,Pavlodar,巴甫洛達爾州,Pavlodar,Pavlodar,Pavlodar
33,Germany,Deutschland,Германия,Alemanha,Alemanha,ドイツ連邦共和国,آلمان,Allemagne,德国,Alemania,Německo,Germania
239906,Federal Republic of Germany,,,,,,,,,,,
6198,Kern County,Kern,Керн,컨 군,Condado de Kern,カーン郡,شهرستان کرن، کالیفرنیا,Comté de Kern,克恩县,Керн,Okres Kern,Contea di Kern
10621,eThekwini Metropolitan Municipality,Metropolregion Ethekwini,Метрополитен-муниципалитет Эеквини,,,エテークウィニ都市圏,,Municipalité métropolitaine d'ethekwini,埃特克威尼市,Metropolitní obec eThekwini,Metropolitní obec eThekwini,Municipalità Metropolitana di EtheKwini
1339,KwaZulu-Natal,KwaZulu-Natal,Квазулу-Наталь,,,クワズールーナタール州,,KwaZulu-Natal,夸祖鲁-纳塔尔,KwaZulu,KwaZulu,KwaZulu-natal
41,Turkey,Türkei,Турция,Turquia,Turquia,トルコ共和国,ترکیه,Turquie,土耳其,Turquía,Turecko,Turchia
577,Ohio,Ohio,Огайо,오하이오 주,,オハイオ州,اوهایو,Ohio,俄亥俄州,Ohio,Ohio,Ohio
562,Berlin,Berlin,Берлин,베를린,Berlim,ベルリン,برلین,Berlin,柏林,Berlín,Berlín,Berlino
144491,Altındağ,Altındağ,Алтындаг,,,アルトゥンダー,,Altındağ,阿尔廷达,Altındağ,Altındau,Altındağ
53,South Africa,Südafrika,ЮАР,África do Sul,África do Sul,南アフリカ,افریقای جنوبی,Afrique du Sud,南非,Sudáfrica,Jihoafrická republika,Africa del Sud
59,Kazakhstan,Kasachstan,Казахстан,Cazaquistão,Casaquistão,カザフスタン共和国,قزاقستان,Kazakhstan,哈萨克斯坦,Kazajstán,Kazachstán,Kazakistan
13883,Pretoria,Pretoria,Претория,Pretória,,プレトリア,,Pretoria,比勒陀利亚,Pretoria,Pretorii,Pretoria
239933,Republic of Indonesia,,,,,,,,,,,
20153,Vogtlandkreis,Vogtlandkreis,Вогтландкрейс,,,ヴォクトランドクリース,,Vogtlandkreis,沃格兰克雷斯,Vogtlandkreis,Vogtlandkreis,Vogtlandkreis
724,Ankara,Ankara,Анкара,Ancara,Ancara,アンカラ,,Ankara,安卡拉省,Provincia de Ankara,Ankara,Ankara
211713,Newlands East,Newlands Ost,Ньюлендс Восток,,,ニューランズ・イースト,,Newlands Est,東紐蘭省,Newlands,Newlands,Newlands Est
28755,Falkenstein,Falkenstein,Фалькенштайн,,,ファルケンシュタインだ,,Falkenstein,法尔肯斯坦,Falkenstein,Falkenstein,Falkenstein
239947,Republic of Kazakhstan,,,,,,,,,,,
8131,Wasco,Wasco,Уаско,,Condado de Wasco,ワスコ郡,شهرستان واسکو، اورگن,Comté de Wasco,沃斯科縣,Wasco,Wasco,Wasco
724,Ankara,Ankara,Анкара,Ancara,Ancara,アンカラ,,Ankara,安卡拉省,Provincia de Ankara,Ankara,Ankara
297,New Jersey,New Jersey,Нью-Джерси,Nova Jérsia,Nova Jérsia,ニュージャージー州,نیو جرسی,New Jersey,新泽西州,Nueva Jersey,New Jersey,New Jersey
5697,Hudson County,Hudson,Хадсон,,Condado de Hudson,ハドソン郡,شهرستان هادسون، نیوجرسی,Comté de Hudson,哈德遜縣,Хадсон,Hudson County,Contea di Hudson
5751,Hamilton County,Hamilton,Гамильтон,,Condado de Hamilton,ハミルトン郡,شهرستان همیلتون، اوهایو,Comté de Hamilton,漢密爾頓縣,Гамильтон,Hamilton County (Kansas),Contea di Hamilton
4754,Shenzhen,Shenzhen,Шэньчжэнь,Shenzhen,,深セン市,شنژن,Shenzhen,深圳市,Shenzhen,Shenzhen,Shenzhen
751,San Jose,San José,Сан-Хосе,,,サンノゼ,,San José,聖荷西聖荷西,San José,San José,San Francisco
17186,Surabaya,Surabaya,Сурабая,Surabaia,,スラバヤ,,Surabaya,泗水,Surabaya,Surabaya,Surabaya
4560,Santa Clara County,Santa Clara County,Санта-Клара,샌타클래라 군,Condado de Santa Clara,サンタクララ郡,شهرستان سانتا کلارا، کالیفرنیا,Comté de Santa Clara,聖塔克拉拉縣,Санта-Клара,Santa Clara County (Texas),Contea di Santa Clara
122,Indonesia,Indonesien,Индонезия,Indonésia,Indonésia,インドネシア共和国,اندونزی,Indonésie,印度尼西亚,Indonesia,Indonésie,Indonesia
362,California,Kalifornien,Калифорния,Califórnia,Califórnia,カリフォルニアだ,کالیفرنیا,Californie,加州,California,Kalifornie,California

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
166,AS,5,TR,TUR,TUR,41,240014,724,TRY,Turkish Lira,,+90,.tr,"tr-TR,ku,diq,az,av"
91,AS,5,KZ,KAZ,KAZ,59,239947,221824,KZT,Tenge,,+7,.kz,"kk,ru"
73,AS,5,ID,IDN,INA,122,239933,913,IDR,Indonesian Rupiah,Rp,+62,.id,"id,en,nl,jv"
41,EU,7,DE,DEU,GER,33,239906,562,EUR,Euro,,+49,.de,de
172,NA,6,US,USA,USA,28,240018,240019,USD,US Dollar,$,+1,.us,"en-US,es-US,haw,fr"
180,AF,9,ZA,ZAF,RSA,53,240026,13883,ZAR,Rand,R,+27,.za,"zu,xh,af,nso,en-ZA,tn,st,ts,ss,ve,nr"
35,AS,5,CN,CHN,CHN,12,239901,275,CNY,Yuan Renminbi,¥,+86,.cn,"zh-CN,yue,wuu,dta,ug,za"

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: 21.55 MB
  • Entries: 31.1M
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": "sultánu",
        "de": "Nur-Sultan",
        "en": "Nur-Sultan",
        "es": "Nur-Sultán",
        "fa": "",
        "fr": "Nur-Sultan",
        "it": "Nur-Sultano",
        "ja": "ヌル・スルタン",
        "ko": "",
        "pt": "",
        "ru": "Нур-Султан",
        "zh": "努尔苏丹"
      },
      "code2": "KZ",
      "code3": "KAZ",
      "code_ioc": "KAZ",
      "continent": {
        "code": "AS",
        "name": {
          "cs": "Asie",
          "de": "Asien",
          "en": "Asia",
          "es": "Asia",
          "fa": " آسیا",
          "fr": "Asie",
          "it": "Asia",
          "ja": "アジア",
          "ko": "Ásia",
          "pt": "Ásia",
          "ru": "Азия",
          "zh": "亚洲"
        }
      },
      "currency": {
        "code": "KZT",
        "name": {
          "en": "Tenge"
        },
        "symbol": "₸"
      },
      "metadata": {
        "calling_code": "+7",
        "languages": "kk,ru",
        "tld": ".kz"
      },
      "name": {
        "cs": "Kazachstán",
        "de": "Kasachstan",
        "en": "Kazakhstan",
        "es": "Kazajstán",
        "fa": "قزاقستان",
        "fr": "Kazakhstan",
        "it": "Kazakistan",
        "ja": "カザフスタン共和国",
        "ko": "Cazaquistão",
        "pt": "Casaquistão",
        "ru": "Казахстан",
        "zh": "哈萨克斯坦"
      },
      "name_official": {
        "cs": "",
        "de": "",
        "en": "Republic of Kazakhstan",
        "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 refreshed daily and weekly, 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.