Reverse Geocoding | Convert Lat Long to an Address
Reverse geocoding is the process of converting a latitude & longitude coordinates into the corresponding street address.
Geocoding is the process of converting a street address into the corresponding latitude & longitude coordinates (a geocode).
Ready to Reverse Geocode?(courtesy of our US Reverse Geocoding API)
Even though reverse geocoding can come with challenges, we’re going to answer all your questions so that you become a certified geocoding guru.
Table of Contents
- What is the difference between geocoding and reverse geocoding?
- Levels of accuracy
- How to reverse geocode a geocode into an address
- Batch reverse geocoding
- Service providers for batch and API
What Is the Difference Between Geocoding and Reverse Geocoding?
For starters, we need to answer the question: What is geocoding? Geocoding starts with an address and gives you back a latitude/longitude point (a geocode). Reverse geocoding starts with a latitude/longitude point, and gives you back an address.
For example let’s say we are doing international geocoding and you live at the top of Mount Everest. Which, first of all, is very cool - way to get a place with a view.
Your address would be formatted something like:
111 Summit Circle, Apt. 32A Mt. Everest, Nepal
Geocoding would take this address and replace it with the corresponding geocode, which is the latitude and longitude coordinates of the address. The geocode for your address on Mt Everest would be:
This geocode represents an exact point on the earth. A mailing address is not an exact point on the earth. Consequently, a geocode can be a much more accurate description of where you live. The process of converting an address into a geocode, is called ‘geocoding’. So, what then is reverse geocoding?
Reverse geocoding is the process of converting a geocode into an address.
If we started off with your geographic latitude and longitude coordinates (or geocode) of:
reverse geocoding this geocode would give us back your address of
111 Summit Circle Mt. Everest, Nepal
This address data would then be referred to as your ‘reverse geocode’.
You might be saying, “Awesome. Got it. But who cares? What does geocoding and reverse geocoding do for me?” To which I would reply, “Welcome to the next section of this document. You’re asking the exact question I wanted you to ask.”
Geocodes can give accuracy for geographic information that a regular address may not be able to provide. For instance, let’s imagine that your Mt. Everest home is actually part of a spread out apartment complex.
If someone were to try to deliver a package to your apartment, the address would lead them to the address of the complex but not the location of your unit. To make matters worse, addresses don’t prominently display unit numbers. Now, it becomes difficult to locate the address.
A geocode provides additional location-based accuracy. Having the latitude and longitude would pinpoint the exact location. Higher level of accuracy better guarantees you are getting the right addresses and the most correct geocodes. Of course, this depends on the accuracy of the reverse geocoding web services that you’re using.
Levels of Accuracy
Geocoding’s helpfulness is contingent on the accuracy of the geocoding service that you’re using. Within the geocoding industry there are different levels of accuracy. So, we would advise checking whatever service you’re using to ensure that they are parsing to the level that you need. The different levels of reverse geocoding accuracy are:
- Rooftop Geocoding: The highest level of geocode accuracy available. Just as the name implies, these coordinates have been verified as the rooftop of the location in question. This data is often obtained via interpolation. Rooftop location is calculated based on known coordinates of nearby roads.
- Parcel Centroid: Locates the center of the parcel or property. This is not rooftop accuracy, but it at least has been verified to hit the property, and the geocodes are likely close to the middle of the parcel.
- Thoroughfare: The geographic data has been verified down to the thoroughfare or street-level. The exact location of the property is not identified. Rather, this level of data means that you are ‘close’ But, its exact location cannot be verified.
- Locality: The data is verified to the level of the city or town. The lookup in question has been determined to be in a particular city or town, but the location cannot be specified any more precisely.
- Administrative Area: The lowest level of geocoding accuracy. The location in question can only be parsed to be in a particular state or province.
Before you commit to a particular bulk geocode service or API service provider, we suggest running several sample street addresses to ensure the level of accuracy matches what you need. Take note: many reverse geocoding companies will advertise they are “rooftop level accurate” when they aren’t. Rather than believing their sales copy, test a sampling of your addresses and see for yourself.
How to reverse geocode a geocode into an address
We know what a geocode is and how geocodes can help us. We have learned about the differing levels of accuracy with geocoding. Let’s dive into how you can reverse geocode a geocode into a street address with house number, street name, city name, ZIP Code, country code, geonames, and other Geo place names. This gives us the location intelligence needed.
Get your geocode
Coordinates commonly display in two formats. First as latitude and longitude the way a human understands and contain the degree symbol (°) and includes indicators for North, East, South and West. The other displays as a numeric shorthand that a computer better understands.
The more human understandable format for Mt. Everest would look like this:
The more the computer understandable format looks like this:
Not a huge difference but not all geocode systems can interpret the human understandable format. So, make sure you get the computer understandable coordinates.
Enter your geocode into a reverse geocoding engine
Geocoding lookup providers are oftentimes referred to as a converters, or finder services. Since it's close by, we’ll use SmartyStreets’ reverse geocoder.
- Visit our reverse geocoding API demo page
- Enter your geocode into the latitude and longitude boxes. For the example, we will use this one:
- Click “View API Response”
- The results will show up on the right in the ‘API Response’ box. There you will see the validated, standardized address closest to the coordinates you put in.
- SmartyStreets also provides the best available geocode for the address. The level of accuracy attained will also be listed. In this case, the geocode is rooftop accurate.
Here is the original geocode we entered and the geocode that SmartyStreets gave back in the API response. This is an improvement of 29 feet (8.83 Meters). Neat.
Finally, the SmartyStreets demo includes the 10 closest addresses to your geocode in the API response. We also pair each address with the best geocodes we have and the level of accuracy attained.
And there you have it! We just reverse geocoded. It feels good, doesn’t it?
Batch Reverse Geocoding
It’s simple enough to reverse geocode one address, but what do you do if you want to convert a lot of geocodes into addresses?
You could manually process each geocode one at a time, but at that rate you might as well just rack up your sky miles and go visit each location in person. I mean, who has the time to reverse geocode hundreds, thousands or even hundreds of thousands of geocodes into addresses, individually?
To process many geocodes quickly, you’ll want to perform batch reverse geocoding. To do that, you’ll need to use a batch reverse geocode service provider that allows uploads with a CSV file. You might also want to find a provider of a reverse geocode API.
Service providers for batch and API
There are a number of notable companies that provide batch reverse geocoding. The services from these companies range in cost and quality, but we’ll discuss the positives and negatives of two of the more prominent providers: Google and OpenStreetMaps.
Google Reverse Geocoding
One of the most famous reverse geocode converters is, of course, Google. After all, who hasn’t heard of Google Maps? And, because they do maps, Google also does batch geocodes and reverse geocoding via API.
Like most geocoding providers, Google provides coverage for over 200 countries and territories, but the level of geocoding accuracy varies from country to country. For example, geocoding spatial data for the United States can often be ‘rooftop’ level precision. Geocodes for China are notoriously inaccurate and can often only be verified to the administrative, or state/province level.
It is worth noting that Google’s reverse geocoding API does not gather as many data types about certain coordinates as their user-facing reverse geocoder built into Google Maps. This means the Google Geocoding API, which you can purchase, tends to be less accurate than their internal Google Maps. So, we would recommend that you take the API for an accuracy test drive before committing to it. If you were to only test their user facing reverse geocoder, you would only get part of the story.
In addition to geocodes from their mapping service, Google provides a data source for ‘Routes’ and ‘Places’. But, this data does come with some limitations. Specifically, users are limited to only 50 server-side requests per second. Which means crunching through a lot of data can be time-consuming.
So the benefit of using Google is that you’re using the company behind Google Maps - a product known for its usefulness and accuracy. The downside of using the Google Address API is that you’re not getting the same accuracy that Google Maps provides. And, Google doesn’t validate that the address they return to you is an actual, real address.
OpenStreetMap Reverse Geocoding
OpenStreetMaps is another prominent provider of geocoding data. The OpenStreetMap project is built by a community of mapping professionals that all collaborate to provide geographical data from around the world.
The nice thing about OpenStreetMap is that it is kind of a Wiki: it’s free and it’s maintained by individuals who are dedicated to the cause. The downside is that it requires you to credit OpenStreetMap and its contributors if you use the web service. So, if you need reverse geocodes for any type of proprietary business process, you are going to need to look for another provider.
Additionally, when dealing with volunteers on an enormous project like reverse geocoding the world, geographic data accuracy can vary greatly from coordinate to coordinate. So, test out several addresses before committing to a batch or API service provider.
SmartyStreets Reverse Geocoding
The SmartyStreets US Reverse Geocoding API is a world-class geocoder. Our reverse geocoder offers several competitive advantages over other providers. Here are key reasons businesses choose SmartyStreets.
Speed - Remember how Google rate limits you to 50 reverse geocodes per second? That is great if you only need a handful of geocodes for your neighborhood picnic. What if you had 200 billion geocodes like telecom providers get every few weeks? It would take 127 years to geocode all those coordinates. By then, the data would no longer be useful.
Luckily, SmartyStreets offers plans that include speeds exceeding 30,000 lookups per second. As in 600+ times faster than Google. If Google was the book, “Around the World in 80 Days” SmartyStreets would be the book, “Around the World in Less Time Than It Takes To Watch The Godfather”. Impressive.
Accuracy - Accuracy matters. Hyper-accuracy rocks. When SmartyStreets reverse geocodes, we give you the nearest addresses to your coordinates. We also provide the most precise geocode we have for your addresses. So, you give us a geocode, and we give you back an address and a rooftop geocode when possible.
Cascading Resolution - When we reverse geocode, we provide the most accurate addresses available. We offer rooftop accuracy for the vast majority of geocodes. If we can’t find a requested geocode, we cascade down to the next levels of accuracy until we have a geocode. Most important, we tell you what level of accuracy we achieved; you aren’t left guessing.
We Don't Guess - Guessing and geocodes don’t play well together. Even still, there are geocoding providers whose geocodes are about as accurate as throwing darts blindfolded. These providers do their best to give you a geocode for your requested addresses where possible. When they fail to provide the requested geocode, they give their best guess which can be hundreds of miles off.
Geocoders who guess cause business decisions based on bad data. You would prefer that a provider say “we don’t know” rather than taking shots in the dark.
Like other providers, SmartyStreets does everything possible to give you the most accurate geocodes possible. When we aren’t sure, we won’t guess. Instead, we tell you that we don’t know. That way, you aren’t making business decisions based on bad data.
Valid, Standardized Address - SmartyStreets was born as an address validation software. Because validation is our first love, we baked it into our US Geocoding and US Reverse Geocoding products.
When you geocode an address, we first perform address standardization and verify it to make sure it is real and correct. Then, we give you the Geocode. With reverse geocoding, we only match your geocode with real valid US addresses. And of course, we still give you the address in that same standardized format.
I want to let you in on a little secret. The best geocoding originates with top-notch address validation. If a provider doesn’t do address validation or relies on open source data, you will frequently receive false-positives. That is why we chose to develop our geocoding products. We are the industry leader in address validation. And as such, we can provide some of the most accurate geocodes available.
Very Trustworthy - When you write the code to consume our APIs, you want it to work correctly all the time.
We are so dependable that the Greenwich Royal Observatory sets its clocks based on our uptime. The 1988 Toyota Hilux uses SmartyStreets as it’s powertrain. Our software was a crucial component of the flux capacitor ( we were not consulted on the DeLorean though). We were used in the development of the Nokia 3210. Our APIs have even been shown to violate the second law of thermodynamics and exhibit something new called “reverse entropy”. Many scientific papers on the subject are forthcoming.
How did we become so trustworthy? Here’s how:
- Redundant data centers operating in multiple regions of the US
- Redundant server monitoring
- Data centers that scale to near infinite levels based on load
- Employees that are exclusively descended from George Washington
So, when you start using our APIs, don’t be surprised when you find them to be the most trusted components of your systems too.
Reverse geocoding is the practice of putting in a set of latitude and longitude coordinates and getting the corresponding address. Accuracy levels can range from rooftop down to administrative area. By knowing this, you can seek out the right reverse geocoder services for your needs, and even find one that provides batch or API services. We recommend testing the product first to guarantee that the level of accuracy provided matches the level of accuracy needed.
Now, get out there, and find the best reverse geocoding address locator service (single address, batch or API) that fits your needs and start converting lat long to addresses!