The APP was not awakened by system after start a liveactivity and the liveactivity has showed on lock screen.so the updatetoken wont send to our inner server and the liveactivity can not update,often like this,but sometimes it can work.
it makes me confuse,and i don't know how should i can do,because the liveactivity like a black box,i can not analyse the data link.for example ,inner server send a start liveactivity,but it can not accept a updatetoken unless the user lanuch APP.
i hope the liveactivity can start and update on background. And i have developed it as described in the document.
Hope to get your help,thank you very much.
User Notifications
RSS for tagPush user-facing notifications to the user's device from a server or generate them locally from your app using User Notifications.
Posts under User Notifications tag
149 Posts
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
Hello all 👋
We're developing an app for families with neurodivergent members (primarily autistic children) and have run into a critical reliability issue with silent push notifications that breaks core functionality.
Our current implementation:
When a caretaker updates the person's daily routine/schedule in our system, we send a silent push notification to the user's device. The app wakes, connects to our server, downloads the updated schedule, and creates/updates local notifications for upcoming activities.
The problem:
Because the app is rarely/never directly interacted with by the end user (the child doesn't open the app - caregivers configure it on their behalf), silent push notifications get progressively throttled and eventually stop being delivered entirely. This means schedule changes made by caregivers never reach the device, breaking the app's core value proposition. Uninstalling and reinstalling doesn't reset the throttling state
Questions:
Is there any way to reset or mitigate throttling for devices that legitimately need background updates but have low or no user interaction? This is an accessibility use case where the end user (child) doesn't interact with the app, but the app must reliably receive updates. Would switching to regular (visible) push notifications avoid this throttling even if the app is not interacted with?
We already have Critical Alerts entitlement, but for regular updates we're worried that the "CRITICAL ALERT" banner will be too upsetting for the child. Is there any exception process for accessibility apps to change the way Critical Alerts are presented?
For neurodivergent individuals, predictable routines are essential. When schedule updates don't reach their device, it can cause significant distress. This is a genuine accessibility need, not a "nice-to-have" feature.
Any guidance from Apple engineers or developers who've solved similar challenges would be greatly appreciated.
Thank you!
Topic:
App & System Services
SubTopic:
Notifications
Tags:
APNS
iOS
Accessibility
User Notifications
Hello,
An application I am working on would like to schedule push notifications for a medication reminder app. I am trying to use BGTaskScheduler to wake up periodically and submit the notifications based on the user's medication schedule.
I set up the task registration in my AppDelegate's didFinishLaunchingWithOptions method:
BGTaskScheduler.shared.register(
forTaskWithIdentifier: backgroundTaskIdentifier,
using: nil) { task in
self.scheduleNotifications()
task.setTaskCompleted(success: true)
self.scheduleAppRefresh()
}
scheduleAppRefresh()
I then schedule the task using:
func scheduleAppRefresh() {
let request = BGAppRefreshTaskRequest(identifier: backgroundTaskIdentifier)
request.earliestBeginDate = Date(timeIntervalSinceNow: 60 * 1)
do {
try BGTaskScheduler.shared.submit(request)
} catch {
}
}
In my testing, I can see the background task getting called once, but if I do not launch the application during the day. The background task does not get called the next day.
Is there something else I need to add to get repeated calls from the BGTaskScheduler?
Thank You,
JR
Topic:
App & System Services
SubTopic:
Processes & Concurrency
Tags:
Background Tasks
User Notifications
I am an iOS development engineer. Recently, I updated the Xcode version to 16.1 (16B40) and updated my debugging device (iPhone 15) to iOS 18.1.1. However, I found that I could not respond to the delegate method.
I confirmed that my code, certificate, Xcode settings, and network environment had not changed. Simply executing
application.registerForRemoteNotifications()
in
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool
did not receive a response(didRegisterForRemoteNotificationsWithDeviceToken or didFailToRegisterForRemoteNotificationsWithError ).
In the same environment, when I switched to another device for debugging (iOS 17.0.3), the delegate method would respond.
I really don't know what to do, I hope someone can help me, I would be very grateful.
Please note: Everything is normal when using devices before iOS 18.1.1 version
Hello Team,
We are currently experiencing an issue where some of our devices are not receiving push notifications. We are sending notifications via the Apple Push Notification portal (https://developer.apple.com/notifications/push-notifications-console/) using the following two requests. However, in both cases, the notifications are not being delivered to the devices.
Scenario 1 :
When we send a request with apns-push-type set to alert, we receive the following error.
Request :
curl -v
--header "authorization: bearer ${AUTHENTICATION_TOKEN}"
--header "apns-topic: com.testcompany.sampletest"
--header "apns-push-type: alert"
--header "apns-priority: 10"
--header "apns-expiration: 0"
--data '{"aps":{"alert":{"title":"Test Notification Title","subtitle":"Test Notification Sub Title","body":"Test Notification Body"}}}'
--http2 https://api.push.apple.com:443/3/device/*devicetoken*
Response:
{
"code": 400,
"message": "bad-request",
"reason": "The device token is inactive for the specified topic. There is no need to send further pushes to the same device token, unless your application retrieves the same device token.",
"requestUuid": "c4ae39b4-87e1-4269-a1e9-163f60ec0385"
}
Scenario 2 :
However, if we send the request with apns-push-type set to background, the request is processed successfully by APNs, but no notification is received on the device.
Request :
curl -v
--header "authorization: bearer ${AUTHENTICATION_TOKEN}"
--header "apns-topic: com.testcompany.sampletest"
--header "apns-push-type: background"
--header "apns-priority: 10"
--header "apns-expiration: 0"
--data '{"aps":{"alert":{"title":"Test Notification Title","subtitle":"Test Notification Sub Title","body":"Test Notification Body"}}}'
--http2 https://api.push.apple.com:443/3/device/*devicetoken*
Response:
Getting a message that The notification sent successfully but no notification is received on the device.
In both cases (with alert and background push types), the push notification does not reach the device.
Additionally, when we validated the device token using the APNs Device Token Validator, it appears to be valid and returns the following message.
"Device Token is valid for sending Alert & Background push-type notifications in the Production environment"
Affected Device:
macOS version : MacOS 15.3.1
Processor : Apple M1
Could you please assist me in resolving this issue?
Thanks
I am developing a Flutter app for food delivery (a multivendor e-commerce restaurant app).
In the vendor app (Android), I successfully implemented a background notification that stays active until the vendor responds with either Accept or Decline.
This works fine on Android, but I cannot get the same functionality working on iOS.
My requirements:
Vendor should receive a background notification.
The notification should include action buttons (Accept / Decline).
It should remain active until the vendor takes action.
My questions:
Is this possible to implement in iOS with Flutter?
If yes, what is the recommended way (e.g., firebase_messaging, flutter_local_notifications, flutter_foreground_task, or native iOS integration)?
Are there any iOS restrictions I should consider compared to Android background services?
I built this for Android using firebase_messaging + flutter_foreground_task + flutter_local_notifications.
On iOS, I tried setting up firebase_messaging and flutter_local_notifications, but I’m unable to keep the notification persistent with Accept/Decline action buttons.
I expected similar behavior to Android, but it seems iOS has more restrictions around background services and notification handling.
Dependencies I am using (relevant ones):
firebase_core: ^3.8.0
firebase_messaging: ^15.1.5
flutter_local_notifications: ^17.2.2
flutter_foreground_task: ^8.17.0
get: ^4.7.2
shared_preferences: ^2.3.2
Topic:
Developer Tools & Services
SubTopic:
General
Tags:
App Store Server Notifications
Notification Center
User Notifications
PushKit
ISSUE:
CloudKit subscriptions are not triggering push notifications despite correct configuration. CloudKit logs show RecordSave events but NO NotificationSend events, indicating CloudKit is not attempting to send to APNS.
CONTAINER:
iCloud.Wunderkind.StrikeForceApp
ENVIRONMENT:
Tested in both Development and Production
iOS 18.6.x
Xcode 15.x (update with your version)
Device: iPhone (not simulator)
EVIDENCE:
Subscriptions exist and are visible in CloudKit Dashboard
Records are being created successfully (verified in logs)
Device token is registered: 60eb962ff189dc5c2c0ef3e9d6643d72b4442a831bae224d2a553588b2e29139
Local notifications work correctly
CloudKit logs show RecordSave but NO NotificationSend events
STEPS TAKEN:
Regenerated push certificates
Disabled and re-enabled Push Notifications capability
Deleted and recreated subscriptions
Tested in both Development and Production environments
Verified aps-environment entitlement matches environment
Confirmed notification permissions granted
SPECIFIC TEST:
Creating a Challenge record with recipientRef matching my user triggers:
✅ RecordSave event in CloudKit logs
❌ No NotificationSend event
❌ No push notification received
EXPECTED:
CloudKit should send NotificationSend events and deliver push notifications when subscriptions match.
ACTUAL:
No NotificationSend events appear in CloudKit logs, no notifications delivered.
my dynamic island UI is triggering as empty when i send my curl, this is a pushToStart run push driven live activity and when i send my curl this is what appears, despite be being able to render the UI through a local push no problem, here is my curl.
curl -v \
-H "apns-topic: MuscleMemory.KimchiLabs.com.push-type.liveactivity" \
-H "apns-push-type: liveactivity" \
-H "apns-priority: 10" \
-H "Content-Type: application/json" \
-H "authorization: bearer eyJhbGciOiJFUzI1NiIsImtpZCI6IjI4MjVTNjNEV0IifQ.eyJpc3MiOiJMOTZYUlBCSzQ2IiwiaWF0IjoxNzU4ODU2MDkyfQ.i83VbgROsxEzdgr512iQkVsp0FjHIoHq2L6IB2aL1fImJgX-XM6TM5frNnVyfva7haMd9fDGjO2D_wfCq8WnBg" \
--data '{
"aps": {
"timestamp": '"$now"',
"event": "start",
"content-state": {
"plain_text": "hello world",
"userContentPage": ["hello world"]
},
"attributes-type": "KimchiKit.DynamicRepAttributes",
"attributes": {
"activityID": "12345"
},
"alert": {
"title": "Workout started",
"body": "We’ll show your reps on the Lock Screen.",
"sound": "default"
}
}
}' \
--http2 https://api.sandbox.push.apple.com/3/device/80d50a03472634d9381b729deec58a3e250ea0006b7acd7c2d6ef19e553dcdb010eb1434ff9a6907380f6ed3e9276d57d58f3cda3ac9fc3bea67abae116601a63ec77a34174fd271c4151ec898abae30
and heres my content state which resides in a shared module
@available(iOS 17.0, *)
public struct DynamicRepAttributes: ActivityAttributes, Codable {
public struct ContentState: Codable, Hashable {
public var plainText: String
public var userContentPage: [String]
public enum CodingKeys: String, CodingKey {
case plainText = "plain_text"
case userContentPage
}
public init(plainText: String, userContentPage: [String]) {
self.plainText = plainText
self.userContentPage = userContentPage
}
}
public var activityID: String
public init(activityID: String) {
self.activityID = activityID
}
}
Ive also alr verified my attributes type is correct, have been stuck on this issue would really appreciate the help
Since upgrading to Xcode 26 beta 4 and using the iOS 26 simulator for testing our app, we've stopped being able to receive device tokens for the simulator from the development APNS environment.
The APNS environment is able to return meta device information (e.g. model, type, manufacturer) but there are no device tokens present. When running the same app using the iOS 18.5 simulator, we are able to register the device with the same APNS environment and receive a valid device token.
Notification coordination between iOS and watchOS is not working properly
watchOS and iOS try to coordinate between phone and watch notifications.
The concept here is that if there is a main app and a companion app, they could both be sending a notification, then the notification would alert on both, which is a deviation from how notification mirroring is handled if there is an iOS app but no watch app.
The watch waits for the iOS notification to fire so they can determine if this is the same notification that needs to be deduped, displayed on one device but not the other, or separate notifications to be displayed both.
If there is no notification on the phone, the watch will timeout after 13 seconds and alert anyway.
If you have an iOS companion app, the best solution to this is to send the same notification on both devices simultaneously, and ensuring the UNNotificationRequest.identifier matches on both notifications. This will let the systems determine how to handle the notification correctly and quickly, and the notification will alert right away.
https://developer.apple.com/forums/thread/765669
According to the above article, "when a notification arrives on watchOS alone first, it coordinates with iOS," but in reality, it doesn't work properly.
Detailed process of this phenomenon
watchOS receives a notification.
On watchOS, the notification is not immediately shown to the user.
iOS receives a notification with the same UNNotificationRequest.identifier as in (1).
The notification in (3) does not appear on either iOS or watchOS. However, the notification from (3) does appear in iOS Notification Center.
Thirteen seconds after watchOS received the notification, the notification from (1) is shown to the user on watchOS.
In the end, the iOS and watchOS notifications are not consolidated and each remains in its respective notification center.
Up to (3) there are no issues. Starting with (4), both iOS and watchOS exhibit a lot of odd behavior.
This phenomenon occurs with both local notifications and push notifications.
When iOS receives the notification first, there is no problem. The notification for watch received later is processed appropriately, and the watchOS notification is not additionally displayed to the user.
Expected proper process
Same as above.
Same as above.
Same as above.
The notification in (1) is integrated into the notification in (3).
The notification in (3) is alerted to the user immediately.
2 sample projects to reproduce
Only the main code is attached.
Sample project1: local notifications
Swift code for local notification app (iOS, watchOS) - App.swift.txt
Sample project2: push notifications
This sample project is implemented using Firebase Functions and Firebase Cloud Messaging.
Swift code push notification app (iOS, watchOS) - App.swift.txt
Server side JavaScript code for FirebaseFunction - index.js.txt
Tested devices and OS
This phenomenon occurred in both of the following patterns.
Pattern 1
Xcode 26.0
iPhone 16 (iOS 26.0)
Apple Watch series 10 (watchOS 26.0)
Pattern 2
Xcode 16.4
iPhone 11 (iOS 18.6)
Apple Watch SE 2nd gen (watchOS 11.6)
Question
Is this phenomenon a bug?
Or is my understanding or implementation incorrect?
Feedback Assistant number
FB20339772
After porting code to Swift 6 (Xcode 16.4), I get a consistent crash (on simulator) when using UNUserNotificationServiceConnection
It seems (searching on the web) that others have met the same issue. Is it a known Swift6 bug ? Or am I misusing UNUserNotification ?
I do not have the crash when compiling on Xcode 26 ß5, which hints at an issue in Xcode 16.4.
Crash log:
Thread 10 Queue : com.apple.usernotifications.UNUserNotificationServiceConnection.call-out (serial)
As far as I can tell, it seems error is when calling
nonisolated func userNotificationCenter(_ center: UNUserNotificationCenter, willPresent notification: UNNotification, withCompletionHandler completionHandler: @escaping (UNNotificationPresentationOptions) -> Void)
I had to declare non isolated to solve a compiler error.
Main actor-isolated instance method 'userNotificationCenter(_:didReceive:withCompletionHandler:)' cannot be used to satisfy nonisolated requirement from protocol 'UNUserNotificationCenterDelegate'
I was advised to:
Add 'nonisolated' to 'userNotificationCenter(_:didReceive:withCompletionHandler:)' to make this instance method not isolated to the actor
I filed a bug report: Aug 10, 2025 at 2:43 PM – FB19519575
Topic:
App & System Services
SubTopic:
Notifications
Tags:
Swift
Xcode
Notification Center
User Notifications
When I turn the Ringtone and Alerts volume all the way up, I expect standard notifications to play at the loudest level the device allows. In theory, this should match the volume of a critical alert with its sound.volume set to 1.0 in payload.
However, I’ve noticed that non-critical notifications still play quieter than critical alerts under these conditions. Critical alerts with volume: 1.0 sound noticeably louder than standard notifications, even though the Ringtone and Alerts slider is already set to maximum. And I couldn't find a documentation for this behavior anywhere.
Is this expected behavior on iOS? And is there any way to make non-critical notifications play at the same maximum loudness as critical alerts?
Thanks in advance for any clarification.
I am scheduling critical user notifications with a custom sound. This worked for years both on devices and in the simulator. Since Xcode 26 it crashes in simulator.
Example
let content = UNMutableNotificationContent()
content.title = "Critical"
content.body = "Example"
content.sound = UNNotificationSound.criticalSoundNamed(UNNotificationSoundName("notification.aiff"), withAudioVolume: 0.5)
content.interruptionLevel = .critical
let trigger = UNTimeIntervalNotificationTrigger(timeInterval: 10, repeats: false)
let request = UNNotificationRequest(identifier: "exampleCriticalNotification", content: content, trigger: trigger)
UNUserNotificationCenter.current().add(request)
It seems that simpler variants such as just content.interuptionLevel = .critical or just content.sound = UNNotificationSound.defaultCritical also crash.
I assume that critical notifications is a small niche use case but i still hope this gets fixed. This is filed as FB20272392 with a full crash log.
Hello all,
I'm building a web application in ASP.NET MVC (.NET Framework 4.7.2), from this web app I need to send push notifications to users. For the ones who are logged in with windows/android, everything works as expected, but I can't manage to get it work on the apple side.
If I use the same methods to subscribe to push notifications, it shows me the popup that asks the user to enable push notifications, and then I get an endpoint like this:
https://web.push.apple.com/QKC1Muic0H7...
It doesn't work using this (taking the part after https://web.push.apple.com/), I keep getting "Bad device token" (trying to send the notification via APNS).
Then I found out that there is another method to register the device from the frontend, and this one should give me the real device token:
window.safari.pushNotification.requestPermission
But this one doesn't show me the popup, it gives me "denied" without a reason.
I'm trying to a test application which is here https://pwa.vctplanner.it, the web push id is web.it.vctplanner, I created a push package downloadable from POST https://pwa.vctplanner.it/api/v2/PushPackages/web.it.vctplanner, and the code from the frontend is this:
function registerSafariPush() {
// Controlla se Safari Push Notifications è disponibile
if (!('safari' in window) || !('pushNotification' in window.safari)) {
console.log("Safari Push Notifications non supportate su questo browser.");
return;
}
// Il tuo Website Push ID registrato su Apple Developer
var websitePushId = "web.it.vctplanner";
// Controlla lo stato della permission
var permissionData = window.safari.pushNotification.permission(websitePushId);
switch (permissionData.permission) {
case 'default': // L'utente non ha ancora deciso
window.safari.pushNotification.requestPermission(
'https://pwa.vctplanner.it', // URL del server che serve il Push Package
websitePushId,
{}, // dati opzionali da inviare al server
function (permission) {
if (permission.permission === 'granted') {
console.log("Notifiche push abilitate!");
sendSubscriptionToServer({ endpoint: permission.deviceToken });
} else {
console.log("Notifiche push non abilitate dall'utente.");
}
}
);
break;
case 'denied': // L'utente ha negato
console.log("Notifiche push negate.");
break;
case 'granted': // L'utente ha già autorizzato
console.log("Notifiche push già autorizzate.");
sendSubscriptionToServer({ endpoint: permissionData.deviceToken });
break;
}
}
Any suggestions of what I'm missing? Is there a complete guide to how generate the push package?
Thank you
In iOS 26, I can check the notification that arrives to the user when the AirPods or Apple Watch is fully charged. When tap the notification, notification only expands and does not include actions such as moving to an app.
I checked the documents of UserNotification and UNNotificationServiceExtension, but I couldn't find what I wanted.
I can expand by long-tapping as default, but I'm looking for a way to expand it without entering the app when I tap the notification.
I wonder if there is an API that I missed or if it's not publicly supported.
thank you for your support.
Hello Developers,
I am currently developing a Flutter application where I am implementing both push notifications (for messages) and VoIP call notifications. The implementation works perfectly fine on Android. However, I am facing issues specifically on iOS in the following scenarios:
Terminated State:
When the app is terminated on iOS, neither call notifications nor message notifications are received.
In the background state, things partially work, but in the terminated state, nothing comes through.
Debug vs Production:
In Debug mode, everything works as expected (both message and call notifications).
Once I release the app to TestFlight (Production), the notifications completely stop working:
Message notifications are not delivered at all.
Call notifications also fail to appear in terminated state.
Configuration Details:
I have already configured APNs with .p8 key in Firebase.
The required capabilities (Push Notifications, Background Modes → Remote notifications, VoIP, etc.) are enabled in Xcode.
I also updated the AppDelegate.swift / Notification handling code for production environment.
Despite these steps, the same issue persists in production/TestFlight.
It seems like the issue is specifically related to production environment handling on iOS, since everything works in debug.
My Question:
What could be causing push notifications and call notifications to not work in the terminated state on iOS, especially in production/TestFlight builds?
Are there additional configuration steps required for APNs, VoIP, or background handling in production that differ from debug mode?
Any guidance or similar experiences would be really helpful.
Thanks in advance for your support.
Dear Apple Team,
I hope this message finds you well. I wanted to share a playful and innovative idea that could enhance the iPhone experience—particularly when viewing content in full-screen mode through apps like Apple TV or YouTube.
Feature Concept: Hands-Free Dismissal of Notifications
When the iPhone is in landscape mode, incoming notifications can interrupt the viewing experience. While Focus Mode and swipe gestures help, I thought of a more intuitive and hands-free interaction: using a light puff of air directed toward the screen to dismiss a notification.
This interaction could use the microphone or other onboard sensors to detect a brief burst of air, providing a fun and natural way to maintain immersion without touching the device.
If this isn’t feasible with current hardware, here are a few alternative concepts that align with the same goal:
Blink to Dismiss: Using Face ID sensors to detect a quick blink as a hands-free gesture.
Shake to Dismiss: A gentle shake gesture when holding the iPhone in one hand.
Gaze-Based Dismissal: Notifications automatically disappear after a brief moment of eye contact.
These ideas could offer both accessibility benefits and a touch of delight—making the iPhone feel even more magical and responsive.
Thank you for your time and for considering this suggestion!
Warm regards,
Badhan Baidya
26 beta 7,8,9. Waking me up. Checked settings several times. No issue for years prior to this
I created new APNS key, when i clicked on download, this is the error am getting:
Download Failed
Auth Key can only be downloaded once. This auth key has already been downloaded.
I dont have any key before and i have not downloaded the key before, it just a new key, i just created.
Please this is affecting the release of our client app, and the client is having negative thought concern our service not knowing it from you guys.
Previously, when using AppDelegate, I was able to check the app’s launch options (launchOptions) to determine cases such as:
Location updates (UIApplication.LaunchOptionsKey.location)
Background push notifications (UIApplication.LaunchOptionsKey.remoteNotification)
However, after migrating to the SceneDelegate approach, launchOptions is no longer available — it always returns nil.
In my app, I need to branch the code depending on the launch options, but I can’t find a way to achieve this in the SceneDelegate environment.
👉 Is there a way to access launch options in SceneDelegate, similar to how it worked in AppDelegate?
Or, if that’s no longer possible, what would be the proper alternative approach?
Any guidance would be greatly appreciated.