Quick reference
Payment flow
Control the payment flow for Klarna.Payment flow values
When using
'PREFER_VAULT', you must also provide recurringPaymentDescription.Payment categories
Restrict which Klarna payment categories are available to customers.Available categories
By default, all categories supported by the merchant’s Klarna configuration are shown. Set
allowedPaymentCategories to limit the options.
Examples
Available categories also depend on the customer’s country, the order amount, and the merchant’s Klarna configuration. If a specified category is not available for the given context, it will not be displayed.
Button customization
Customize the text displayed on the Klarna payment button.Vaulting
Enable vaulting to save Klarna accounts for recurring payments.Requirements checklist
SDK configuration
How it works
- Customer authenticates with Klarna
- Klarna authorizes a recurring payment token
- Primer stores the vaulted payment method
- Future payments use the saved method without re-authentication
Client session requirements
Klarna requires specific data in the client session to process payments. Pass these when creating the client session on your server.Testing
Sandbox testing
Use Primer’s TEST environment to test Klarna payments without processing real transactions. Visit the Klarna Sample Data Page for test credentials and sample customer data.Production
No special configuration is required to go live — use your production credentials.Troubleshooting
Payment categories not displaying
Payment categories not displaying
Possible causes:
allowedPaymentCategoriesfilters out all available categories- Klarna does not offer the specified categories for the customer’s country or order amount
- Remove
allowedPaymentCategoriesto see all available categories - Check Klarna’s supported countries and currencies
- Verify order amount meets Klarna’s minimum requirements
Vaulting not working
Vaulting not working
Checklist:
paymentFlow: 'PREFER_VAULT'in SDK optionsrecurringPaymentDescriptionprovided in SDK optionsvaultOnSuccess: truein client sessioncustomerIdprovided in client session
Complete example
See also
SDK options reference
All configuration options
Klarna integration guide
Setup and integration guide
Klarna documentation
Official Klarna documentation