Integrate PayPal buttons and Hosted Fields

SDKLegacyAdvancedLast updated: September 6th 2023, @ 12:43:42 pm


This version of the JavaScript SDK integration guide for direct merchants is a legacy integration. Use version 2 for new integrations.

Note: Discover Checkout's advanced features and unlock greater control over your checkout process by directly integrating with PayPal REST APIs. See Get started with PayPal REST API for more information about setting up your own custom integration.

Which integration to use

There are 2 versions of card payment integrations for direct merchants using the JavaScript SDK:

  • Recommended: Version 2 uses the PayPal-hosted CardFields component to accept and save cards without handling card information. PayPal handles all security and compliance issues associated with processing cards. The CardFields component is the recommended integration method and receives ongoing enhancements and improvements.
  • Version 1 is a legacy integration that uses the HostedFields component. This integration is no longer under active development and won’t receive further updates.

Other elements of the JavaScript SDK integration for direct merchants remain the same.

Next steps & customizations

Add security to your checkout integration, or create customizations for your audience.

Add more payment methods

Optional
Pay Later

Payers buy now and pay in installments.

Optional
Pay with Venmo

Add the Venmo button to your checkout integration.

Optional
Alternative payment methods

Accept local payment methods across the globe.

Optional
Apple Pay

Add Apple Pay as a payment button.


Security and customizations

Required
Implement 3D Secure

Authenticate card holders through card issuers.

Optional
Capture payment

Captures payment for an order.

Optional
Refund a captured payment

Refund all or part of a captured payment.

Optional
Real-time account updater

Reduce declines by getting card updates from the issuer.