Back to Blog
Headless19 June 20267 min read · 1,485 words

Apple Pay Google Pay eCommerce 2026: Native vs Headless Guide

N7

No7 Engineering Team

Growth Architecture Unit

Headless — Apple Pay Google Pay eCommerce 2026: Native vs Headless Guide — illustration

Deploying native wallets is the most critical conversion driver for modern checkouts, but implementing apple pay google pay ecommerce 2026 patterns requires navigating complex decryption handshakes and platform-specific verification. While standard Shopify Liquid paths handle this out of the box, headless custom storefronts demand manual domain validation and direct Storefront API mutations to prevent checkout drop-off.

Why native wallets fail on custom storefronts

When merchants migrate from standard Liquid themes to custom headless setups, they often expect payment sheets to work out of the box. In our experience, this is where the most critical checkout drop-offs occur. In a standard Liquid theme, Shopify injects the required scripts and handles domain verification automatically. When you move to a headless architecture, that automation is lost.

You must now manually manage the browser-side detection of Apple Pay and Google Pay. If a buyer is on Safari on iOS, the Apple Pay button must be rendered; if they are on Chrome on Android, Google Pay takes precedence. If your headless storefront fails to detect these device-side wallets correctly, buyers are forced to manually enter their 16-digit card numbers, causing conversion rates to plummet. For a comprehensive overview of how these architectures compare, you can read our headless commerce practical guide.

We built several custom React components for Next.js and Hydrogen to address this exact issue. The trade-off is clear — while a custom storefront gives you total design control, you pay for it with significant engineering overhead to replicate the simple, native payment flows. If your store's annual GMV is under £1M, going headless solely for aesthetic control is rarely worth the ongoing maintenance burden.

How to set up apple pay google pay on custom storefront?

Configuring the merchant credentials is the first point of failure. For Apple Pay, you cannot simply use a generic merchant identifier. You must register an Apple Merchant ID in your Apple Developer account and generate an Apple Pay Payment Processing Certificate. Unlike the standard Apple process where you manage keys locally, Shopify requires you to generate a Certificate Signing Request (CSR) directly through the REST Admin API and upload the signed certificate back to Shopify.

This process requires the write_mobile_payments and read_mobile_payments access scopes on your Admin API token. Once the certificate is uploaded, you must verify your custom storefront's domain. Apple Pay requires hosting a domain association file at a specific path: /.well-known/apple-developer-merchantid-domain-association. If your headless frontend is hosted on Vercel or Cloudflare Pages, your routing config must serve this static text file without altering its headers.

For Google Pay, the configuration relies on the Google Pay API. You must configure the merchantInfo block with your Google Merchant ID, which is obtained via the Google Pay Business Console. During local development, you can use the test environment where Google returns dummy tokens, but moving to production requires registering your production domain with Google and passing their brand guidelines audit. This complexity is one reason why many merchants evaluate robust payment processors, as detailed in our Adyen vs Stripe UK Plus payment guide.

The Storefront API wiring for headless apple pay shopify

Once the frontend detects wallet availability, the checkout payload must be structured to match Shopify's GraphQL expectations. Under the hood, your custom storefront handles cart mutations using the Storefront API. When a buyer triggers the Apple Pay sheet, the browser's PaymentRequest API returns an encrypted payment token.

To process this, you must query the Shop object in the Storefront API to verify that APPLE_PAY is returned in the supportedDigitalWallets array of the PaymentSettings object. The DigitalWallet enum in the Storefront API includes APPLE_PAY, GOOGLE_PAY, ANDROID_PAY, and SHOPIFY_PAY. If supported, you construct a cartPaymentUpdate mutation.

The payload must include a CartPaymentInput object, which accepts a walletPaymentMethod field. For Apple Pay, this nested input is mapped via ApplePayWalletContentInput, which accepts billingAddress and data fields. The billing address must be strictly formatted to match Shopify's MailingAddressInput schema, while the raw encrypted payload from Apple maps to the data field. Additionally, you must populate the ApplePayWalletHeaderInput input object, which contains ephemeralPublicKey and publicKeyHash fields. This structure allows Shopify's backend to decrypt the PassKit payment data securely.

Google Pay tokenizationSpecification and merchantInfo mechanics

Google Pay operates slightly differently because it relies on a gateway tokenization model. Instead of Shopify decrypting the raw payload, Google Pay encrypts the payment credentials using your payment gateway's public key. If you are using Stripe as your gateway, your frontend must configure the tokenizationSpecification block to point to Stripe.

According to the Google Pay PaymentDataRequest specification, you must define the gateway parameter as stripe and pass your Stripe publishable key in the parameters object. This ensures that the token returned by the Google Pay sheet is directly compatible with Stripe's API. This pattern is critical for maintaining clean payment routing without adding custom decryption servers.

