What does offlineConnectionError (code 35) mean in the purchases SDK?
The purchases SDK raises offlineConnectionError (code 35) on iOS when a request fails because the device is not connected to the internet.
Quick facts#
| Error | ErrorCode.offlineConnectionError (iOS), no Android member, code 35 |
| Where | Purchases SDK (iOS, Android and the hybrid SDKs built on them) |
| What the vendor says | Error performing request because the internet connection appears to be offline. |
Cause#
- A request failed with the system's "not connected to the Internet" error, which the SDK maps to this error. It differs from
networkError, which covers every other network failure. - Airplane mode, no signal, Wi-Fi without internet, or cellular data blocked for the app.
- Android has no member for this code; the same situation raises an
IOException, which becomesNetworkError.
Fix#
- Show an offline state and keep the app usable with cached data.
- Retry offerings or customer info when your platform's reachability callback says the network is back.
- Keep gating features on the cached entitlement state the SDK already holds.
- On iOS, check that cellular data is allowed for the app in Settings.
Example#
Swift
// The purchases SDK throws `ErrorCode` values; match the one you handle and let the rest fall through.
func handle(_ error: Error) {
guard let code = error as? ErrorCode else {
print("Not a purchases SDK error: \(error)")
return
}
switch code {
case .offlineConnectionError:
// Offline is not a purchase failure: keep cached access and retry when the network returns.
print("You appear to be offline")
default:
print("Other purchases error: \(code.description)")
}
}Compile-checked: npm run check:snippets type-checks this snippet with swiftc together with the ErrorCode.swift file of the RevenueDot purchases-ios fork (checked 2026-10-03).
How the RevenueDot SDK reports it#
Customers who already paid keep the access the SDK cached, and a device that is offline never reaches RevenueDot. Deep dive: revenuedot.app/errors/offline-connection-error.
Related#
- What does networkError (code 10) mean in the purchases SDK?
- What does StoreKitError.networkError mean?
- What does Play Billing NETWORK_ERROR (12) mean?
- What RevenueDot's API errors mean (server codes)
Source#
- RevenueDot purchases-ios: ErrorCode.swift (the iOS ErrorCode enum)
- RevenueDot purchases-android: PurchasesErrorCode.kt (the Android enum)
- RevenueDot purchases-android: common/errors.kt (backend code mapping)
Checked: 2026-10-03