Last month, when Apple announced OS X Mavericks, the new operating system for Macs, one minor detail caught our eye. Although it was mentioned only in passing, Apple is bringing web notifications to Mac — natively.
This holds a lot of potential for web developers all over the world, who can use notifications to alert users to when an online auction has ended, breaking news, or even sports scores. We’re excited about the possibility of alerting readers to new issues of their favourite publications, so they don’t have to worry about checking manually or risk the message getting lost in email.
But we’ve got a couple questions. Naturally, we want to know how it works. What makes this different from similar features in Chrome or Safari? And how can we enable this feature across multiple platforms with HTML code?
How Web Notifications Work With Mavericks
Although web notifications can be put in place with Chrome or Firefox, Safari’s finally stepping into the game with all the perks that come with Mac’s Notification Centre. In principle, this allows the user to customize they way they receive web notifications. OS X allows them to make notifications appear as Banners, which go away automatically but remain visible in Notification Centre, or Alerts, which stay visible on the desktop until dismissed.
After the user allows web notifications from a given website, Mavericks will handle the rest of it, even when Safari isn’t running. When you couple that with a couple of OS X’s other advanced features, like Power Nap, that means that users will be able to receive web notifications from Safari even while their Mac is asleep.
Presumably, adding notifications with Mavericks will be similar to adding it in Chrome or Firefox (and a how-to is available here). The difference is that it has direct integration with the operating system. Let’s dig a little bit into Apple’s history with notifications to find out more.
Apple’s History With Notifications
On iOS, push notifications were enabled in iOS 3.0. Instead of the way other companies handle push notifications, which is as application-independent, Apple set up a centralized server that handles the notifications for all apps. This meant that an app had to be sold on the App Store to take advantage of notifications, but it also came with increased security.
Originally, Scott Forstall announced the push services for iOS 2.0, but they realized during stress testing that there was significantly more third-party demand for the feature than they had once thought. This gave Google the time to patent and release its own notifications solution. Instead of using a centralized server, Google stuck with its open-door policy on third-party apps and allowed users to receive notifications from anybody — including web services. While handy for web developers, it can also be abused. As a result, Android has since struggled with spam notifications. But Apple’s stance on notifications makes them difficult to implement for the company, who is currently largely alone in their lack of support (even Blackberry 10 supports web notifications). In fact, both Firefox and Chrome support web notifications on Android and the desktop because the notifications don’t have to go through a secondary server for assessment.
Apple’s Support of the Feature is a Big Deal
But Apple supporting web notifications largely changes the game because of their dedicated push notifications server and direct integration with their operating system. Mavericks brings some other changes to the way Macs handle notifications, including the ability to interact with a notification without booting up an app and the ability to sync iPhone notifications with your Mac.
Starting this fall, people will see all their iOS notifications on their Mac, so there’s less of a need to pull their phones out of their pockets. Typically speaking, Apple often introduces new features on their Macs before porting them to their iPhone. This leads us to hope that Apple will eventually allow the same thing on an iPhone, so users can get notifications from their computer to appear on their iPhone while they’re away. Apple’s already-existing technologies should allow this to happen even while a desktop is asleep or while a laptop’s lid is shut.
In real-world application, this bears a lot of potential. If Apple does allow Mac notifications to be displayed on an iPhone in the future, then with just a few lines of code, web developers could get their notifications on the Mac to also appear on the most popular phone in the world.
Where one company goes, another follows, so we think it’s safe to say Microsoft or Google could already be considering such features as well. That’s slightly negated by the fact that anybody can already display web notifications on those platforms, but their current implementation — which leads users to be cautious about allowing notifications on their devices — leavers something to be desired.
Some Other Technical Details
Technically speaking, we don’t yet know everything we’d like to about this feature. We’re going to presume that an Apple Developer ID won’t be necessary to implement web notifications, but we have to wonder. Some demo sites, like this one from Connor LaCombe, require the user to be running Safari 7.0 on Mavericks for the demo to run. We tried it on Chrome and were unable to get it to activate the demo there, despite the fact that Chrome offers push notifications otherwise.
So it does look like there are perhaps some different HTML implementations of Safari’s native web notifications to consider. At this time of writing, Apple’s Developer Center has been down for nearly a week because of a security hack, but all the specific documentation you’ll need to get started with the new Safari notifications will be available here shortly.
The Long and Short of It
Technically speaking, Safari handles web notifications in a more secure way for both legitimate developers and users. If the past has been any indication, this means that web notifications will eventually be accessible on iOS. For many web developers, this could change the way we interact with our users.
For us at Readz, we see it as an opportunity for any web developer with a subscription setting to make it easier to alert readers to new content, and that alone is reason enough to celebrate.
This post is a re-blog, the post originally was featured on The Tech Scoop, you can read it here : http://thetechscoop.net/2013/07/24/web-notifications-osx-mavericks/