Skip to main content
This reference documents all options available in the options property of <primer-checkout>.
Looking for how to use options? See the Options Guide for patterns and best practices.

Quick navigation


Core options

locale

Sets the UI language. Uses standard locale formats.
Supported locales include: en-US, en-GB, fr-FR, de-DE, es-ES, it-IT, nl-NL, pt-BR, ja-JP, and 40+ more.

merchantDomain

Domain for Apple Pay validation. Set this when checkout is hosted on a different domain than your registered Apple Pay domain.

enabledPaymentMethods

Filters which payment methods are displayed. Methods must also be configured in your Primer Dashboard.

disabledPayments

Disables all payment methods. Useful when you only want to show vaulted payment methods.

Redirect options

Configuration for redirect-based payment methods. Controls the return URL behavior for payment methods that require a redirect to an external page (e.g. PayPal, Klarna, and most APMs), and whether to force a full-page redirect instead of opening the flow in a popup where supported.

redirect.returnUrl

URL the payment method redirects back to after the customer completes (or cancels) the flow on the external page. If omitted, the SDK uses the current page URL.

redirect.forceRedirect

Whether to force a full-page redirect for payment methods that would otherwise open in a popup.

Card options

card.cardholderName

Configure the cardholder name field.
For runtime updates after initialization, use primer.setCardholderName().

Apple Pay options

For complete Apple Pay configuration including all button types, testing, and requirements, see the Apple Pay Options Reference.

applePay.buttonOptions

Button types: 'plain', 'buy', 'book', 'check-out', 'donate', 'order', 'pay', 'set-up', 'subscribe', and more Button styles: 'black', 'white', 'white-outline'. If not set, Apple Pay uses its default styling.

applePay.billingOptions

Values: 'postalAddress'

applePay.shippingOptions

Contact fields: 'postalAddress', 'name', 'phoneticName', 'phone', 'email'

Google Pay options

For complete Google Pay configuration including express checkout, shipping methods, and testing, see the Google Pay Options Reference.

googlePay.buttonType

Values: 'buy', 'checkout', 'pay', 'order', 'book', 'donate', 'subscribe', 'plain'

googlePay.buttonColor

Values: 'black', 'white', 'default'

googlePay.buttonSizeMode

Values: 'fill' (expands to container), 'static' (sized by label)

googlePay.buttonRadius

Corner radius in pixels.

googlePay.buttonLocale

ISO 639-1 locale code (e.g., 'en', 'de', 'fr').

googlePay.captureBillingAddress

googlePay.captureShippingAddress

googlePay.shippingAddressParameters

googlePay.requireShippingMethod

Enable shipping method selection in the Google Pay sheet. Requires captureShippingAddress or shippingAddressParameters.

googlePay.emailRequired

googlePay.existingPaymentMethodRequired

Only show button if user has a saved payment method (production only).

Klarna options

klarna.paymentFlow

Values: 'DEFAULT', 'PREFER_VAULT'
When using 'PREFER_VAULT', you must also provide klarna.recurringPaymentDescription.

klarna.recurringPaymentDescription

Required when offering recurring payments.

klarna.allowedPaymentCategories

Values: 'pay_now', 'pay_later', 'pay_over_time'

klarna.buttonOptions.text

Custom button text.
Klarna Options Reference

Klarna via Adyen options

adyenKlarna.buttonOptions.text

Custom text displayed next to the Klarna logo. Replaces the default “Pay with” text.
Klarna via Adyen Options Reference

PayPal options

PayPal has extensive configuration options documented separately. PayPal Options Reference

Vault options

vault.enabled

Enable payment method vaulting (saving for future use).

vault.headless

Hides default vault UI for custom implementations. Use with onVaultedMethodsUpdate, vault.createCvvInput(), and vault.startPayment().
Headless Vault Implementation Guide

vault.showEmptyState

Show a message when no saved payment methods exist.

Submit button options

submitButton.amountVisible

Show the order amount on the button (e.g., “Pay $12.34”).

submitButton.useBuiltInButton

Set to false to use your own submit button. Dispatch primer:card-submit event to trigger submission.
External Submit Button Recipe

Stripe options

stripe.publishableKey

Stripe publishable key for direct integration.

stripe.mandateData

Custom mandate text for direct debit payments.

Legacy options

sdkCore

SDK Core is the default payment engine. Set to false only if you need legacy behavior.
Only set sdkCore: false if you have a specific need for legacy behavior. SDK Core is the recommended engine for all new integrations.

TypeScript

Import types for autocomplete and type checking:

See also

Options guide

How to configure options

Events reference

Callbacks and events

Styling variables

CSS customization