Klarna Docs - Klarna Payments in native apps without SDK
Klarna Payments in native apps without SDK

This section content outline known issues when integrating Klarna Payments in the merchant iOS and Android Apps without Klarna SDK. Providing a troubleshooting guide and recommended actions and implementation patterns for your app developers to ensure that Klarna Payments flow works properly.

In case your mobile app is integrated with Klarna Payments and it is not using Klarna SDK, the payment flow could be interrupted getting the customer experience “stuck” on a page with the animated Klarna logo and not allowing to proceed with the payment.

In order to understand what might cause the issue described above please ask your engineering team to follow the steps below. It is important to have all of the recommendations below implemented to make sure that Klarna Payments flow is working correctly.

This step is recommended for best performance.

If your application has integration with "Sign In with Google" or any other social sign-in provider, we recommend using the same webview component for running the Klarna Payments flow. In detail it means:

It is best to allow ‘*.klarna.com’ domains to be loaded in your webview, but if you need to have a specific list, use the following:

  • js.klarna.com
  • pay.klarna.com
  • payments.klarna.com
  • login.klarna.com

If you are using the `react-native-webview` library, it is configured in the `originWhitelist` property and in the `onShouldStartLoadWithRequest` property.

It is crucial that your webview does not block any response codes, like 302 and 303 that are commonly used for browser redirections. Klarna Payments flow relies on this capability in order to run correctly.

If you are using the `react-native-webview` library, check that you allow both Klarna Domains and the redirect status codes in the `onShouldStartLoadWithRequest` handler and `onNavigationStateChange` handler.

Klarna Payments flow uses OAuth2 protocol to securely log the user in, so it is crucial that this flow is not blocked in your webview component. OAuth2 protocol is an industry standard for running user login flows, used by Google, Apple, Facebook and others.

If you are using the `react-native-webview` library, check that you allow both Klarna Domains and the redirect status codes in the `onShouldStartLoadWithRequest` handler and `onNavigationStateChange` handler.

Klarna Payments flow requires the capability to perform real time identification and verification (ID&V) for fraud prevention, underwriting, and KYC purposes, so it is crucial that your webview has the required configurations to support ID&V. 

If you are using the `react-native-webview` library, check that you configure the following 2 properties correctly as below:

  • allowsInlineMediaPlayback = true
  • mediaPlaybackRequiresUserAction = false

Overview & Concepts
The Mobile SDK offers a broad selection of integration options (and more are coming up!). If you’re familiar with Klarna’s products, you can head directly to each platform’s getting started guide. If not, we’ve got a few guides below to introduce you to all our options and how they work.