How to find a county by ZIP Code, city, or address lookup
Every mailing address is located within a specific county AND a specific ZIP Code. Therefore, if you know what the ZIP Code or city for a specific address, you can find out what county that address is located in. All you need is an address validation service provider. Here is a simple example of how to lookup a county using a ZIP Code. We'll also look at an example of how to perform a county lookup using a mailing address.
Before you embark on your journey, there is something you need to know. Cities and ZIP Codes frequently cross county and even state lines. Some cities cross into five different counties and as many as 20% of the ZIP Codes cross county lines. This means that if you enter a city or ZIP Code into our tool, it may return information for more than one county.
Conversely, a single address will only ever be located in one county. So, for the most precise results, use the full address to find county information rather than the city or ZIP Code.
Table of contents:
- Using a ZIP Code to find a county
- Using a mailing address to find a county
- Programmatically finding county data using ZIP Code API
- Programmatically finding county data using mailing address API
How to use a ZIP Code to find a county
Step 1. Go to the website of an address validation services provider of your choice. In this example, we'll find a ZIP Code's corresponding county designation using the Smarty address validation tool.
Step 2. Look for "Step 2: Choose a lookup type" and choose "city/state or ZIP Code" from the dropdown menu.
Step 3. Enter the ZIP Code in the "ZIP Code" form field of "Step 3."
Step 4. Click on "View Results."
Step 5. In the "Output Fields" section of the results, look for "County Name". There you will see the county associated with the ZIP Code you entered.
You can also find county info using this method by submitting the name of a city instead of a ZIP Code. On "Step 3", simply enter the city name instead of the ZIP Code.
How to find a county using a mailing address
The process for finding a county by using a mailing address is very similar to finding a county using a ZIP Code. However, it is not necessary to have the ZIP Code for this process. You can use a mailing address to find a county by using the following steps:
Step 1. Go to the website of an address validation service provider of your choice. For this example, we'll again use the Smarty address validation tool for single addresses.
Step 2. Look for "Step 2: Choose a lookup type" and choose "address components" from the dropdown menu.
Step 3. Enter the address info into the respective form fields of "Step 3". You can enter a ZIP Code into the "ZIP Code" field if you want to, but it is not necessary.
Step 4. Click on "View Results"
Step 5. In the "Metadata" section of the results, look for "County Name". There you will see the county associated with the address that you entered.
Programmatically finding county data by using a ZIP Code API
Sometimes, you need to find A LOT of county names for A LOT of different ZIP Codes. Because each individual address is also tied to a specific county, when that address is validated by an address validation service provider, the corresponding county data we be returned to you as well.
By programmatically accessing the Smarty ZIP Code API, you can submit tens of thousands of addresses in seconds. Our servers will process it in under 30 milliseconds on average and return to you a JSON response with up to 55 datapoints about the address, including the address' county name and county FIPS Code.
Step 1. Visit our ZIP Code API tool, select "zipcode" as your input field and enter your ZIP Code.
Step 2. Click "View API Response."
Step 3. In the "API Response" section, you will see the county listed as "county_name".
The process is facilitated by sending a simple HTTP request to the Smarty ZIP Code API. Complete instructions on how to call the Smarty ZIP Code API, including URL composition, Request Methods, Input Fields and Headers are found in our ZIP Code API documentation.
Programmatically finding county data asing a mailing address API
To find the county information for a large batch of specific addresses, you will want to use our US Street Address API. Since ZIP Codes and cities frequently cross county lines, entering an address to perform a county lookup is the most reliable way to get a single county returned.
Step 1. Visit our address validation API tool page and enter the address for which you would like county info.
Step 2. Click "View API Response."
Step 3. You will then see the sample cURL request and API response. The "county_name" will appear under the "metadata" section.
Step 4. Implement in the language of your dreams with our choice SDK's.