Open data
Where to find reliable public data for your spreadsheets
Public data sources worth trusting for spreadsheets, what each covers, how it is licensed, how to pull it into a sheet, check gaps and cite it properly.
Start with the agency that collects or compiles the numbers, not with a website that redraws its chart. For country-by-year indicators that is usually the World Bank; for weather and solar data it is NASA POWER; for boundaries and codes it is Natural Earth; for US figures it is the Census Bureau, the Bureau of Labor Statistics (BLS) or the St. Louis Fed's FRED. Whatever you choose, check three things before the first chart: the license, the years and places the data really covers, and the exact definition and unit of each column.
The main sources at a glance
| Source | Good for | How to get it | Reuse terms |
|---|---|---|---|
| World Bank World Development Indicators (WDI) | Country-year indicators: GDP, population, water, energy, many back to 1960 | API v2, DataBank, CSV download | CC BY 4.0 for most indicators; the license is listed in each indicator's metadata |
| FAO AQUASTAT | Water resources and withdrawals by sector, irrigation | FAO web database; also through WDI | CC BY 4.0 with additional FAO terms |
| NASA POWER | Gridded daily and monthly weather and solar data for any coordinates | REST API (JSON, CSV) | Open; NASA asks for an acknowledgment |
| Natural Earth | Country boundaries, populated places, ISO codes | Shapefile, GeoJSON, attribute tables | Public domain |
| OECD | Economy, labor, tax, education for member and partner countries | OECD Data Explorer, SDMX API, CSV | OECD terms of use; read them per dataset |
| Eurostat | Harmonized EU statistics | Bulk TSV files, JSON-stat API | Free reuse with source acknowledgment |
| UN Data | Tables compiled from UN agencies | CSV downloads | Varies by contributing agency |
| US Census Bureau, BLS | Population, income, jobs, prices | Web APIs, CSV | Federal works; cite the agency |
| FRED | Economic time series from many publishers | CSV by URL, API key | Varies by series; each page names the source |
| Our World in Data | Long-run indicators across many topics | CSV download per chart | CC BY 4.0 for its own work; underlying sources keep their terms |
Notes on the sources that need care
World Bank and AQUASTAT. WDI is the easiest place to start because every indicator has a code, a definition, a unit, a source and a license in one place. Some of its series are passed through from other agencies: the freshwater withdrawal indicators (ER.H2O.FWTL.K3 and its relatives) come from FAO AQUASTAT, which relies on national surveys and reports. FAO states that data in its statistical databases are licensed under CC BY 4.0 with additional terms, including that you may not imply FAO endorses your product. Cite both the World Bank and FAO.
NASA POWER. POWER is model-based: it combines satellite observations with reanalysis such as MERRA-2 on a grid, so a value is an estimate for a grid cell, not a reading from a weather station. Missing values are returned as -999, which will wreck an average if you leave it in. Precipitation arrives as mm/day, a daily average for the month, so multiply by the number of days to get a monthly total. The monthly response also carries a thirteenth period per year (202513) holding the annual figure; do not sum it with the twelve months.
Natural Earth. Public domain, no credit required, though "Made with Natural Earth" is the courteous line. Its country file has several scales (1:10 million, 1:50 million, 1:110 million); pick one and stay with it. In some versions the ISO_A3 field holds -99 for a few countries, so join on ISO_A3_EH or ADM0_A3 instead.
OECD, Eurostat and UN Data. These cover richer comparisons for developed economies and Europe. Eurostat's bulk TSV files put several dimensions into the first header cell, separated by commas, and add flag letters to values (p provisional, e estimated) and : for missing data. All three vary by dataset, so read the terms on the page you download from.
US agencies. Census, BLS and FRED have free APIs. American Community Survey estimates come with margins of error; download the margin column along with the estimate. FRED republishes series from other organizations, and some carry the owner's copyright.
Our World in Data. It compiles and cleans data from the sources above and others, which is convenient, but it is a second hand: cite Our World in Data and the original source it names.
Pull the data into a sheet
For a one-off, download the CSV and open it through the import dialog, not a double-click, so you control delimiters and column types (open CSV in Excel without breaking data). WDI's bulk CSV is wide, with one column per year and a few preamble lines above the header row. The API returns long format, one row per country and year, which is easier to filter and pivot.
For data that updates, fetch from a URL:
- World Bank API:
https://api.worldbank.org/v2/country/all/indicator/NY.GDP.MKTP.CD?format=json&per_page=20000&date=1990:2024. The response is a two-item JSON array: paging information, then the records, each withcountryiso3code,dateandvalue.per_pagedefaults to 50, so raise it or page through the results. - FRED:
https://fred.stlouisfed.org/graph/fredgraph.csv?id=UNRATEreturns a CSV that a spreadsheet can read directly. - Our World in Data: add
.csvto a chart's address. - Census:
https://api.census.gov/data/2022/acs/acs5?get=NAME,B01003_001E&for=state:*returns total population by state. - NASA POWER:
https://power.larc.nasa.gov/api/temporal/monthly/point?parameters=T2M,PRECTOTCORR&community=AG&longitude=-0.13&latitude=51.51&start=2024&end=2025&format=CSV
Google Sheets reads CSV addresses with =IMPORTDATA("url"). Excel uses Data, Get Data, From Web. LibreOffice uses Sheet, Link to External Data. JSON usually needs Power Query in Excel or a small script. Once the numbers are in, convert them to values and keep a dated copy so your analysis does not shift when the source revises.
Check coverage before you trust the data
Coverage problems are quiet. Four checks catch most of them.
Separate countries from aggregates. WDI mixes economies with regions and income groups ("World", "High income"). On October 8, 2026 the World Bank country list returned 296 entries, 79 of them aggregates. Download the country list, filter out rows whose region is "Aggregates", and join on the three-letter ISO code rather than the name, because names differ between sources ("Türkiye" and "Turkey", "Korea, Rep." and "South Korea").
Count the years. Put years in row 1 and one country per row, then add helper columns: =COUNT(B2:AI2) for years with data and =SUMPRODUCT(MAX((B2:AI2<>"")*$B$1:$AI$1)) for the latest year with a value. A country with three data points is not a trend line.
Look for filled values. A pull of ER.H2O.FWTL.K3 on October 8, 2026 returned values for 182 economies, but only 16 in 1970, 104 in 1990 and 177 in 2010. Of the 182, 85 report exactly the same number in every year from 2015 to 2020. The United States shows 444.29 billion cubic meters for each year from 2015 through 2022, and from 2010 to 2015 it rises in equal steps of 5.098. A flat run or a perfect straight line between two years usually means a value was interpolated or carried forward from a survey year, not measured annually. To count repeats in a row, use =SUMPRODUCT((C2:AI2=B2:AH2)*ISNUMBER(C2:AI2)).
Confirm the definition. Withdrawal is not consumption (freshwater withdrawal versus consumption), and GDP in current dollars is not GDP in constant dollars or PPP (nominal GDP versus GDP PPP). Read the unit and long definition before you compare two columns. The articles on freshwater withdrawals and GDP measures go deeper on those two cases.
Cite and license correctly
CC BY 4.0 lets you copy, adapt and use the data commercially if you credit the source, link the license and say whether you changed anything. Add a Sources sheet to the workbook with one row per dataset:
| Field | Example |
|---|---|
| Publisher | World Bank, World Development Indicators |
| Series | ER.H2O.FWTL.K3, annual freshwater withdrawals, total (billion cubic meters) |
| Original source | FAO AQUASTAT |
| URL | The API or download address you used |
| Retrieved | 2026-10-08 |
| License | CC BY 4.0 |
| Changes | Aggregates removed; blanks left blank |
For the wording of a World Bank citation, see how to cite World Bank data. Natural Earth needs no credit. For POWER, include NASA's acknowledgment text from its site. For FRED, cite the series ID and the original publisher.
A checklist
- Prefer the primary publisher, and name any intermediary as well.
- Record the series code, URL, retrieval date and license before you clean anything.
- Remove aggregates,
-999fill values and flag characters before calculating. - Count years per country, and check for flat runs and straight lines.
- Confirm unit and definition for every column you compare.
- Keep the raw download unchanged on its own sheet and work on a copy.
The freshwater and GDP examples above come from datasets that Sheet Reserve publishes with their sources and licenses documented: freshwater withdrawals by country (AQUASTAT through the World Bank) and GDP by country (WDI).