GeoClue: The Geolocation Service

Geoclue is a D-Bus service that provides location information. The primary goal of the Geoclue project is to make creating location-aware applications as simple as possible, while the secondary goal is to ensure that no application can access location information without explicit permission from user.

Geoclue is Free Software, licensed under GNU GPLv2+. It is developed for Linux.

The aim of project is to utilize all possible sources of geolocation to best find user's location:

  • WiFi-based geolocation (accuracy: in meters)
  • GPS(A) receivers (accuracy: in centimeters)
  • GPS of other devices on the local network, e.g smartphones (accuracy: in centimeters)
  • 3G modems (accuracy: in kilometers, unless modem has GPS)
  • GeoIP (accuracy: city-level)

WiFi-based geolocation makes use of Mozilla Location Service. If geoclue is unable to find you, you can easily fix that by installing and running a simple app on your phone.

For making use of your phone's (currently only Android supported) GPS, you'll need to install the latest version of GeoclueShare app on your phone.

Geoclue used to also do (reverse-)geocoding but that functionality has been dropped in favor of geocode-glib library.

Discuss & contribute

How to use it from an application

Here you can find documentation for the D-Bus API:

libgeoclue API documentation is here:

Here is an example of how a C application can locate its user:

Get the source

The code is is available as a tar-ball and in a Git repository. You can also browse the source.

Latest releases available here.

Git repository:

  • git clone git://
    For help with Git, see Usage notes here on and documentation on Git homepage.


Geoclue got started during GNOME Summit 2006 in Boston. At least Keith Preston and Tuomas Kuosmanen can be blamed.

There was a total rewrite after version 0.9. Use tag "0.9" (as in git checkout 0.9) if you need the old code.

There was yet another rewrite that we call geoclue2. The first version to introduce the re-write was 1.99. You can find the rationale for the re-write here but I was way too lazy/busy to preserve the previous wiki page.