The Zip Code API provides United States zip code data with a comprehensive data model in JSON format. Using REST design, this API can help you build zip validations, city searches, distance calculations, radius searches and many other key functions for your applications.

Fast API Responses

Millisecond response times for Zip Code API responses.

Always Up to Date

The Zip Code database is updated monthly with the latest Zip Code changes from USPS.

JSON Responses

Well structured JSON responses with a very complete and enhanced data model for US zip codes.

Free to Try

We offer a free tier that allows you to try the full functionality of the zip code database


Endpoints:

  • GET Zip Code Details. Gets the details of a single Zip code.
  • GET List All Zip Codes. Returns a list of zip codes. Can take query parameters.
  • GET Distance Between 2 Zip Codes. Gets the distance (in miles and kilometers) between 2 zip codes passed as parameters. There are 2 mandatory query parameters (zipCode1 and zipCode2).
  • GET Zip Code Radius. Endpoint that returns the zip codes that fall within the specified radius of another zip code. The returned zip codes are sorted by distance.
  • GET List All MSA Groups. This end point lists all the Metropolitan and Micropolitan Statistical Areas in the United States with the corresponding states and counties that make up the group.
  • GET Metro/Micro Statistical Area Details. Gets the details of a single Metropolitan Statistical Area code passed as a path parameter.

Complete and comprehensive data model for each Zip Code in the USA

Sample Zip Code Object for Beverly Hills 90210:

{
    "links": {
        "self": "https://global.metadapi.com/zipc/v1/zipcodes/90210"
    },
    "meta": {
        "count": 1
    },
    "data": {
        "zipCode": "90210",
        "uspsMainCityKey": "Z20259",
        "uspsMainCityName": "BEVERLY HILLS",
        "titleCaseCityName": "Beverly Hills",
        "zipClassificationCode": "N",
        "zipClassificationDesc": "Non-Unique Zip",
        "uspsFacilityCode": "P",
        "uspsFacilityName": "Post Office",
        "uspsCityMailingInd": true,
        "uspsDeliveryCode": "Y",
        "uspsDeliveryDesc": "Office Has City-Delivery Carrier Routes",
        "uspsCarrierRouteSortCode": "B",
        "uspsCarrierRouteRateSortDesc": "Carrier Route. Sortation/Rates. Apply-Merging Not Permitted",
        "uniqueZipNameInd": false,
        "uspsFinanceNumber": "050666",
        "stateCode": "CA",
        "stateName": "California",
        "stateFipsCode": "06",
        "stateAbbr": "Calif.",
        "countyFipsCode": "037",
        "uspsCountyName": "LOS ANGELES",
        "titleCaseCountyName": "Los Angeles",
        "latitude": 34.100517,
        "longitude": -118.41463,
        "landAreaMi2": 10.125,
        "waterAreaMi2": 0.059,
        "landAreaKm2": 26.22277,
        "waterAreaKm2": 0.153478,
        "divisionCode": "9",
        "divisionName": "Pacific Division",
        "regionCode": "4",
        "regionName": "West Region",
        "msaCode": "31080",
        "msaName": "Los Angeles-Long Beach-Anaheim, CA Metro Area",
        "cityAliases": [
            {
                "uspsCityKey": "Z20259",
                "uspsCityName": "BEVERLY HILLS",
                "titleCaseCityName": "Beverly Hills",
                "uspsCityAbbr": null,
                "uspsCityMailingInd": true,
                "uspsMainCityInd": true
            }
        ],
        "zipCodeStatistics": [
            {
                "year": 2000,
                "totalPopulation": 21396,
                "malePopulation": 10061,
                "femalePopulation": 11335
            },
            {
                "year": 2010,
                "totalPopulation": 21741,
                "malePopulation": 10292,
                "femalePopulation": 11449
            }
        ]
    }
}
			

Documentation for this API can be found here. See all endpoints, security, examples, and well as multiple programming languages examples.

Subscription Tiers

Professional$99/mo

  • Unlimited API requests per month
  • Unlimited API requests per month
  • Unlimited Concurrent Calls
  • Dedicated Support
  • Sign up

Free$0

  • 1,000 API requests per month
  • 2MB Monthly Bandwidth
  • 1 Concurrent Call
  • Email Support
  • Sign up