Skip to main content

Offline and connectivity behavior

The Atomic SDK is designed to handle intermittent or unavailable network connectivity gracefully, minimizing disruption to the user experience. This page describes the behavior of the SDK when network connectivity is unavailable or unreliable.

Initial loading

When the SDK attempts to load a stream container for the first time and there is no network connection available:

  • Vertical containers display an error message with a retry button. By default this message reads "No internet connection", but you can customize this string via each SDK's configuration options. See the custom error messages section below for details.
  • Single card views collapse to a height of 0 — nothing is displayed to the user.
  • Horizontal containers display the card list header if the card list header is enabled; otherwise they collapse to a height of 0.
  • Modal containers display nothing — because nothing is rendered, the underlying UI is not blocked.

Cards already visible

If cards are already loaded and visible when connectivity is lost, the SDK does not immediately switch to an error state. The existing cards remain visible to minimize disruption.

The container will transition to an error or empty state only when:

  • The host app manually triggers a refresh of the container, or
  • An HTTP polling request fails (when the SDK is using HTTP polling instead of WebSockets).

This approach keeps the UI as undisruptive as possible when connectivity is temporarily unavailable.

Subviews

Users can open and interact with card subviews without an active network connection. Subviews are rendered from content that has already been loaded, so they remain accessible offline.

Card actions

When a user performs a card action (such as dismissing, completing, snoozing, or voting on a card) while offline, the action fails. The SDK provides visible feedback:

  • The action fails with an obvious animation.
  • By default, a toast message is shown at the bottom of the screen informing the user of the failure. The host app can disable toast messages via the SDK configuration if desired.

Actions are not queued for retry once connectivity is restored — they are fire-and-forget. If a user wants to perform the action after connectivity returns, they must do so manually.

Custom error messages

Each SDK allows you to customize the error message displayed when the user has no internet connection. Refer to the relevant SDK guide for details:

  • iOS (SwiftUI) — configure .noInternetConnectionMessage in your AACConfiguration. See iOS SwiftUI SDK.
  • iOS (Legacy) — configure AACCustomStringNoInternetConnectionMessage using setValue:forCustomString: on AACConfiguration. See iOS SDK (Legacy).
  • Android — configure noInternetMessage in your stream container configuration. See Android SDK.
  • Android Jetpack Compose — configure noInternetMessage in your stream container configuration. See Android Compose SDK.
  • React Native — configure noInternetConnectionMessage in your stream container configuration. See React Native SDK.
  • Flutter — configure AACCustomString.noInternetConnectionMessage in your AACConfiguration. See Flutter SDK.
  • Web — configure noInternetConnectionMessage in the custom strings of your container configuration. See Web SDK.

Analytics

Analytics events are not discarded when the user is offline. If analytics events cannot be sent because connectivity is unavailable, they are retained and resent on the next 30-second interval once connectivity is restored. For more information, see SDK analytics.