I have a bunch of telephone numbers (just the area codes), and I'd like to geolocate them and make a map, but I haven't had too much luck googling for shapefiles for Area Codes. Surely these are in the public domain?

  • 1
    Are you willing to pay? I had a quick look, but was not able to find any free sources -- it seems there are many companies eager to sell the data, however. – nmpeterson Apr 22 '12 at 1:47
  • It appears that ESRI might have them on their data CD. – mhoran_psprep Apr 22 '12 at 3:08
  • (1) Do you need the shapefile for the entire United States? – DSG Apr 22 '12 at 18:52
  • 1
    An older answer, but perhaps still with useful information, appears at stackoverflow.com/questions/4047689/…. – whuber Apr 22 '12 at 21:39
  • @nmpeterson: I would prefer to avoid paying if possible; this is for a hobby project. – Jason Sundram Apr 22 '12 at 22:25

You could also try using the MaxMind GeoLite City dataset. This dataset is a point layer that contains both the AreaCode and MetroCode (Example: AreaCode - MetroCode - XXXX). If you have a metrocode, you might be able to get closer than just with area code by finding the nearest City point that shares both the area code and metrocode of the phone number you are testing.

If you are trying to get the center of the area code, you could try creating something like a Voronoi diagram and dissolve the polygons to generate area-code like boundaries. I will tell you, however, tried this method already, there are a lot of outliers that will need to be cleaned up in order to get a decent output of area codes (see image below). It certainly wouldn't be perfect, but would give you an approximation.

There are some other questions that have mentioned the MaxMind dataset that you may want to read for additional information.

Initial map, all points:

Unfiltered area codes

Update: After doing some pre-processing of the points to remove outliers and clipping to the US boundaries, the result turned out pretty good, I thought.

"Cleansed" map after removing outliers and clipping to US border


Area Code Map


"area codes have very little correlation with geographic location. Zip codes are much more useful."

Source: http://groups.google.com/group/google-maps-api/browse_thread/thread/74262bccd2e0ce36


Old, question, but since it still appears at the top of my google search, the UCLA Geoportal has a free version of the NANP boundries.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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