---
title: "What does storeProblemError (code 2) mean in the purchases SDK?"
description: "storeProblemError (code 2) means the App Store, Google Play or the payment system failed the request. It is usually temporary: retry once and read the underlying error."
url: https://revenuedot.app/docs/errors/sdk-store-problem-error
---

# What does storeProblemError (code 2) mean in the purchases SDK?

The purchases SDK raises storeProblemError (code 2) when the App Store or Google Play fails a request or the backend reports a store problem.

## Quick facts

| | |
|---|---|
| Error | `ErrorCode.storeProblemError` (iOS), `PurchasesErrorCode.StoreProblemError` (Android), code 2 |
| Where | Purchases SDK (iOS, Android and the hybrid SDKs built on them) |
| What the vendor says | There was a problem with the store. |

## Cause

- StoreKit 2: `StoreKitError.systemError`, `.notEntitled` and `.unknown`, and `Product.PurchaseError.invalidQuantity` all map here.
- Android: Play Billing `ERROR`, `SERVICE_UNAVAILABLE`, `SERVICE_DISCONNECTED` and `SERVICE_TIMEOUT` map here. Google describes `ERROR` as an internal Play problem and `SERVICE_DISCONNECTED` as a severed connection ([Google docs](https://developer.android.com/google/play/billing/errors)).
- The backend answered 7101 (store problem), or on Android 7229 (Play quota exceeded) or 7231 (Play generic error).

## Fix

1. Read the underlying error: `NSUnderlyingErrorKey` and `rc_backend_error_code` on iOS, `underlyingErrorMessage` on Android. They tell a StoreKit failure from a backend 7101.
2. Retry once after a short pause. Google recommends retries with backoff for `ERROR` and service disconnects.
3. Check that the store account on the device works: open the App Store or Google Play once and try again.
4. If the backend sent 7101, fix the store key or service account the message names, using Verify credentials on the app page.

## 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 .storeProblemError:
        // Retrying once is reasonable; never unlock until customer info shows the entitlement.
        print("The store had a problem; read the underlying error")
    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

A burst of storeProblemError usually means a store outage or a broken store credential on the server. See the [server error codes](https://revenuedot.app/docs/api/errors.md) for 7101. Deep dive: [revenuedot.app/errors/store-problem-error](https://revenuedot.app/errors/store-problem-error).

## Related

- [What does StoreKitError.systemError mean?](https://revenuedot.app/docs/errors/storekit-error-system-error.md)
- [What does Play Billing SERVICE_DISCONNECTED (-1) mean?](https://revenuedot.app/docs/errors/play-billing-service-disconnected.md)
- [What does Play Billing ERROR (6) mean?](https://revenuedot.app/docs/errors/play-billing-error.md)
- [What RevenueDot's API errors mean (server codes)](https://revenuedot.app/docs/api/errors.md)

## Source

- [RevenueDot purchases-ios: ErrorCode.swift (the iOS ErrorCode enum)](https://github.com/revenuedot/purchases-ios/blob/revenuedot/main-patches/Sources/Generated/ErrorCode.swift)
- [RevenueDot purchases-android: PurchasesErrorCode.kt (the Android enum)](https://github.com/revenuedot/purchases-android/blob/revenuedot/main-patches/purchases/src/main/kotlin/generated/com/revenuecat/purchases/PurchasesErrorCode.kt)
- [RevenueDot purchases-ios: StoreKitError+Extensions.swift](https://github.com/revenuedot/purchases-ios/blob/revenuedot/main-patches/Sources/Error%20Handling/StoreKitError%2BExtensions.swift)
- [RevenueDot purchases-android: google/errors.kt (Play Billing mapping)](https://github.com/revenuedot/purchases-android/blob/revenuedot/main-patches/purchases/src/main/kotlin/com/revenuecat/purchases/google/errors.kt)
- [RevenueDot purchases-ios: BackendErrorCode.swift (backend code mapping)](https://github.com/revenuedot/purchases-ios/blob/revenuedot/main-patches/Sources/Error%20Handling/BackendErrorCode.swift)

Checked: 2026-10-03
