Skip to main content
PayPal Pay Later provides installment and deferred payment options for eligible buyers. This buy now, pay later (BNPL) solution allows customers to split purchases into interest-free payments or defer payment, subject to credit approval and eligibility criteria determined by PayPal.
Pay Later availability automatically depends on buyer eligibility, which is determined by PayPal based on factors like purchase amount, buyer history, and location.

Setup

Follow the PayPal setup instructions before configuring PayPal Pay Later. After setting up your PayPal account, Pay Later options are automatically presented to eligible buyers during checkout. No additional configuration is required beyond enabling the payment method in your Gr4vy connection.

Capabilities

Integration

For PayPal Pay Later, the default integration is through a redirect to PayPal’s hosted checkout page where eligible buyers are presented with Pay Later options. Start by creating a new transaction with the following required fields.
var transaction = await client.Transactions.CreateAsync(
  transactionCreate: new TransactionCreate()
  {
    Amount = 1299,
    Currency = "USD",
    Country = "US",
    PaymentMethod =
      TransactionCreatePaymentMethod.CreateRedirectPaymentMethodCreate(
        new RedirectPaymentMethodCreate()
        {
          Method = "paypalpaylater",
          Country = "US",
          Currency = "USD",
          RedirectUrl = "https://example.com/callback",
        }
      ),
  }
);
After the transaction is created, the API response includes payment_method.approval_url and the buyer_approval_pending status.
{
  "type": "transaction",
  "id": "ea1efdd0-20f9-44d9-9b0b-0a3d71e9b625",
  "payment_method": {
    "type": "payment-method",
    "approval_url": "https://www.paypal.com/checkoutnow?token=..."
  },
  "method": "paypalpaylater"
}
Redirect the buyer to the approval_url where PayPal determines eligibility and presents available Pay Later options. After the buyer reviews terms and approves the payment, they are redirected to the redirect_url you provided when creating the transaction. Do not rely solely on the redirect - either poll the transaction or (recommended) rely on webhooks to detect the final status (for example capture_succeeded or failure states).

Supported countries

Testing

PayPal provides a sandbox environment for testing Pay Later transactions. After setting up your sandbox PayPal developer account, you can create test buyer accounts in the PayPal Developer Dashboard. Pay Later options in the sandbox simulate the eligibility and approval flow. Note that specific Pay Later products (like Pay in 4 or Pay in 30 days) may vary by test account configuration. For detailed testing instructions and Pay Later-specific sandbox guidelines, see the PayPal Pay Later documentation.

Additional configuration

Ingest billing and shipping details

By default, billing, and shipping details received from PayPal are not imported. To enable this feature, head over to ConnectionsConfigured and select your PayPal connector. Next, go to Credentials and toggle Import billing details and/or Import shipping details. When Import billing details is enabled, any of the user’s name, email address, and billing address are automatically imported into your transaction, merging it with any data already present on the transaction. Linked buyers are not updated, but only the snapshot of the buyer on the transaction. When Import shipping details is enabled, the user’s shipping address is automatically requested and imported into your transaction, merging it with any data already present on the transaction. Linked buyers are not updated, but only the snapshot of the buyer on the transaction.
The ingestion of billing and shipping details is not available for tokenized payments.

Server-side shipping callbacks

When Import shipping details is enabled, you can configure PayPal to call your server whenever the buyer changes their shipping address or selects a different shipping option during checkout. This lets you return updated shipping costs and available options in real time. To enable this, pass order_update_callback_config in connection_options["paypal-paypalpaylater"] when creating a transaction:
FieldDescription
callback_urlThe URL PayPal calls when the buyer updates their shipping details.
callback_eventsArray of events to subscribe to. "SHIPPING_ADDRESS" fires when the buyer changes their shipping address; "SHIPPING_OPTIONS" fires when they change their selected shipping option.
var transaction = await client.Transactions.CreateAsync(
  transactionCreate: new TransactionCreate()
  {
    Amount = 1299,
    Currency = "USD",
    Country = "US",
    PaymentMethod =
      TransactionCreatePaymentMethod.CreateRedirectPaymentMethodCreate(
        new RedirectPaymentMethodCreate()
        {
          Method = "paypalpaylater",
          Country = "US",
          Currency = "USD",
          RedirectUrl = "https://example.com/callback",
        }
      ),
    ConnectionOptions = new Dictionary<string, object>()
    {
      ["paypal-paypalpaylater"] = new Dictionary<string, object>()
      {
        ["order_update_callback_config"] = new Dictionary<string, object>()
        {
          ["callback_url"] = "https://example.com/shipping-callback",
          ["callback_events"] = new List<string> { "SHIPPING_ADDRESS", "SHIPPING_OPTIONS" },
        }
      }
    }
  }
);

