iOS 16 web push notifications in 2023

I’m glad to see that I wasn’t the only one watching that keynote. :wink:

I’m not sure why it won’t debut with the first release of iOS 16, but whatever…

Wasn’t that already available in macOS? I’ve been able to receive able to receive Safari push notifications from MacRumors for years now. Maybe they were using a workaround of some sort? :thinking:

2 Likes

As I said in my earlier post:

1 Like

Ah, sorry. I wasn’t entirely sure what you meant by that. :see_no_evil:

1 Like

There was very little detail in today’s video. Meet Web Push for Safari - WWDC22 - Videos - Apple Developer

WebKit has a blog post up today.

There’s a little more detail available here.
https://developer.apple.com/documentation/usernotifications/sending_web_push_notifications_in_safari_and_other_browsers

At the Safari WWDC lounge, a user “John” asked a question, “Will web push work in WKWebView instances?” The answer from “Brady E” at Apple was:

On macOS Ventura, Web Push is only supported in Safari 16.

John followed up: “what about iOS/iPadOS?” to which Brady replied, “Look for iOS/iPadOS support in 2023.” So, they’re not answering any questions today about iOS support.

It seems extremely unlikely to me that Web Push notifications will work in a WKWebView in 2023, especially on iOS, so I expect that Safari Web Push will have no direct benefit to Discourse Hub.

But, of course, the Discourse Hub app will be much less important when Safari Web Push lands.

6 Likes

Thank you for following this with Apple and for writing a follow-up to this here :pray:t2:

There are some other benefits to the Discourse Hub application.

You’re mostly correct though. It’ll become partially obsolete soon enough. I wonder if CDCK will ditch it altogether… :thinking:

1 Like

Its About Time GIFs | Tenor

BTW, There are no plans on ditching the mobile app, it’s still very useful to be able to aggregate all of your discourse sites and notifications together in one place, separately from receiving real-time notifications

3 Likes

Would it make sense to bring Discourse Hub to the web as a PWA?

4 Likes

That’s unfortunately not something currently on our roadmap, but it’s something I personally would love to see, it’s an great idea :slight_smile:

7 Likes

Me too. Especially since non-push notifications flat out don’t work 95% of the time.

Really this whole topic is about push notifications, which you simply can’t get on iOS with self-hosted Discourse without creating a separate iOS app, which then might not be accepted into the App Store.

3 Likes

Oh, I’m glad to hear it’s not on the chopping block! @jimkleiber made a good point about that.

1 Like

Nodeb solved this problem with ntfy

meta.discourse.org now supports macOS Safari pushes. (Hopefully Apple will enable iOS web pushes soon.)

3 Likes

Small correction, all up to date Discourse instances have support for push notifications on MacOS Safari :wink:

3 Likes

In what way is this new? I thought MacOS Safari always supported notifications? The limitation has always been an iOS one?

MacOS Safari supported notifications, yes, but they were simply triggered by the page javascript. In Discourse, this meant that you would need a tab open for the website, for MessageBus to be still polling, the tab to not be suspended, etc.

Now, Safari on MacOS supports the WebPush standard where even without having Safari open at all you will still get notifications, very much like they work on native apps in your phone.

4 Likes

Ah got it, so they’ve now standardised. That’s excellent! Thanks for the explanation.

1 Like

Pushing Season 2 GIF by The Office

They made it restricted to apps added to the home screen! I suggested this to the Chrome team back in 2021 as a way to curb request spam, but they dismissed it.

13 Likes


[1] pry(main)> PushSubscription.last
=> #<PushSubscription:0x00007fec11b781a8
 id: 5164,
 user_id: 8722,
 data:
  "{\"endpoint\":\"https://web.push.apple.com/.........\",\"keys\":{\"p256dh\":\"..................\",\"auth\":\"..............\"}}",
 created_at: Thu, 16 Feb 2023 21:51:24.260325000 UTC +00:00,
 updated_at: Thu, 16 Feb 2023 21:51:24.260325000 UTC +00:00,
 error_count: 0,
 first_error_at: nil>

Just enabled it here on Meta on my iPad, let’s see how it goes.

First iOS push notification prize goes to @maiki

Looooots of notifications

16 Likes

We may have less testers this time around, at least initially:

If you install 16.4 using the profile then you will be stuck at b1 unless you log in with a developer account or until swap to the public betas.