Skip to content

About

Free sample CSVs of US ZIP code, ZIP+4, area-code, carrier-route, and geocoded address data from postalup.com (CC BY 4.0 samples)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

US ZIP Code Sample Data

Sample CSVs from PostalUp — US ZIP code, ZIP+4 address-range, area-code, carrier-route, and geocoded address data. This repo is a free, open sample of the full commercially licensed catalog, published so you can evaluate the schema and data quality before buying.

What's in this repo

File Rows Description
data/zipcode_database_standard_sample.csv 100 ZIP-level records: city/alias names, county, coordinates, time zone, classification flags (sample of the ZIP Code Database, Standard tier)
data/zip_4_database_standard_sample.csv 100 Street-level 9-digit ZIP+4 address ranges with carrier route, delivery point, and county/census identifiers (sample of the ZIP+4 Database, Standard tier)
data/area_code_database_basic_sample.csv 100 NPA area-code records: location, time zone, in-service status, overlay flag, ZIP counts (sample of the Area Code Database, Basic tier)
data/carrier_routes_sample.csv 104 Carrier-route assignments per ZIP with route type and ZIP+4 range bounds (sample of the Carrier Routes pack)
data/geocoded_addresses_sample.csv 95 Address-level latitude/longitude with county FIPS and a confidence score (sample of the Geocoded Address Database)

Each file is a small slice of the corresponding full product — a schema preview, not a representative statistical sample. Column-by-column definitions are in docs/field-reference.md.

Loading the data

Python (pandas)

import pandas as pd

zips = pd.read_csv("data/zipcode_database_standard_sample.csv", dtype={"zipCode": str})
print(zips[zips["stateCode"] == "NY"][["zipCode", "cityName", "countyName"]].head())

See examples/python/load_pandas.py for more, including a ZIP ↔ ZIP+4 join.

Python (SQLite)

import sqlite3
import pandas as pd

conn = sqlite3.connect("zip_sample.db")
pd.read_csv("data/zipcode_database_standard_sample.csv", dtype=str).to_sql(
    "zip_codes", conn, index=False, if_exists="replace")
pd.read_csv("data/zip_4_database_standard_sample.csv", dtype=str).to_sql(
    "zip4_ranges", conn, index=False, if_exists="replace")

q = """
SELECT z4.zipCode, z4.zipPlus4, z4.streetName, z.cityName, z.countyName
FROM zip4_ranges z4
JOIN zip_codes z ON z.zipCode = z4.zipCode AND z.isPrimaryRecord = 'true'
LIMIT 10
"""
print(pd.read_sql(q, conn))

Runnable version: examples/python/load_sqlite.py.

SQL (Postgres)

-- examples/sql/schema.sql defines the tables; postgres_load.sql loads the CSVs
\i examples/sql/schema.sql
\i examples/sql/postgres_load.sql

Get the full dataset

These samples are small slices. The full catalog includes:

  • ZIP Code Database — up to 110 fields per ZIP across tiers, including demographics and business fields (pricing)
  • ZIP+4 Database — the full street-level address-range table (pricing)
  • Geocoded Address Database — point-level coordinates with confidence scoring (pricing)
  • Complete Dataset — every database and pack bundled (pricing)

Full products are sold under a 1-year commercial license and refreshed monthly. Formats include CSV, JSON, SQL, and Parquet depending on product.

Related free data

The US ZIP Code Rankings & Demographics dataset (richest/poorest/largest/ fastest-growing ZIP codes) is free and CC BY 4.0:

License and attribution

The sample CSVs in this repo are licensed CC BY 4.0 — free to use, share, and adapt with attribution to PostalUp. See CITATION.cff for a citation template.

The full paid catalog on postalup.com carries its own commercial license terms (1-year license; see the license terms linked from checkout). This repo contains only the free sample files already published on the site.

About

Free sample CSVs of US ZIP code, ZIP+4, area-code, carrier-route, and geocoded address data from postalup.com (CC BY 4.0 samples)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors