← All datasets

Countries

196 countries with their ISO 3166-1 alpha-2 and alpha-3 codes, capital, continent, population, land area, nominal GDP, currency, international calling code, official languages, driving side, internet country-code top-level domain, flag emoji and centroid coordinates, every value drawn from Wikidata's best-rank statements. Two columns are derived for modeling: population density (people per square kilometre) and GDP per capita in US dollars. The spreads are large enough to demand log scales: GDP per capita runs from a few hundred dollars to Monaco and Luxembourg above one hundred thousand, and density from barely two people per square kilometre in Mongolia and Namibia to tens of thousands in Monaco and Singapore. Wikidata stores official languages as each state defines them, so a few countries list regional languages rather than one national language. A clean reference table for country codes, currencies, capitals and calling codes, free as a CSV download. Nine acceptance tests, one enforcing the 25 percent fill rule on every column.
196 rows 1 file last pulled 2026-10-22
Where would you start?
Pick a question, or ask your own and answer it; publish what you find as an insight. The same question can carry many insights from different angles.
  • Which countries pack the most neighbors per border kilometer?
  • How does GDP per capita relate to internet penetration across countries?
  • Which currencies serve the most countries?
Countries 196 rows × 20 columns
CountryCountry_IDISO2ISO3CapitalContinentPopulationArea_km2Population_DensityGDP_USDGDP_Per_Capita_USDCurrencyCalling_CodeOfficial_LanguagesDriving_SideInternet_TLDFlag_EmojiLatitudeLongitudeCountry_URL

Questions and answers

What is the Countries dataset?

196 countries with their ISO 3166-1 alpha-2 and alpha-3 codes, capital, continent, population, land area, nominal GDP, currency, international calling code, official languages, driving side, internet country-code top-level domain, flag emoji and centroid coordinates, every value drawn from Wikidata's best-rank statements. Two columns are derived for modeling: population density (people per square kilometre) and GDP per capita in US dollars. The spreads are large enough to demand log scales: GDP per capita runs from a few hundred dollars to Monaco and Luxembourg above one hundred thousand, and density from barely two people per square kilometre in Mongolia and Namibia to tens of thousands in Monaco and Singapore. Wikidata stores official languages as each state defines them, so a few countries list regional languages rather than one national language. A clean reference table for country codes, currencies, capitals and calling codes, free as a CSV download. Nine acceptance tests, one enforcing the 25 percent fill rule on every column.

How big is the Countries dataset?

196 rows in one CSV file, with 20 columns in total: Country, Country_ID, ISO2, ISO3, Capital, Continent, Population, Area_km2, Population_Density, GDP_USD, GDP_Per_Capita_USD, Currency, Calling_Code, Official_Languages, Driving_Side, Internet_TLD, Flag_Emoji, Latitude, Longitude, Country_URL.

Where does the data come from?

It is built by programmatically scraping wikidata.org, last pulled on 2026-10-22. Datasets are versioned; older versions stay downloadable.

Is the dataset free to download?

Yes. Every CodeSights dataset is completely free as a CSV download; a free account is all it takes. Anyone can preview the data without signing in.

Can I see the code that built this dataset?

Yes. The exact Python scraper that built it is viewable on the dataset page by any signed-in member, so every number is reproducible.

Can the data contain errors?

Automated scraping leaves room for error and the underlying sources change over time, so no version is guaranteed accurate or complete. If a number matters, verify it against the original source.

Browse every free dataset on CodeSights