I'm developing a web-app and I want to send push notifications to users on iPhone. Is there any way of doing this from the browser? Chrome or Safari does not matter.
3 Answers
As of today a web app cannot receive push notifications on any iOS browser (Safari, Chrome for iOS, ...). The reason is that iOS does not yet include an implementation of Service Workers, which are needed for push notifications to work. It is currently in development, though: https://webkit.org/status/#specification-service-workers
And it is already working on Safari for OS X: https://developer.apple.com/notifications/safari-push-notifications/
Meanwhile, you will have to settle for a native implementation of your app, at least on iOS. My recommendation would be using what you have developed for web and making it a hybrid app through the use of Apache Cordova.
You can also regularly check if support is available here:
-
Now in 2019, work the web push notificacion in chrome/ safari iOS? the link webkit.org/status/#specification-service-workers now is supported but the Notification javascript object and the push api isnt support so isnt supported(for me dont work, i dont know if it is my problem or only that notification dont exists in webkit), web push with service workers, and also isnt supported simple push with Notification. For me the hybrid app dont work because is a development about web push in a specified website and nothing of apps. Sep 18, 2019 at 7:47
iOS supports Service Worker technology (e.g. for offline caching)
Web Push Notification support is added in iOS 16
You can send push notification from web application, the only condition is the mobile device must have registered to receive push notifications for a particular application. The registration for push notification is done through a native app and can only be performed through a native app. Once the native app is registered for push notification, it can send the authorization token to the server, which can be used in conjunction with the certificate used to provision the native client, to send the push notifications to the mobile device.
Please refer to Apple guidelines on push notification for more detail
-
Thanks. So you can not send push notifications from any browser on ios, as of this date? May 16, 2017 at 8:38
-
If you have integrated push notification functionality in native app then you can else no. May 16, 2017 at 9:10