Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ You'll need to implement your own logic to handle the redirect and deep link use

## Setting Up Deep Links

Whether you're showing a checkout page in a browser or using the In-App Browser, the Superwall SDK relies on deep links to redirect back to your app.
Whether checkout starts from a web link or from a paywall that opens an external browser, the Superwall SDK relies on deep links to redirect back to your app.

#### Prerequisites
1. [Configuring Stripe Keys and Settings](/web-checkout/web-checkout-configuring-stripe-keys-and-settings)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@ Available tap actions are:
3. **Deep Link:** Similar to the **external** option, but it'll _close_ the paywall before opening the URL. This is useful for internal navigation or when you are attempting to link to something in a web page and you'd like the paywall to close when doing so.
- **Scroll To Element:** Scrolls the view to a specific element on the page.

<Warning>
For Stripe Checkout or other external purchase links on iOS, use the **External** option. Do not use the in-app browser option for purchase flows.
</Warning>

**State & Variables**

- **Update Variable:** Sets or updates an existing variable's value. Options specific to the variable type will also be displayed. For example, a **Number** variable will have an option to choose an **Operation** such as Set, Increment or Decrement. Or, a **Boolean** variable's **Operation** will offer to either **Set** or **Toggle** the boolean value.
Expand Down
27 changes: 0 additions & 27 deletions content/docs/dashboard/guides/using-stripe-checkout-in-app.mdx

This file was deleted.

1 change: 0 additions & 1 deletion content/docs/dashboard/meta.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
"---Guides---",
"guides/superwall-skill",
"guides/superwall-mcp",
"guides/using-stripe-checkout-in-app",
"guides/migrating-from-revenuecat-to-superwall",
"guides/pre-launch-checklist",
"guides/using-superwall-for-onboarding-flows",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ You'll need to implement your own logic to handle the redirect and deep link use

## Setting Up Deep Links

Whether you're showing a checkout page in a browser or using the In-App Browser, the Superwall SDK relies on deep links to redirect back to your app.
Whether checkout starts from a web link or from a paywall that opens an external browser, the Superwall SDK relies on deep links to redirect back to your app.

#### Prerequisites
1. [Configuring Stripe Keys and Settings](/web-checkout/web-checkout-configuring-stripe-keys-and-settings)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ You'll need to implement your own logic to handle the redirect and deep link use

## Setting Up Deep Links

Whether you're showing a checkout page in a browser or using the In-App Browser, the Superwall SDK relies on deep links to redirect back to your app.
Whether checkout starts from a web link or from a paywall that opens an external browser, the Superwall SDK relies on deep links to redirect back to your app.

