NSLocation When In Use Usage Description
A message that tells the user why the app is requesting access to the user’s location information while the app is running in the foreground.
Availability
- iOS 11.0+
Framework
- Core Location
Details
- Name
- Privacy - Location When In Use Usage Description
- Type
- String
Discussion
Use this key if your iOS app accesses location information only when running in the foreground. If your app needs location information when in the background, use NSLocation
instead. For more information, see Choosing the Location Services Authorization to Request.
If you need location information in a macOS app, use NSLocation
instead.
See Also
Authorization
Choosing the Location Services Authorization to Request
Determine the authorization your app needs to access location data.
Requesting Authorization for Location Services
Ask the user for permission to access their location.
Responding to Changes in Authorization Status
Receive and respond to changes in your app's authorization status in your delegate's method.
enum CLAuthorization Status
Constants indicating the app's authorization to use location services.
enum CLAccuracy Authorization
Constants indicating the level of location accuracy the app has authorization to use.
property list key NSLocation Always And When In Use Usage Description
A message that tells the user why the app is requesting access to the user’s location information at all times.
property list key NSLocation Usage Description
A message that tells the user why the app is requesting access to the user’s location information.
property list key NSLocation Default Accuracy Reduced
A Boolean value that indicates whether the app requests reduced location accuracy by default.
property list key NSLocation Always Usage Description
A message that tells the user why the app is requesting access to the user's location at all times.