How to geocode a phone number in the United States?
Asked Answered
D

5

5

I am looking for a way to get the latitude and longitude coordinates of any area code + prefix land line phone in the United States. Does anyone know of a data provider or service that could be used to do this?

EDIT: I understand that the location of cell phones or VOIP lines probably cannot be geocoded and this is fine by me. I am only interested in POTS phone numbers. Although, it would be nice to be able to identify the type of phone service based on the prefix (if this is even possible).

Dhyana answered 3/6, 2009 at 19:36 Comment(1)
there are no acceptable solutions to this anymore.Romeyn
D
2

I found a few options that do the trick for a reasonable price:

Option 1 (web service subscription):

Service Objects DOTS GeoPhone [edit: link is no good now] web service should do the trick nicely. It even seems to provide the "telephone service type" information that I was hoping for.

Option 2 (database subscription):

AreaCodeWorld™ Platinum Edition [edit: link is no good now] is a database product that can be purchased on a one-time basis or via annual subscription. The data spec includes all North American area codes and prefixes along with latitude & longitude coordinates.

Dhyana answered 4/6, 2009 at 15:16 Comment(0)
T
2

There are websites that do this, for example http://www.thedirectory.org [edit: link is no good now]. I have no idea if they have anything like a RESTful api you could use, although I guess you could always screenscrape them. Presumably the raw data that they're using should be something you could obtain yourself, possibly from the phone company.

Transpire answered 3/6, 2009 at 19:48 Comment(1)
This is helpful, thank you. Unfortunately, I will have to keep looking. According to the FAQ at thedirectory.org they limit the number of lookups to 50 in a 48 hour period and do not provide or sell the database in any other form. :(Dhyana
D
2

I found a few options that do the trick for a reasonable price:

Option 1 (web service subscription):

Service Objects DOTS GeoPhone [edit: link is no good now] web service should do the trick nicely. It even seems to provide the "telephone service type" information that I was hoping for.

Option 2 (database subscription):

AreaCodeWorld™ Platinum Edition [edit: link is no good now] is a database product that can be purchased on a one-time basis or via annual subscription. The data spec includes all North American area codes and prefixes along with latitude & longitude coordinates.

Dhyana answered 4/6, 2009 at 15:16 Comment(0)
G
2

Using the Google Geocoding API and the list on the side of allareacodes.com, I created this json for a hacker project:

http://pintweets.com/area_codes.json [edit: link is no good now]

Clearly, this is not court-admissible evidence, but it should work for certain purposes.

Gobelin answered 18/4, 2012 at 22:30 Comment(0)
N
1

[EveryoneAPI][1] [edit: link now goes to a new site not related] will do exactly what you're looking for.

You can limit your query to location-only by adding "data=location" to your HTTP request, and you'll get back something like this:

"location": {
  "city": "Birmingham",
  "geo": {
    "latitude": "33.51685254860801",
    "longitude": "-86.81075983815001"
  },
  "state": "AL",
  "zip": "35203"
}

Disclaimer: I am the CEO of Telo. [1]: https://www.everyoneapi.com/

Nadeau answered 29/3, 2017 at 19:22 Comment(0)
C
0

There's publicly available geocode data for zipcodes (although the location they give is the geocode for the corresponding post office), so you might be able to build a correspondence that way (although you'd have to pick the specific zip more or less at random, as there are many more zips than area codes).

However there's going to be some built in error. Some numbers (e.g. 800 numbers) don't have a specific location by design. Same with cell numbers. In NY, in any case, there are cell #'s that start with the same areacode as NY-located phone #'s (e.g. 718, 212). I'm not sure if the carriers are required to provide those #'s in a way that corresponds with the customers billing address, either, so you might get a situation where most of the 212 #'s are NYC but some are cell phones in Wichita.

Cockloft answered 3/6, 2009 at 19:45 Comment(4)
Also I believe some VOIP services can assign any area code that the customer wants, regardless of physical location.Transpire
A zip database is better than nothing, but it's only half a solution; Saul's trying to zero-in using the prefix, not just the area code. I don't know if that info is available in a zip DB -- it wasn't when I was looking at them, but that was six years ago.Theressathereto
Steve B. - Unless the publicly available geocode data for zipcodes includes area codes, I don't know how it would help me. Also, I am aware that the location of cell phones, VOIP phones, etc could not be realistically geocoded (which is why I stated "land line") in the question. I will try and revise to be more clear about the type of phone numbers I am trying to work with.Dhyana
The database I was working with six years ago did indeed include area code data. (Granted, that DB wasn't free, but it was pretty cheap.) Just wasn't any prefix data, and the amount of terrain covered by a single area code can be kinda freakin' huge.Theressathereto

© 2022 - 2024 — McMap. All rights reserved.