Download Postal Codes By Country

Welcome to the world of postal code data!

At Geoapify, we are committed to providing you with an invaluable resource - postal code datasets for countries around the globe. The best part? You can download these Postcodes Dataset for Free!

Our dedication to open data ensures that you have easy access to postal code information that can be instrumental in your business or personal projects. Whether you're a developer building applications, a business optimizing logistics, or simply someone in search of precise location information, our postal code datasets are here to serve your needs.

What's even better is that you can access these datasets without downloading via the Geoapify Geocoding API, an intuitive and robust platform that simplifies the integration of postal code data into your Web-applications.

Available Countries

We aim to provide worldwide access to open postal code datasets. Our goal is to make postal code information available for as many countries as possible, allowing you to benefit from accurate location data globally with a priority to official sources from governments.

Our postal code datasets are available under an open data license to promote transparency and accessibility. By downloading and using our datasets, you agree to:

  • Use the data responsibly, respecting all applicable laws and regulations.
  • Provide proper attribution when redistributing the data.

For specific licensing terms and data source for each country, please refer to:

CountryData sourceLicense
FranceCreated by Géoclip (Ciril GROUP) utilizing Open Data resources.ODbL License
GermanyDerived from OpenStreetMap ( There is no particular URL to download; it's database extraction.ODbL License
NorwayGeonorge - Norway's national hub for map data and location-based information.Creative Commons BY 4.0 (CC BY 4.0)
United StatesAccess postal code data for the United States from the trusted source of the U.S. Census BureauU.S. Census Bureau's licensing and terms

Please ensure compliance with the licensing terms and conditions for each country when using the data. The datasets are provided for informational purposes, and data accuracy should be verified according to your specific needs.

More countries are coming soon!

As we work towards our mission, keep an eye out for updates and announcements about new countries being added to our list. We look forward to providing you with open postal code datasets from around the world.

Data Structure

Postcodes in our datasets are in a JSON format that includes the following fields:

  • postcode: A postal code or ZIP code.
  • country_code: The country code for the location.
  • lon: The longitude coordinate.
  • lat: The latitude coordinate.
  • area: The area associated with the location in square meters.
  • tags: This field contains properties from the original data source.
  • geometry: A GeoJSON Geometry object containing the geometric shape of the location. It includes the type ("Point", "Polygon", or "MultiPolygon") and coordinates that define the geometry.

Here is an example of data:

  "postcode": "00602",
  "country_code": "US",
  "lon": -67.1755974,
  "lat": 18.361945,
  "area": 82975147,
  "tags": {
    "aland20": 78546711,
    "geoid20": "00602",
    "mtfcc20": "G6350",
    "ogc_fid": 13856,
    "awater20": 4428428,
    "classfp20": "B5",
    "zcta5ce20": "00602",
    "funcstat20": "S",
    "intptlat20": "+18.3619450",
    "intptlon20": "-067.1755974"
  "geometry": {
    "type": "Polygon",
    "coordinates": [

Download Postcodes

Click the link below to access the archived postal code datasets by country:

After downloading the dataset, unzip or extract the files to access the postal code data. It's important to note that due to the substantial size of the files, the postal code datasets are provided in the New Line JSON (NDJSON) format.

Reading NDJSON Files (JavaScript Code Samples)

You have two options for reading NDJSON files: you can read the entire file at once or read it line by line.

Option 1. Reading the Whole File

You can read the entire NDJSON file at once, for example, using the fs.readFileSync method:

const fs = require('fs');

const data = fs.readFileSync('PATH_TO/postcodes.ndjson', 'utf-8');

const postcodes = data
  .filter(line => line.trim()) // Filter out empty lines
  .map(JSON.parse); // Parse each line into a JavaScript object


This approach loads the entire NDJSON file into memory, making it suitable for smaller files or when you need all the data at once.

Option 2. Reading Line by Line

If you prefer to process the file line by line, for example, you can use the ndjson library. First, ensure you have the ndjson package installed:

const fs = require('fs');
const ndjson = require('ndjson');

const postcodes = [];
fs.createReadStream('PATH_TO/postcodes.ndjson', 'utf-8')
  .on('data', postcode => {
  .on('end', () => {

This approach is efficient for large NDJSON files, as it processes one line at a time, reducing memory usage.

Both methods allow you to access the data in the NDJSON file, whether you need it all at once or prefer to process it line by line.

More Postcode Data Sources

In addition to the provided postcode datasets, we provide several alternative sources of valuable postcode (ZIP-code) information for different countries.

It's important to note that while these sources provide valuable data, some licenses may restrict the use of the data for commercial projects and other requirements.

CountryData SourceLicenseGeometry Type
GlobalGeoNames Postcode DatasetsCreative Commons Attribution 4.0 LicensePoints
PortugalCP7 Portugal on GitHubGNU General Public License v3.0Points
BelgiumPostal Districts by Geo.beThe resource custodian owns intellectual property rights to geographic files. Users are granted internal use rights; however, commercial use is strictly prohibited. The custodian's name must be mentioned when publicly using the data.Polygons
SpainDS Códigos Postales on GitHubUnspecifiedPolygons

While these datasets offer valuable information, it's crucial to carefully review the licensing terms to ensure compliance, especially regarding the use of the data for commercial projects and other specific purposes.

The postcode data in most of these datasets are provided in shapefile format. You can find valuable tips to convert SHP files into different data formats on the page Converting shapefiles to GeoJSON.

Frequently Asked Questions (FAQ)

How can I get the original source for the data?

You can find information about the original sources in the ReadMe file accompanying the dataset. This file contains details about data providers and their terms of use.

Can I use the data set in my Web Application?

We don't restrict the usage of our dataset in web applications. However, we recommend checking the file size. For large datasets, it's advisable to consider creating a backend service for efficient data retrieval, or you can take advantage of our Geocoding API to access the data.

Can I reduce the file size of the dataset?

Certainly. You have the flexibility to customize the dataset according to your needs. You can remove unnecessary data, including geometries, to reduce the file size. Just ensure that the information you retain remains relevant to your use case.

How can I use the data set?

You can use the dataset in various ways, and here are some practical examples:

  • Address Verification: Validate and standardize addresses using postal codes.
  • Geocoding: Convert postal codes into latitude and longitude coordinates for mapping.
  • Location-Based Services: Create applications for location-based services and navigation.
  • Logistics Optimization: Enhance route planning and delivery services with accurate postal code information.
  • Demographic Analysis: Analyze populations and demographics in different regions.
  • Market Research: Conduct market analysis and targeting based on postal code regions.
  • E-commerce: Enhance e-commerce platforms with location-based features.
  • Data Visualization: Create informative maps and visualizations using postal code data.
  • Emergency Services: Improve response times and location accuracy for emergency services.
  • Custom Applications: Tailor the data for your unique projects and business needs.

Can I share the data with others or use it in a commercial product?

Yes, you can share the data with others and use it in commercial products. However, it's important to ensure that you comply with the open data license and terms, provide proper attribution, and follow any relevant legal requirements.

How often are the datasets updated?

Dataset update frequencies may vary depending on the country and data sources. Please refer to the dataset documentation or contact our support team for specific update details.

What data quality assurances are provided?

We strive to maintain data accuracy and reliability, but we do not guarantee the completeness or correctness of the data. We recommend verifying and validating the data according to your specific needs and use cases.