Our engineers measured that this tokenization handshake typically adds around 150-250ms of latency on mobile connections, which is why optimising your frontend bundle size is critical. In our work with Plus merchants, we have found that delaying the loading of the Google Pay JS library until the product detail page (PDP) or cart page actually enters the viewport can reduce your Interaction to Next Paint (INP) by up to 35-55%. If you load the heavy Google Pay scripts eagerly on the homepage, your mobile pagespeed scores will suffer.

Handling fallback patterns when digital wallets are unavailable

Digital wallets will fail to load in several standard scenarios. If the buyer is browsing in an incognito window, using a desktop browser without a paired device, or accessing your store from an unsupported region, the payment buttons must gracefully degrade. If your custom storefront displays a broken or unclickable Apple Pay button, it alienates the user.

To prevent this, always wrap your wallet initialisation in a capability check. For Apple Pay, verify window.ApplePaySession && ApplePaySession.canMakePayments() before rendering the button. For Google Pay, use the isReadyToPay() method provided by the Google Pay client library. If these checks return false, your UI must fallback to standard credit card inputs or accelerated options like Shop Pay.

Wallet Integration Decision Matrix

Choose your architecture based on GMV, engineering capacity, and compliance requirements:

RequirementNative Checkout RedirectFully Headless Checkout
PCI-DSS ComplianceHandled entirely by Shopify (SAQ-A)Merchant responsibility (SAQ A-EP / D)
Domain VerificationAutomatic on myshopify.com domainsManual verification file hosting
Engineering EffortLow — native configurationHigh — custom API wiring & encryption

Additionally, you can use Shopify Functions to control which payment methods are displayed on the backend. You can activate a maximum of 25 payment customization functions on each store, allowing you to hide, reorder, or rename payment methods dynamically. For instance, if a buyer's cart contains subscription items that require recurring billing, you can write a Function to hide Google Pay if your current gateway does not support recurring wallet tokens.

Comparing native Shopify checkout vs custom headless payment routing

Deciding between native Shopify checkout and a custom headless payment route is a fundamental architectural choice. If you use Shopify's native checkout, headless storefronts simply redirect the buyer to a checkoutUrl generated by the Storefront API. In this model, Shopify handles all the payment sheet complexities, PCI-DSS compliance, and domain verification on its own domain.

However, if you choose to build a fully custom checkout on your own domain — typically using Stripe Elements or Adyen components — you inherit the entire security and compliance surface. This approach is covered in detail in our Stripe Apple Pay documentation and our internal audits. While a custom checkout allows you to maintain a unified domain, it requires significant engineering effort to maintain PCI-DSS compliance and keep up with API updates.

For most merchants in the £1M-£15M GMV band, we typically recommend routing buyers to Shopify's native checkout. It eliminates the risk of payment API deprecations and ensures that accelerated wallets work with maximum reliability and zero custom wiring.

Your next engineering steps for checkout optimisation

Optimising your checkout experience requires a systematic approach to performance and reliability. Start by auditing your current checkout flow and measuring your mobile loading times. We typically target an Interaction to Next Paint (INP) under 200ms and a Largest Contentful Paint (LCP) under 2.5s on mid-tier Android devices over a 4G connection.

If you are building or maintaining a custom storefront, review your wallet implementation to ensure domain verification files are correctly served and that you are using the latest version of the Storefront API. For deep-dive architectural comparisons, read our headless commerce practical guide or evaluate gateway options with our Adyen vs Stripe UK Plus payment guide.

If you need assistance configuring secure payment handshakes, domain verification, or custom Shopify Functions for your checkout, contact our engineering team at No7 Software to schedule a technical audit. We typically deliver a complete implementation roadmap within 2-4 weeks, ensuring your store is fully optimised for mobile conversions.

Frequently Asked Questions

The questions buyers and engineers ask us most about this topic.

When does headless Apple Pay make sense vs native Shopify checkout?

Headless Apple Pay integrations are only worth the engineering effort if your brand requires a highly customised, single-page, in-app checkout on your own domain. For most merchants, routing the checkout flow to native Shopify checkout is the optimal choice. It reduces compliance overhead and eliminates the need for manual domain verification files, which typically cost £15,000 to £60,000 to build and maintain on custom architectures.

What is the biggest pitfall when setting up Google Pay on custom storefronts?

The biggest pitfall is loading the Google Pay JavaScript libraries eagerly on the homepage. Our engineers have measured that this adds up to 250ms of bundle parsing latency, severely degrading your mobile Interaction to Next Paint (INP). To prevent this, defer library loading until the buyer reaches the product detail page (PDP) or cart page, reducing INP by up to 35-55%.