Checkout experience

You can customize the PayPal Checkout page by passing any of the following fields in connection_options["paypal-paypalpaylater"] when creating a transaction.
FieldDescription
user_actionControls the label on the PayPal Checkout button. "PAY_NOW" (default) shows an immediate pay button; "CONTINUE" shows a continue button for deferred-payment flows.
shipping_preferenceControls how the shipping address is sourced during checkout. "NO_SHIPPING" hides the shipping address fields; "GET_FROM_FILE" lets the buyer provide or change their address during checkout; "SET_PROVIDED_ADDRESS" pre-fills the address you supplied and prevents the buyer from changing it. When omitted, Gr4vy determines this value automatically (see the note below).
brand_nameThe merchant brand name displayed on the PayPal Checkout page. Maximum 127 characters.
landing_pageThe page shown to the buyer when they arrive at PayPal. "LOGIN" opens the PayPal login page; "GUEST_CHECKOUT" opens the guest checkout page; "NO_PREFERENCE" lets PayPal decide.
localeA BCP 47 locale tag used to localize the PayPal Checkout page, for example "en-US" or "fr-FR".
"GUEST_CHECKOUT" for landing_page only takes effect if PayPal account optional is enabled in your PayPal merchant account settings. If the setting is not enabled, PayPal falls back to showing the login page regardless.
locale is a hint to PayPal and may not always be honored. PayPal also determines locale from the buyer’s browser cookies and the configuration of its own SDK, so the effective locale can differ from the value you provide.
ConnectionOptions = new Dictionary<string, object>()
{
  ["paypal-paypalpaylater"] = new Dictionary<string, object>()
  {
    ["user_action"] = "PAY_NOW",
    ["shipping_preference"] = "GET_FROM_FILE",
    ["brand_name"] = "Acme Store",
    ["landing_page"] = "LOGIN",
    ["locale"] = "en-US",
  }
}
shipping_preference is automatically determined by Gr4vy when not set. It is set to GET_FROM_FILE when order_update_callback_config is set and shipping ingestion is enabled, SET_PROVIDED_ADDRESS when a shipping address is supplied on the transaction, and NO_SHIPPING otherwise. Setting shipping_preference explicitly overrides this automatic behavior.

Payment receiving preferences

By default, PayPal only settles payments automatically if the payment is in the primary currency of the PayPal merchant account. If you need to accept payments in additional currencies, you need to open a PayPal account balance in each of the currencies you intend to accept. Alternatively, you can configure your PayPal merchant account to automatically convert payments into the primary currency. If you receive a payment in a currency that your PayPal merchant account is not configured to accept, the payment enters a pending state and you need to log in to the PayPal merchant dashboard to trigger settlement, either by opening the required currency balance, or converting the payment into the primary currency of your PayPal account.
Payments left in a pending state are eventually reversed by PayPal.

FraudNet

FraudNet is a PayPal-developed JavaScript library that collects browser-based data to help reduce fraud. Upon checkout, the FraudNet library sends data elements to PayPal Risk Services for fraud and risk assessment. When creating transactions, the PayPal FraudNet library must be included on the checkout page for all transactions. When using Embed, the PayPal FraudNet library is included automatically. If you are using the API directly, you need to use the device fingerprinting library which includes the PayPal FraudNet library.

Supported currencies