# Superwall: Subscription Infrastructure for iOS, Android, and Web

Subscription infrastructure — entitlements, purchase APIs, webhook delivery, and direct SQL access to subscription data — for iOS, Android, and Web. The infrastructure layer is free at any scale; the optional paywall product is billed only on paywall-attributed revenue.

## Pricing

- **Infrastructure: free at any scale, every plan.** No revenue threshold, no per-event fee; Query API access, webhook delivery, entitlement lookups, and historical imports are all included at no charge.
- **Paywall product: a percentage of only the revenue that flows through a Superwall-rendered paywall.** Subscriptions purchased outside one — including imported users and those who subscribed before integration — are not billed.

Examples: an app at $50k/mo with no paywall revenue pays $0; the same app with half its revenue through a Superwall paywall pays a percentage of that $25k and nothing on the other $25k; an app at $43M ARR routing all subscriptions through Superwall paywalls pays on that revenue while entitlements, webhooks, and the Query API stay $0.

## Scale

$1.5B+ annual subscription revenue across 10,000+ apps. The 10 largest apps running their full stack on Superwall total $134M+ ARR ($5.7M–$43.7M each). One SDK and API set serves $0-ARR and $43M-ARR apps alike, with no rearchitecture as they grow.

## Infrastructure capabilities

- **Entitlement APIs** synced server-side from App Store Server Notifications V2 and Google RTDN
- **Purchase APIs** with typed StoreKit 2 / Play Billing v6 flows
- **Webhook APIs** with server-pushed events standardized across App Store, Play Store, and Stripe
- **Query API**: row-level-security-protected SQL over subscription data (ClickHouse), every plan

Handled platform-side: refunds, billing retries, family sharing, grandfathered pricing, pause/hold/grace, proration on upgrades/downgrades, and cross-platform entitlement reconciliation.

## Migration

Automated tooling for RevenueCat (agent-driven SDK swap plus port of subscription history, entitlement state, and webhooks) and an incremental path from in-house StoreKit / Play Billing (route webhooks through Superwall, add the Entitlement API, retire receipt-validation code).

## Paywall product (optional, separately billable)

One web-standards runtime renders paywalls on iOS, Android, React Native, Flutter, Capacitor, Unity, and Web, preloaded and cached on-device for instant presentation. Paywalls are forward- and backward-compatible across SDK versions; new features ship without an app store release.

## Architecture

Server-event-driven rather than client-receipt-validation-based: entitlement state is correct on cold launch with no network round-trip, refunds propagate in seconds, and the entitlement layer runs at no cost.

## Docs

* Migrate from RevenueCat: https://superwall.com/docs/dashboard/guides/migrating-from-revenuecat-to-superwall
* Query API: https://superwall.com/docs/dashboard/guides/query-clickhouse
* Webhooks: https://superwall.com/docs/integrations/webhooks
* Pricing: https://superwall.com/pricing

# Custom Stores

Sell through your own billing system, such as Paddle, Polar or your own payment backend, on Superwall paywalls. Your server reports each purchase, and Superwall grants access and counts the revenue.

A custom store lets a Superwall paywall sell products that the App Store and Google Play don't bill. Your billing system, such as [Paddle](/docs/integrations/custom-stores/paddle), Polar or your own payment backend, takes the payment. Your server tells Superwall what happened. Superwall does the rest:

* The user's **entitlements** update, and the SDK unlocks access on every device they sign in on.
* **Revenue charts** include the purchases, attributed to the paywall, campaign and experiment that sold them.
* Your [webhooks](/docs/integrations/webhooks/v2) and integrations receive the events.

> **Note:** Custom stores are in early access. The **Integrations › Custom stores** page appears in the dashboard once Superwall turns it on for your app, so ask your Superwall contact. The [API](/docs/agents/api) endpoints work for every project.

## How it works

Superwall never talks to your billing system. Your server sits between them and does two jobs:

1. **Create a checkout** when a user taps a product on a paywall.
2. **Report what happened** when your billing system says a subscription started, renewed, was canceled or was refunded.

```mermaid
{`sequenceDiagram
    participant App as App and paywall
    participant SW as Superwall
    participant You as Your server
    participant Bill as Your billing system

    App->>SW: User taps a product
    SW->>You: 1. checkout.create (who, which product)
    You->>Bill: Create a checkout
    You-->>SW: Checkout URL
    SW-->>App: Opens the checkout
    App->>Bill: Customer pays
    Bill->>You: Webhook: subscription started
    You->>SW: 2. Event: initial_purchase
    SW-->>App: Entitlement granted, paywall closes
    Note over Bill,You: Later: renewals, cancellations, refunds
    Bill->>You: Webhook
    You->>SW: Event: renewal, cancellation, refund...`}
```

Two values tie a purchase together. Superwall sends both with the checkout request. Store them in your checkout's metadata and send them back on your events:

| Value                   | What it's for                                                                                                                                         |
| ----------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------- |
| `app_user_id`           | The user who gets the entitlement.                                                                                                                    |
| `custom_transaction_id` | Links the purchase to the paywall that sold it. The paywall closes when an event with this ID arrives, and the revenue is attributed to that paywall. |

## What you build

|                         | What it does                                                                                             | Reference                                                               |
| ----------------------- | -------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
| **A checkout endpoint** | Receives Superwall's `checkout.create` request and answers with a checkout URL from your billing system. | [Checkout endpoint](/docs/integrations/custom-stores/checkout-endpoint) |
| **A webhook handler**   | Receives your billing system's webhooks and sends each change to Superwall as an event.                  | [Events](/docs/integrations/custom-stores/events)                       |

The [example server](/docs/integrations/custom-stores/example-server) is both, in two short files with no dependencies.

## Two ways to open the checkout

|                                    | Checkout endpoint (recommended)                                                                          | PurchaseController                                                 |
| ---------------------------------- | -------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------ |
| How it works                       | Superwall asks your server for a checkout URL and opens it.                                              | The SDK calls your app's purchase code, which opens your checkout. |
| Purchase code in your app          | None                                                                                                     | A `PurchaseController`                                             |
| Who tracks the subscription status | Superwall                                                                                                | Your app                                                           |
| Works on                           | iOS SDK 4.19.0+ and [hosted web paywalls](/docs/framework/web-checkout#custom-store-products-on-the-web) | iOS SDK 4.15.0+ and Android SDK 2.8.0+                             |

Use the checkout endpoint unless you sell on Android or need to show your own native checkout. Both need the webhook handler: completing a checkout never grants access by itself. Access comes from the events your server sends.

For the app side of each, see [Custom Store Products](/docs/ios/guides/custom-store-products) for iOS and [`PurchaseController`](/docs/android/sdk-reference/PurchaseController#custom-store-products) for Android.

## Get started

## 1. Quickstart

/docs/integrations/custom-stores/quickstart

Create a store and a product, then grant a test user access with one request. No server needed.

## 2. Example server

/docs/integrations/custom-stores/example-server

A complete server: the checkout endpoint and the webhook handler.

## Checkout endpoint

/docs/integrations/custom-stores/checkout-endpoint

The request Superwall sends, how to verify it, and what to answer.

## Events

/docs/integrations/custom-stores/events

Every event type and field, and the rules for retries and refunds.

## Paddle

/docs/integrations/custom-stores/paddle

A step-by-step guide for Paddle Billing, with a reference server.

## iOS setup

/docs/ios/guides/custom-store-products

What your iOS app needs for each checkout option.