Sulaiman Khan
Sulaiman Khan

Reputation: 928

iOS - Opening App Push Notification Settings screen from App

I want to open Push Notification Settings from my app. Is it possible in iOS? I know I can open Settings screen only.

Upvotes: 1

Views: 2796

Answers (4)

sergeyski.com
sergeyski.com

Reputation: 596

On iOS 16 you should be able to do this

if let url = URL(string: UIApplication.openNotificationSettingsURLString) {
    // Ask the system to open that URL.
    await UIApplication.shared.open(url)
}

Source: https://developer.apple.com/documentation/uikit/uiapplication/4013180-opennotificationsettingsurlstrin

Upvotes: 0

Simon Reggiani
Simon Reggiani

Reputation: 560

Since iOS 15.4 we can deeplink to the notif settings screen directly: https://developer.apple.com/documentation/uikit/uiapplicationopennotificationsettingsurlstring?language=objc

Upvotes: 1

Ghufran
Ghufran

Reputation: 16

You can open app setting from your app. Refer this apple doc

https://developer.apple.com/documentation/uikit/uiapplication/1623042-opensettingsurlstring

Upvotes: 0

congnd
congnd

Reputation: 1284

There is no official way to so do. You can navigate directly to the Notification Setting page but doing so can cause your app to be rejected.

https://stackoverflow.com/a/49041704/3867033

Upvotes: 0

Related Questions