Possible Duplicate:
How does Google Maps estimate my location without GPS?

I was wondering how Google Maps on my Android phone can locate me with a good accuracy when my GPS is disabled.

At first I though it was with the cell tower but I'm not sure it can achieve this precision and it is way better when the wireless is enabled.

Experiment that i did.

  1. If GPS is OFF and Wifi is ON = Perfect location
  2. If Wifi is ON GPS OFF = Still Perfect location
  3. If Wifi is OFF and GPS is ON = location is not precise.

Tested this with 5 -6 Phones

Any Idea why ?

  • 4
    What's the difference between 1 and 2 in your experiment? Are you indoors or outdoors? Apr 16, 2012 at 16:18

2 Answers 2


Google have a huge database of the approximate locations of a large number of phone network cell towers and wifi access points all around the world. If your phone can "see" one (or more) known cell-tower IDs or Wifi AP SSIDs, then it can query Google's database to ask where that is and use that for your location. The cell network towers have a large range (kilometers in some cases) so that alone won't give a precise location. As Wifi is a very short range signal your phone can locate you very precisely using that, particularly if you're also picking up Wifi signals of different strengths from neighbouring houses to triangulate from.

All of the quoted sections below are from: Google Maps Help - Location-based services

Because GPS is not always available and locations derived from cell towers aren’t very accurate, Google (and other Internet companies) use publicly broadcast Wi-Fi data from wireless access points to improve our location-based services. By using signals from these access points, your mobile device is able to fix its general location quickly without using too much power.


Our Location Server uses only publicly broadcast Wi-Fi information to estimate the location of a device:

The MAC (Media Access Control) address. This is a number that identifies computing devices – whether PCs, laptops, tablets, mobile phones, or wireless access points – interacting with a network. MAC addresses usually look like this: 00:01:02:0A:0B:0C. The number is usually fixed for the life of the device. A MAC address tells you nothing about the owner or user of the equipment concerned. It’s just a string of characters that’s technically necessary for web pages and other content to be properly delivered to your device over the Internet.

This data has been collected in two main ways: as their Google Street View car drives around it always has a precise GPS fix, at the same time it listens out for Wifi APs that broadcast their identity and records where it was when it picked them up, and does the same for phone network cell towers; in addition they "crowd-source" the data from Google Maps users on mobile devices, as the Google Maps users travel around with GPS enabled Google Maps will check which cell-towers they're connected to and which wifi points they can "see" and periodically upload this information.

Google Maps on an Android handset is an example of a reliable channel, since we can be confident that the SSIDs and MAC addresses it sends as part of a location request haven’t been tampered with before being sent.

So, for example, one way to ensure that your changed SSID is submitted to Google quickly, open Google Maps on an Android Device with WiFi enabled, and use the My Location feature to establish a location fix in the vicinity of your WiFi access point.

See also How does Android get the coarse location?

  • @gathrawn- Its still Hard to believe that WIFI's AP SSID can tell the location. Is there some Documentation that you could provide please ? :) If i get a new WIFI modem then? In that case Googles Database dosnt have my ID , So what would happen in that case?
    – Yahoo
    Apr 16, 2012 at 17:14
  • 1
    Google don't just use your WiFi modem's details, it will also check the details of any other WiFi APs it can detect in the area. Changing your WiFi modem means that your non-GPS fix will be slightly less accurate for a while as it has to rely on other sources (like other people's wifi or cell towers), until enough other devices have detected and logged your new AP for Google to get a fix on where it is. Adding references to the answer in a couple of minutes, but I'm pretty sure it's a combination of your WiFi AP's SSID and its MAC address that gives it the unique ID
    – GAThrawn
    Apr 18, 2012 at 16:06

Android offers two ways (from a developer point of view) to determine your current location:

LOCATION_COARSE Allows an application to access coarse (e.g., Cell-ID, WiFi) location

LOCATION_FINE Allows an application to access fine (e.g., GPS) location

So to answer your first question: Yes Android can determine your location just by the cell-broadcast. Keyword here is triangulation and this depends on the density of the broadcast towers. In Berlin you get about 100 m accuracy.

As you can see, the Android documentation says "e.g.", because some phones may also have GLONASS support etc. to determine your location. You have to check your specific phone GPS chip to check what frequency it supports (L2 etc.).

So regarding your second question:

Since GPS falls into the category of LOCATION_FINE it will be picked if available. So Android can not distinguish which position signal is better.

Indoors GPS may be worse, but will still be picked if available, because generally speaking it is a more precise signal.

  • In My case the GPS doesn't give precise location but WIFI gives it ( Weather GPS is OFF or ON ) :) What is the reason behind that ?
    – Yahoo
    Apr 16, 2012 at 17:17
  • Android does not use triangulation for the location determination. It's just a simple GSM Cell Tower Database.
    – Flow
    Apr 16, 2012 at 21:07

Not the answer you're looking for? Browse other questions tagged .