Optional parameters to customize the retrieval of the geolocation.

{ maximumAge: 3000, timeout: 5000, enableHighAccuracy: true };


  • frequency: How often to retrieve the position in milliseconds. This option is not part of the W3C spec and will be removed in the future. maximumAge should be used instead. (Number) (Default: 10000)
  • enableHighAccuracy: Provides a hint that the application would like to receive the best possible results. (Boolean)
  • timeout: The maximum length of time (msec) that is allowed to pass from the call to [geolocation.getCurrentPosition](../geolocation.getCurrentPosition.html) or [geolocation.watchPosition](../geolocation.watchPosition.html) until the corresponding [geolocationSuccess](geolocationSuccess.html) callback is invoked. (Number)
  • maximumAge: Accept a cached position whose age is no greater than the specified time in milliseconds. (Number)

Android Quirks

The Android 2.x simulators will not return a geolocation result unless the enableHighAccuracy option is set to true.

{ enableHighAccuracy: true }