Learn how to manage and customize app icon badge counts for push notifications on iOS and Android, including disabling auto-clearing, using the OneSignal API, implementing native badge logic, and testing setup.
OneSignalNotificationServiceExtension
info.plist
, add the Key: OneSignal_disable_badge_clearing
with Boolean type to Value YES
Example info.plist with ` OneSignal_disable_badge_clearing` turned off (set to `YES `).
UIApplication.shared.applicationIconBadgeNumber
in iOS 17. You should now use the following methods from the UserNotifications framework:UserDefaults
, your app’s data model, or syncing with your backend).
Set badges in the OneSignal dashboard message form.