#### Prerequisites
1. [Configuring Stripe Keys and Settings](/web-checkout/web-checkout-configuring-stripe-keys-and-settings)
Expand Down
2 changes: 1 addition & 1 deletion content/docs/integrations/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ The `data` field contains detailed information about the subscription or payment
| `expirationReason` | string (optional) | Reason for expiration (see [Cancel Reasons](#cancelexpiration-reasons)) |
| `checkoutContext` | object (optional) | Stripe-specific checkout context |

**Note on Store field:** iOS and Android apps can receive events from any payment provider. For example, an iOS app can receive `STRIPE` events when users purchase through Superwall's App2Web features, which allow web-based checkout flows within mobile apps. The `store` field indicates where the payment was processed, not which platform the app runs on.
**Note on Store field:** iOS and Android apps can receive events from any payment provider. For example, an iOS app can receive `STRIPE` events when users purchase through Superwall's App2Web features, which can start from a mobile paywall and complete in an external browser. The `store` field indicates where the payment was processed, not which platform the app runs on.

## Event Names

Expand Down
2 changes: 1 addition & 1 deletion content/docs/integrations/webhooks/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ The `data` field contains detailed information about the subscription or payment
| `checkoutContext` | object (optional) | Stripe-specific checkout context |
| `userAttributes` | object (optional) | Custom user attributes set via the SDK (see [User Attributes](#user-attributes)) |

**Note on Store field:** iOS and Android apps can receive events from any payment provider. For example, an iOS app can receive `STRIPE` events when users purchase through Superwall's App2Web features, which allow web-based checkout flows within mobile apps. The `store` field indicates where the payment was processed, not which platform the app runs on.
**Note on Store field:** iOS and Android apps can receive events from any payment provider. For example, an iOS app can receive `STRIPE` events when users purchase through Superwall's App2Web features, which can start from a mobile paywall and complete in an external browser. The `store` field indicates where the payment was processed, not which platform the app runs on.

## Event Names

Expand Down
2 changes: 1 addition & 1 deletion content/docs/web-checkout/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ Before you start, you'll need to have a Superwall account and a Stripe account.

### App to Web

9. **[App to Web Checkout](/web-checkout/web-checkout-direct-stripe-checkout):** For customers in the United States, you can offer Stripe products directly from your iOS paywalls.
9. **[App to Web Checkout](/web-checkout/web-checkout-direct-stripe-checkout):** For U.S. storefront customers, you can link from your iOS paywalls to Stripe checkout in Safari or the user's default browser.

## Troubleshooting
If a user has issues accessing their purchase in your app after paying via web checkout, direct them to your plan management page to retrieve their redemption link or manage billing. For example: `http://yourapp.superwall.app/manage`
27 changes: 13 additions & 14 deletions content/docs/web-checkout/web-checkout-direct-stripe-checkout.mdx
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
---
title: "App2Web"
description: "Offer Stripe products directly from your iOS paywalls and perform checkout flows."
description: "Link U.S. customers from iOS paywalls to Safari for Stripe checkout."
---

For customers in the United States, you can offer Stripe products directly from your iOS paywalls. This is a great way to streamline the checkout process and make it easier for users to purchase your products.
For customers on the United States App Store storefront, you can add calls to action in your iOS paywalls that open Stripe checkout outside of your app in Safari or the user's default browser.

Do not present Stripe Checkout inside your iOS app using an in-app browser, `SFSafariViewController`, `WKWebView`, or another embedded web view. For external purchase links, the checkout flow should leave the app and open in the external browser.

<Note>
Apple's App Review Guidelines allow United States storefront apps to include buttons, external links, or calls to action for purchase methods other than in-app purchase. Review [Guideline 3.1.1(a)](https://developer.apple.com/app-store/review/guidelines/#business) before submitting your app.
</Note>

<Frame>![](/images/web_checkout_direct_to_stripe.jpg)</Frame>

Expand All @@ -12,28 +18,21 @@ For customers in the United States, you can offer Stripe products directly from
First, follow the [web checkout setup guide](/web-checkout#getting-setup) to create a Stripe app and configure your web checkout settings. Specifically, you'll need to complete the first three steps. This includes installing the [Superwall Stripe app](https://marketplace.stripe.com/apps/superwall) and setting up your app's settings.
</Step>
<Step title="Add a Stripe product to an iOS paywall">
Select a paywall and add a Stripe product to it. This will allow users to purchase the product directly from the paywall. Stripe products are prepended with "stripe" in the product selector:
Select a paywall and add a Stripe product to it. This lets users start an external browser checkout flow from the paywall. Stripe products are prepended with "stripe" in the product selector:

<Frame>![](/images/web-checkout-select-product.png)</Frame>
</Step>
<Step title="Choose Web Checkout Location">
You can control whether or not Stripe checkout opens in your app via Safari, or externally in the Safari app:

<Frame>![](/images/web-checkout-location.png)</Frame>
<Step title="Create a campaign for U.S. customers">
Since the policy applies to customers on the United States storefront, create a campaign filter that matches those customers. Use `storeFrontCountryCode` equals `USA`, like this:

<Note>
**App Store Review Tip:** If you choose the in-app sheet option, we strongly suggest showing your Stripe purchase experience to Apple during an App Review before testing with users. We recommend adding the following to your App Review notes:

> US users will be able to purchase subscriptions or one-time products using Stripe. These users are filtered using their registered App Store country. All other countries will only be able to purchase using Apple IAPs. You can test this by switching your device's registered App Store country.
For App Review, explain that U.S. storefront customers can tap a paywall call to action that opens an external browser for Stripe checkout. Non-U.S. storefront customers should continue using Apple in-app purchase unless another regional policy applies.
</Note>
</Step>
<Step title="Create a campaign for U.S. customers">
Since the ruling only applies to customers in the United States, you can easily create a campaign filter that will match to those customers. Just create a filter where `storeFrontCountryCode` matches `USA`, like this:

<Frame>![](/images/web-checkout-app2web-campaign-filter.png)</Frame>
</Step>
<Step title="Respond to Checkout">
From there, the flow works the same way as it would for web checkout. Once the payment succeeds, the [Superwall delegate](/sdk/guides/using-superwall-delegate) functions `willRedeemLink()` and `didRedeemLink(result:)` will be called. You can use these functions to handle the deep link in your app if you need to show any specific UI as described in our [Post-Checkout Redirecting](/sdk/guides/web-checkout/post-checkout-redirecting) docs.
From there, the flow works the same way as web checkout. Once the payment succeeds in the external browser, the [Superwall delegate](/sdk/guides/using-superwall-delegate) functions `willRedeemLink()` and `didRedeemLink(result:)` will be called when the user returns through the deep link. You can use these functions to show any specific UI as described in our [Post-Checkout Redirecting](/sdk/guides/web-checkout/post-checkout-redirecting) docs.

Additionally, entitlement and subscription status will update automatically. For lifetime one-time products, the linked entitlement becomes active without an expiration. For consumables, inspect `CustomerInfo.nonSubscriptions` and grant the purchased quantity in your own system. If you're using a `PurchaseController`, refer to [the docs here](/sdk/guides/web-checkout/linking-membership-to-iOS-app#using-a-purchasecontroller).
</Step>
Expand Down
2 changes: 1 addition & 1 deletion content/docs/web-checkout/web-checkout-sdk-setup.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,4 @@ You'll also need the Superwall SDK integrated in your app.
## Further reading

- [Web Checkout FAQ](/web-checkout/web-checkout-faq)
- [App to Web Checkout](/web-checkout/web-checkout-direct-stripe-checkout) — Offer Stripe products directly from your iOS paywalls
- [App to Web Checkout](/web-checkout/web-checkout-direct-stripe-checkout) — Link U.S. storefront customers from iOS paywalls to Stripe checkout in Safari
2 changes: 1 addition & 1 deletion content/shared/web-checkout/post-checkout-redirecting.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ You'll need to implement your own logic to handle the redirect and deep link use

## Setting Up Deep Links

Whether you're showing a checkout page in Safari or using the In-App Browser, the Superwall SDK relies on deep links to redirect back to your app.
Whether checkout starts from a web link or from an iOS paywall that opens Safari, the Superwall SDK relies on deep links to redirect back to your app.

#### Prerequisites
1. [Configuring Stripe Keys and Settings](/web-checkout/web-checkout-configuring-stripe-keys-and-settings)
Expand Down
6 changes: 4 additions & 2 deletions redirects-map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,10 @@ export const fileRedirectsMap = {
"tips-first-touch-paywall": "dashboard/guides/tips-first-touch-paywall",
"tips-paywalls-feature-gating": "dashboard/guides/tips-paywalls-feature-gating",
"tips-using-custom-actions": "dashboard/guides/tips-using-custom-actions",
"dashboard/guides/using-stripe-bottom-sheet-checkout-in-app": "dashboard/guides/using-stripe-checkout-in-app",
"using-stripe-bottom-sheet-checkout-in-app": "dashboard/guides/using-stripe-checkout-in-app",
"dashboard/guides/using-stripe-checkout-in-app": "web-checkout/web-checkout-direct-stripe-checkout",
"using-stripe-checkout-in-app": "web-checkout/web-checkout-direct-stripe-checkout",
"dashboard/guides/using-stripe-bottom-sheet-checkout-in-app": "web-checkout/web-checkout-direct-stripe-checkout",
"using-stripe-bottom-sheet-checkout-in-app": "web-checkout/web-checkout-direct-stripe-checkout",

// Dashboard / Web Checkout
"web-checkout-overview": "web-checkout",
Expand Down
Loading