1 comment

  • Avatar
    Sergey Polshcha

    For iOS, you can find example with geotracking here:

    And yes, it is possible to use geotracking when application is in background. There are two options:

    • You have defined "location" value for UIBackgroundModes key in info.plist (also named "Required background modes" -> "App registers for location updates"). In this case, when your app is in background, it uses standard location services (GPS & Wi-Fi crowdsourcing database). This is very accurate way for geotracking, which allows you to use geozones with very small radius (>10m) but it drains your battery very quickly.
    • You have not defined "location" value for UIBackgroundModes key in info.plist. In this case, app uses iOS geofencing technology and cell-towers for getting location. This is not so accurate way, but it does not drain battery as GPS. With geofencing, minimum radius for geozone must be >100m.

    When app in foreground, it always uses standard location services (GPS), independently of UIBackgroundModes key. When app is not running (killed by user), it uses geofencing for updating location.

    Also keep in mind that disabled Wi-Fi decreases geotracking accuracy very hard.

    All the above is actual for iOS.

Please sign in to leave a comment.