During Apple’s annual Worldwide Developer Conference (WWDC) this past June, the company announced plans to roll out an exciting new iOS feature: Live Activities. Since the ActivityKit Beta Framework was released late last month, we’ve been working hard to architect support for Live Activities to make it easier for our users to create, customize, and manage Live Activities from the OneSignal dashboard once the feature becomes available.

What are Live Activities?

Live Activities are a type of interactive push notification. They were designed by Apple to enable iOS apps to provide real-time updates to their users that are visible from the lock screen.

Left: A Live Activity showing an Uber driver's progress and estimated ETA. Right: A Live Activity showing the current score, inning, and pitch count for a live baseball game.

Live Activities vs Widgets

Unlike Widgets, Live Activities live exclusively on the lock screen and can only last up to eight hours. They are intended to display changing data for live events such as sports scores, delivery statuses, and other real-time transactional updates.

A Live Activity for a fitness app showing a user's current run time and distance.

In contrast, Widgets can permanently live on the home screen and aren't necessarily associated with a particular live event. Although they are implemented similarly, Widgets are permanent features that require less lifecycle management. Whereas Live Activities are associated with push notifications, Widgets are not.

Using Live Activity Notifications to Enhance Your App UX

Many apps send real-time transactional updates via push notification to keep users informed and create a more seamless experience after a user has exited their app. For instance, a food delivery app might send push notifications with live order status updates, a Rideshare app might send notifications when a driver is approaching, and a sports media app might send score updates at different intervals during a live game.

A Live Activity showing the current score, quarter, game clock, and other series details for a live NBA game.

Rather than sending a new notification each time there is a status update, the new Live Activities feature allows app developers to update a single, interactive notification for the duration of the live event. This ultimately creates a cleaner, simpler, and more intuitive user experience by reducing the number of notifications sent while also making information more readily accessible.

A Live Activity tracking the progress of a Starbucks in-store pickup order.

Beyond food delivery and media events, Live Activities can be a valuable feature for many app categories. For instance, this feature might be used by digital wallets and crypto apps to provide users with real-time price changes and trade updates, or used by mobile games to showcase a live game event.

When will this feature be publicly available?

Live Activities are now available in the Beta 4 version of iOS 16. Apple announced that Live Activities will not be available upon the initial release of iOS 16, which is expected in September 2022, but will be publicly available as an update in late 2022.

Discoveries from the iOS 16 Beta 4 Release

As we work to implement support for Live Activities, we’ve discovered a few things about this new iOS feature. Here's what we learned:

  • Live Activities currently cannot be launched from the background, so the user will need to have an app open in order to start the Activity.
  • If your app supports Live Activities, when a user accepts the permission prompt to allow push notifications, the Live Activities capability will be enabled by default. This can be changed by the user in the iOS Settings app.
  • An app can define multiple Live Activities with different interfaces and content states using a WidgetBundle.
  • An App can have multiple Live Activities running simultaneously. For instance, if a user follows two different sports teams, they might have multiple Live Activities on their lock screen for different live games. These activities can be stacked and expanded upon user interaction.
  • Live Activity interfaces can't contain interactable elements such as buttons and web views. Instead, when a Live Activity is tapped, your application will be launched. You can, however, still load images from a URL on demand into your Live Activity. The image URL could be part of the activity content that changes.

How to Create Live Activities for iOS 16+

Live Activities are created in a Widget Extension (Widgets were released with iOS 14) for your iOS application. If you already have a Widget in your iOS application, you can create Live Activities alongside it in the same extension using a WidgetBundle. If you don’t yet have a Widget in your iOS App, you can create a Widget Extension and build your Live Activity using SwiftUI and the new ActivityKit library. When doing so, your app will define attributes for the activity that dictates both the static and mutable content for your activity. Live Activities can then be started, updated, and ended by your application when appropriate. Your Live Activity interface cannot contain any interactable elements and tapping on the Live Activity will launch your application.

The data in your Live Activities can also be updated via remote push notifications. To update or end a Live Activity with a push notification, your app must first request a push token for the Live Activity and send it to your push server. You can then use the push token to send notifications to the Live Activity that specify its new “content-state.” These push tokens are only valid for the duration of the Live Activity, and each Live Activity will receive a unique token. For more details on implementing Live Activities and updating them with push notifications visit Apple’s documentation.

Managing Live Activities with OneSignal

We have built a solution to simplify Live Activity push token management and make it easier to customize Live Activities from the OneSignal dashboard for different use cases. You can contact our team for a demo or get started today by following our documentation on Live Activities.

Click the link below to speak with our team to discuss how we can help bring your ideal use case to life.

Chat With an Expert