2

I'm searching for some kind of database which would allow me to determine the county from an existing US address (consisting of number, street, city, zip and state).

Obviously that would require some sort of database including street names and ranges, city, county and state; however I have not been able to find anything of the sort.

I'd appreciate any help. Thanks!

1
  • Maybe Google Maps/Places API, if they have this feature? Nov 26, 2015 at 16:26

3 Answers 3

5

The 2010 Zip Code Tabulation Area, provided by the Census Bureau, in text format with the county number it is located in can be found here:

https://www.census.gov/geo/maps-data/data/zcta_rel_download.html

Converting the county number to its proper name can be done using this text database from the Census Bureau:

https://www.census.gov/geo/reference/codes/cou.html

The commercially available option that includes a free download for personal use in .xls is here, it has the county name and zip code:

http://www.unitedstateszipcodes.org/zip-code-database/

2
  • It seems I need the ZCTA code for an address in order to get to the county number and name with those tables, however I have only the ZIP code of the address. What am I missing here?
    – Askaga
    Nov 25, 2015 at 15:40
  • 1
    the zip to county table is better than this answer. huduser.gov/portal/datasets/usps_crosswalk.html but that does not work either because some zips cross county lines. Nov 27, 2015 at 6:09
4

The Census Geocoder can perform this lookup. This service also has an API that you can use. The documentation (PDF) might be helpful. For example, this query:

http://geocoding.geo.census.gov/geocoder/geographies/address?street=740+Park+Avenue&city=New+York+City&state=NY&benchmark=Public_AR_Census2010&vintage=Census2010_Census2010&layers=14&format=json

returns

{
   "result":{
      "input":{
         "address":{
            "street":"740 Park Avenue",
            "city":"New York City",
            "state":"NY"
         },
         "benchmark":{
            "id":"9",
            "benchmarkName":"Public_AR_Census2010",
            "benchmarkDescription":"Public Address Ranges - Census 2010 Benchmark",
            "isDefault":false
         },
         "vintage":{
            "id":"910",
            "vintageName":"Census2010_Census2010",
            "vintageDescription":"Census2010 Vintage - Census2010 Benchmark",
            "isDefault":true
         }
      },
      "addressMatches":[
         {
            "matchedAddress":"740 Park Ave, NEW YORK, NY, 10021",
            "coordinates":{
               "x":-73.96422,
               "y":40.770588
            },
            "tigerLine":{
               "tigerLineId":"59657379",
               "side":"L"
            },
            "addressComponents":{
               "fromAddress":"736",
               "toAddress":"756",
               "preQualifier":"",
               "preDirection":"",
               "preType":"",
               "streetName":"Park",
               "suffixType":"Ave",
               "suffixDirection":"",
               "suffixQualifier":"",
               "city":"NEW YORK",
               "state":"NY",
               "zip":"10021"
            },
            "geographies":{
               "Census Blocks":[
                  {
                     "BLKGRP":"2",
                     "UR":"",
                     "OID":210403969807785,
                     "FUNCSTAT":"S",
                     "STATE":"36",
                     "AREAWATER":0,
                     "NAME":"Block 2002",
                     "SUFFIX":"",
                     "LSADC":"BK",
                     "CENTLON":"-073.9648786",
                     "HU100":198,
                     "LWBLKTYP":"L",
                     "BLOCK":"2002",
                     "BASENAME":"2002",
                     "INTPTLAT":"+40.7711022",
                     "POP100":375,
                     "MTFCC":"G5040",
                     "COUNTY":"061",
                     "GEOID":"360610130002002",
                     "CENTLAT":"+40.7711022",
                     "INTPTLON":"-073.9648786",
                     "AREALAND":13468,
                     "OBJECTID":6660907,
                     "TRACT":"013000"
                  }
               ]
            }
         }
      ]
   }
}
2

Are you familiar with Python? The geopy library in combination with Open Street maps and Google maps does a tremendous jobs. It is very easy to analyze thousands of addresses as if you would put them in a google maps search box. The API gives you the political units such as country, state and city. If you like I can share a script that can handle excel sheets as input files.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.