Integrate Apple Pay with JS SDK for direct merchants

DocsCurrentLast updated: March 15th 2023, @ 4:50:11 pm


We've made changes to this page and its layout to improve the developer experience.

Let us know what you think of the updated documentation by selecting the feedback tab below.

Supported countries and currencies

Apple Pay supports payments in 34 countries and 22 currencies:

  • Countries: Australia, Austria, Belgium, Bulgaria, Canada, China, Cyprus, Czech Republic, Denmark, Estonia, Finland, France, Germany, Greece, Hong Kong, Hungary, Ireland, Italy, Japan, Latvia, Liechtenstein, Lithuania, Luxembourg, Malta, Netherlands, Norway, Poland, Portugal, Romania, Singapore, Slovakia, Slovenia, Spain, Sweden, United States, United Kingdom
  • Currencies: AUD, BRL, CAD, CHF, CZK, DKK, EUR, GBP, HKD, HUF, ILS, JPY, MXN, NOK, NZD, PHP, PLN, SEK, SGD, THB, TWD, USD

Tip: If you want to integrate additional methods of accepting payment beyond Apple Pay, visit our Advanced Checkout guide for additional integration choices.

Tip: Apple Pay Recurring for Japan is not supported.

Get up and running in GitHub Codespaces

GitHub Codespaces are cloud-based development environments where you can code and test your PayPal integrations. Learn more

Note: Remove the file extension from the domain association file when you host it on your server.

Register your live domain on PayPal

Add all high-level domains that show the Apple Pay button.

  1. Log into the PayPal Developer Dashboard with your live PayPal account.
  2. Select the Sandbox/Live toggle so it shows Live.
  3. Go to Apps & Credentials.
  4. Select your app.
  5. Scroll down to Features > Accept payments > Advanced Credit and Debit Card Payments.
  6. Check if Apple Pay is enabled. If Apple Pay isn't enabled, select the Apple Pay checkbox and select the Save link to enable Apple Pay.
  7. Select the Manage link in the Apple Pay section.
  8. Select Add Domain and enter your domain name.
  9. Select Register Domain. If registration fails, check that the domain association file is live and saved to the right place on your live site.

After your domain is registered:

  • The domain appears under Domains registered with Apple Pay.
  • Buyers can make payments using the Apple Pay button on the registered website.

Testing in your live environment

When testing a purchase in production, consider:

  • The business account receiving money can't also make the purchase.
  • If you create a personal account with the same information as the business account, those accounts might experience restrictions.

How to test Apple Pay payments in a live environment:

  1. Open your test page with Safari on iOS or desktop.
  2. Select the Apple Pay button to open a pop-up with the Apple Pay payment sheet.
  3. Proceed with the Apple Pay checkout transaction.
  4. If you have an additional confirmation page on your merchant website, confirm the payment.
  5. Log in to your merchant account and confirm that the money has moved into that account.

Troubleshoot your integration

Make sure that there are no browser console warnings or errors. The JavaScript SDK configuration attributes have distinct validation checks for input formatting and values.

If the validation fails, the web browser's developer console shows warning messages that say which property is incorrect and what you need to do to address the issue. The library generally attempts to revert to the safe default values if missing or incorrect inputs exist.