# How to integrate Apple Pay in Bubble

- Tool: Bubble
- Difficulty: Beginner
- Time required: 20-25 min
- Compatibility: All Bubble plans (Stripe account required)
- Last updated: March 2026

## TL;DR

Accept Apple Pay in your Bubble app through Stripe's Payment Request Button. Enable Apple Pay in your Stripe Dashboard, verify your domain, then use the Stripe plugin's payment element or a custom Stripe Checkout session. Apple Pay appears automatically on supported devices (Safari on Mac/iOS) when configured through Stripe — no separate Apple Pay integration is needed.

## Integrate Apple Pay in Your Bubble App via Stripe

This tutorial walks you through accepting Apple Pay payments using Stripe. Since Stripe handles Apple Pay natively through its payment elements, you do not need a separate Apple Pay integration — Stripe detects supported devices and shows the Apple Pay button automatically.

## Before you start

- A Bubble account with an existing app
- A Stripe account with payments enabled
- The Bubble Stripe plugin installed
- A custom domain (required for Apple Pay domain verification)

## Step-by-step guide

### 1. Enable Apple Pay in Stripe Dashboard

Log into Stripe Dashboard → Settings → Payment methods. Find Apple Pay and enable it. Go to Settings → Apple Pay → '+ Add new domain'. Enter your Bubble app's custom domain. Stripe will ask you to host a verification file at /.well-known/apple-developer-merchantid-domain-association. Download this file and host it on your domain (through Bubble's static file hosting or your CDN).

> Pro tip: Apple Pay requires HTTPS and a custom domain. It does not work on Bubble's default *.bubbleapps.io subdomain in production.

**Expected result:** Apple Pay is enabled in Stripe and your domain is verified.

### 2. Configure the Stripe Plugin for Apple Pay

In your Bubble editor, go to Plugins → Stripe plugin settings. Ensure your publishable and secret keys are entered. The Stripe plugin's Checkout or Payment Element automatically includes Apple Pay when the customer's device supports it. No additional configuration is needed within Bubble.

**Expected result:** Stripe plugin is configured and ready to show Apple Pay on supported devices.

### 3. Implement the Payment Flow

On your checkout page, add a Button labeled 'Pay Now'. Create a workflow: When Pay Now clicked → Stripe Checkout (or Create Payment Intent). Set the amount, currency, and description. When the Stripe Checkout page loads on an Apple device with Apple Pay configured, it automatically shows the Apple Pay option alongside card payment. Users tap Apple Pay, authenticate with Face ID or Touch ID, and the payment completes.

**Expected result:** Users on Apple devices see and can use Apple Pay during checkout.

### 4. Test Apple Pay in Stripe Test Mode

Switch Stripe to Test mode. On a Mac with Safari, or an iPhone with a test card configured in Apple Wallet, visit your checkout page. Apple Pay should appear as an option. Use Stripe's test card numbers for Apple Pay testing. Check the Stripe Dashboard → Payments to verify test transactions. Note: testing requires an actual Apple device — it cannot be tested in Chrome or on Windows.

**Expected result:** Apple Pay works correctly in Stripe's test environment on Apple devices.

### 5. Handle Payment Confirmation

After successful Apple Pay payment, Stripe fires a webhook (checkout.session.completed or payment_intent.succeeded). Create a backend workflow that handles this event: update the order status, send a confirmation email, and grant access to purchased content. The flow is identical to regular card payment handling — Apple Pay is just another payment method in Stripe.

**Expected result:** Successful Apple Pay payments update order status and trigger confirmation workflows.

## Complete code example

File: `Workflow summary`

```text
APPLE PAY SETUP CHECKLIST:

1. STRIPE DASHBOARD
   → Settings → Payment methods → Enable Apple Pay
   → Settings → Apple Pay → Add domain → Verify
   → Download domain verification file
   → Host at: yourdomain.com/.well-known/apple-developer-merchantid-domain-association

2. BUBBLE STRIPE PLUGIN
   → Enter publishable key (pk_test_ or pk_live_)
   → Enter secret key (sk_test_ or sk_live_)
   → No additional Apple Pay config needed

3. CHECKOUT WORKFLOW
   When Pay Now clicked:
   → Stripe Checkout (amount, currency, success_url, cancel_url)
   → Apple Pay appears automatically on supported devices

4. WEBHOOK HANDLING
   On checkout.session.completed:
   → Find order by session ID
   → Update status to 'paid'
   → Send confirmation email

5. TESTING
   → Use Stripe Test mode
   → Test on Safari (Mac) or iPhone
   → Verify in Stripe Dashboard → Payments

SUPPORTED DEVICES:
- iPhone (Safari) with cards in Apple Wallet
- iPad (Safari)
- Mac (Safari) with Touch ID or paired iPhone
- Apple Watch (via paired iPhone)
```

## Common mistakes

- **Trying to use Apple Pay on Bubble's default subdomain** — Apple Pay requires a verified custom domain. It will not work on *.bubbleapps.io. Fix: Set up a custom domain for your Bubble app and verify it in Stripe's Apple Pay settings.
- **Building a separate Apple Pay integration instead of using Stripe** — Apple Pay integration is complex (certificates, merchant IDs, session handling). Stripe handles all of this. Fix: Use Stripe's built-in Apple Pay support. It automatically appears on supported devices with zero additional code.
- **Testing Apple Pay on Chrome or Windows** — Apple Pay only works in Safari on Apple devices. It will not appear on other browsers or operating systems. Fix: Test on an actual iPhone, iPad, or Mac using Safari.

## Best practices

- Use Stripe Checkout or Payment Elements which automatically include Apple Pay on supported devices.
- Verify your custom domain in Stripe's Apple Pay settings before going live.
- Test on actual Apple devices — emulators and non-Safari browsers do not support Apple Pay.
- Treat Apple Pay transactions identically to card payments in your webhook handling.
- Show a 'Pay with Card' fallback for users without Apple Pay.
- Display the Apple Pay mark/logo according to Apple's brand guidelines.

## Frequently asked questions

### Do I need an Apple Developer account for Apple Pay?

Not when using Stripe. Stripe handles the Apple Pay merchant registration and certificates. You only need to verify your domain in Stripe's settings.

### Does Apple Pay work on Android devices?

No. Apple Pay is exclusive to Apple devices. For Android users, Google Pay is the equivalent — Stripe also supports Google Pay automatically through the same payment elements.

### Is there an additional fee for Apple Pay transactions?

No. Stripe charges the same processing fee regardless of whether the customer pays with Apple Pay or a regular card.

### Can I force Apple Pay to appear on all devices?

No. Apple Pay only appears on supported devices with cards configured in Apple Wallet. On unsupported devices, regular card payment is shown.

### How do refunds work with Apple Pay?

Refunds work identically to card refunds through Stripe. Refund via the Stripe Dashboard or API, and the amount is returned to the customer's Apple Pay card.

### Can RapidDev help set up payment processing?

Yes. RapidDev can configure Stripe with Apple Pay, Google Pay, and other payment methods, including webhook handling, subscription billing, and multi-currency support for your Bubble app.

---

Source: https://www.rapidevelopers.com/bubble-tutorial/integrate-apple-pay-in-bubble
© RapidDev — https://www.rapidevelopers.com/bubble-tutorial/integrate-apple-pay-in-bubble
