Back to results for “Handlers”
.NET MAUI › Platform Integration & Handlers

How do you request runtime permissions in MAUI?

Intermediate

Answer

Use the Permissions API: check the status with CheckStatusAsync and request with RequestAsync for a permission type (e.g., LocationWhenInUse, Camera). Declare the permission in each platform manifest (AndroidManifest.xml, Info.plist). Handle Denied and Disabled states gracefully.
var status = await Permissions.CheckStatusAsync<Permissions.Camera>();
if (status != PermissionStatus.Granted)
    status = await Permissions.RequestAsync<Permissions.Camera>();
Real-world example Before opening the camera, the app checks and requests camera permission, showing a rationale if the user previously denied it.

Common follow-ups: Where do you declare permissions per platform? | How do you handle a denied result?