> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dodopayments.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Testing Process

> Test your integration with test cards, UPI IDs, BNPL data, and digital wallets. Simulate payments, refunds, and failures without real charges.

Use the test credentials on this page to simulate successful, declined, and failed payments in test mode. No money moves, and no real account is charged. To see a complete test payment, watch this video.

<Frame>
  <iframe className="w-full aspect-video rounded-md" src="https://www.youtube.com/embed/5CcUSE4L_cg" title="Test Transaction | Dodo Payments" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowFullScreen />
</Frame>

<CardGroup cols={2}>
  <Card title="Full API Access" icon="code">
    Every API endpoint is available in test mode.
  </Card>

  <Card title="Webhook Testing" icon="webhook">
    Webhooks fire for test transactions the same way as in production.
  </Card>
</CardGroup>

<Warning>
  Test credentials work only in test mode. In live mode, a payment made with a test credential fails.
</Warning>

## Test Cards

Use these card numbers to simulate successful and declined payments across different regions.

<Tabs>
  <Tab title="Successful Payments">
    | Region | Brand | Card Number | Expiry | CVV |
    | :- | :- | :- | :- | :- |
    | US | Visa | `4242424242424242` | 06/32 | 123 |
    | US | Mastercard | `5555555555554444` | 06/32 | 123 |
    | India | Visa | `4576238912771450` | 06/32 | 123 |
    | India | Mastercard | `5409162669381034` | 06/32 | 123 |
  </Tab>

  <Tab title="Declined Payments">
    | Region | Brand | Card Number | Scenario | Error Code |
    | :- | :- | :- | :- | :- |
    | US | Visa | `4000000000000002` | Generic decline | `GENERIC_DECLINE` |
    | US | Visa | `4000000000009995` | Insufficient funds | `INSUFFICIENT_FUNDS` |
    | India | Visa | `4706131211212123` | Generic decline | `GENERIC_DECLINE` |
    | India | Mastercard | `5105105105105100` | Generic decline | `GENERIC_DECLINE` |

    When a test card declines, the payment's `error_code` and `error_message` reflect the scenario above. Look up any code in the [Transaction Failures](/api-reference/transaction-failures) reference for its meaning and recommended action. See [Handle Payment Failures](/developer-resources/handle-payment-failures) for handling declines in your integration.
  </Tab>

  <Tab title="Subscription Renewal Failures">
    | Card Number | Expiry | CVV |
    | :- | :- | :- |
    | `4000000000000341` | 12/34 | 123 |

    Use this card to test subscription renewal, upgrade, and downgrade failures. A subscription that uses this card is declined at its next charge, so you can test retries, customer notifications, and your failure handling.
  </Tab>
</Tabs>

For all test cards, use expiry date **06/32** (or **12/34**) and CVV **123**.

### Testing Renewal Failures

<Steps>
  <Step title="Create a test subscription">
    Create a subscription with your test API keys using a success test card (for example, `4242424242424242`). The initial charge should succeed and the subscription should become active.
  </Step>

  <Step title="Update the payment method">
    Open the [Customer Portal](/features/customer-portal), find the subscription, and click **Update Payment Method**. Enter the failure test card `4000000000000341` (Expiry: `12/34`, CVV: `123`) and save it.
  </Step>

  <Step title="Advance the next billing date (optional)">
    To trigger renewal without waiting for the natural billing cycle, use the Update Subscription API to set `next_billing_date` to a time slightly in the future, such as one minute from now. Replace the example value below. The API rejects a `next_billing_date` that is not in the future, including the current time. The value must be an ISO 8601 / RFC 3339 UTC timestamp (the `Z` suffix is required).

    ```http theme={null}
    PATCH /subscriptions/{subscription_id}
    {
      "next_billing_date": "2026-05-03T00:00:00Z"
    }
    ```

    See the [Update Subscription API reference](/api-reference/subscriptions/patch-subscriptions) for details.
  </Step>

  <Step title="Verify the failure">
    On the next billing attempt:

    * The renewal charge declines on the failure card
    * The subscription moves to **Past Due** first (the grace period; the `subscription.past_due` webhook carries `past_due_ends_at`), then to **On-Hold** when the grace period ends
    * A `payment.failed` webhook event is delivered
    * The customer can return to the Customer Portal to update the payment method and retry
  </Step>
</Steps>

## Test UPI

UPI testing uses special VPA (Virtual Payment Address) identifiers that simulate different payment outcomes.

| Status | UPI ID |
| :- | :- |
| Success | `success@upi` |
| Failure | `failure@upi` |

### Requirements for UPI Testing

* Billing country must be set to `IN`
* Currency must be `INR`
* For non-Indian merchants: Adaptive Currency must be enabled

For complete UPI documentation including RBI mandate testing for subscriptions, see the [India Payment Methods](/features/payment-methods/india) page.

## Test Pix

Pix testing uses a test CPF (Brazilian tax ID) to simulate the QR code flow.

| Field | Test Value |
| :- | :- |
| CPF | `00000000000` (11 zeros) |

### Requirements for Pix Testing

* Billing country must be set to `BR`
* Currency must be `BRL`

Enter the test CPF when prompted at checkout. A test QR code is generated — scan it with your phone's normal camera (no Pix app needed) and you'll be redirected to a test page where you can simulate the transaction as a success or failure.

For complete Pix documentation, see the [Pix](/features/payment-methods/pix) page.

## Test BNPL

Buy Now Pay Later providers have specific test data requirements.

### Klarna Test Data

Use these details to simulate Klarna payments in test mode:

| Field | Approved | Denied |
| :- | :- | :- |
| Date of Birth | 07-10-1970 | 07-10-1970 |
| First Name | Test | Test |
| Last Name | Person-us | Person-us |
| Email | [customer@email.us](mailto:customer@email.us) | [customer+denied@email.us](mailto:customer+denied@email.us) |
| Street | Amsterdam Ave | Amsterdam Ave |
| House Number | 509 | 509 |
| City | New York | New York |
| State | New York | New York |
| Postal Code | 10024-3941 | 10024-3941 |
| Phone | +13106683312 | +13106354386 |

<Note>
  On USD checkouts, Klarna requires a minimum transaction amount of \$50.01 to appear as a payment option.
</Note>

### Afterpay Testing

<Steps>
  <Step title="Select Afterpay">
    Choose Afterpay as the payment method in checkout and click Pay.
  </Step>

  <Step title="Test successful payment">
    Use any valid email address and shipping address for successful payments.
  </Step>

  <Step title="Test failed authentication">
    To simulate failure, close the Afterpay modal window on the redirect page. The payment transitions from `requires_customer_action` to `requires_payment_method`.
  </Step>
</Steps>

<Note>
  On USD checkouts, Afterpay requires a minimum transaction amount of \$50.01 to appear as a payment option.
</Note>

For complete BNPL documentation including Billie B2B testing, see the [Buy Now Pay Later](/features/payment-methods/bnpl) page.

## Test Digital Wallets

### Apple Pay

<Steps>
  <Step title="Enable test mode">
    Turn off the **Live Mode** switch in the dashboard sidebar, and use API keys created in test mode. See [Test Mode vs Live Mode](/miscellaneous/test-mode-vs-live-mode).
  </Step>

  <Step title="Add a card to Apple Wallet">
    Add a real card to your Apple Wallet. In test mode, the card won't be charged.
  </Step>

  <Step title="Complete test purchase">
    Open checkout on an Apple device and complete the Apple Pay flow.
  </Step>
</Steps>

<Warning>
  Apple Pay requires HTTPS. It won't appear on `localhost` without proper SSL setup. Domain verification must also be complete.
</Warning>

### Google Pay

<Steps>
  <Step title="Join the test card group">
    [Join the Google Pay test card group](https://groups.google.com/g/googlepay-test-mode-stub-data) to get test cards automatically added to your wallet.
  </Step>

  <Step title="Enable test mode">
    Turn off the **Live Mode** switch in the dashboard sidebar, and use API keys created in test mode. See [Test Mode vs Live Mode](/miscellaneous/test-mode-vs-live-mode).
  </Step>

  <Step title="Complete test purchase">
    Select one of the test cards in Google Pay to complete the transaction.
  </Step>
</Steps>

### Amazon Pay, Cash App Pay, and RevolutPay

Use your test API keys and follow the standard checkout flow. Test transactions are simulated without actual charges.

For complete digital wallet documentation including domain verification for Apple Pay, see the [Digital Wallets](/features/payment-methods/digital-wallets) page.

## Test ACH Direct Debit

ACH Direct Debit can be tested in test mode by entering test bank details at checkout.

<Steps>
  <Step title="Enable test mode">
    Turn off the **Live Mode** switch in the dashboard sidebar, and use API keys created in test mode. See [Test Mode vs Live Mode](/miscellaneous/test-mode-vs-live-mode).
  </Step>

  <Step title="Set currency and billing address">
    Set the billing currency to `USD` and the billing address country to `US`. ACH is not offered outside this combination.
  </Step>

  <Step title="Use a one-time payment">
    ACH is not available on subscription checkouts, so test it against a one-time payment.
  </Step>

  <Step title="Enter the test bank details">
    Enter one of the test routing and account number pairs below, then confirm your webhook handler receives the final payment status — ACH payments confirm asynchronously rather than at checkout.
  </Step>
</Steps>

### Test Bank Accounts

Use the routing number `110000000` with any of these account numbers:

| Account Number | Behavior |
| :- | :- |
| `000123456789` | The payment succeeds. |
| `000222222227` | The payment fails due to insufficient funds. |
| `000111111113` | The payment fails because the account is closed. |
| `000555555559` | The payment succeeds, then triggers a dispute. |
| `000000000009` | The payment stays in processing indefinitely. |

For the full list of test accounts, see the [ACH Direct Debit](/features/payment-methods/ach#testing) page.

## Test European Methods

European payment methods (iDEAL, Bancontact, EPS, Multibanco) can be tested in test mode.

<Note>
  Multibanco shows a voucher instead of a bank flow. See [Test Multibanco](#test-multibanco).
</Note>

<Steps>
  <Step title="Enable test mode">
    Turn off the **Live Mode** switch in the dashboard sidebar, and use API keys created in test mode. See [Test Mode vs Live Mode](/miscellaneous/test-mode-vs-live-mode).
  </Step>

  <Step title="Set billing address">
    Set the billing address country to match the payment method:

    * `NL` for iDEAL
    * `BE` for Bancontact
    * `AT` for EPS
    * `PT` for Multibanco
  </Step>

  <Step title="Set currency">
    European methods require EUR currency.
  </Step>

  <Step title="Complete test flow">
    Follow the simulated bank authentication flow in the test environment.
  </Step>
</Steps>

### Test Multibanco

Use EUR and a `PT` billing address. After you click **Pay**, checkout shows a Multibanco voucher. In test mode, the email you enter decides the result:

| Email | Result |
| :- | :- |
| `succeed_immediately@example.com` | Payment succeeds within a few seconds. |
| `expire_immediately@example.com` | Payment fails within a few seconds. |

To see the success page, use `succeed_immediately@example.com`, wait a few seconds, and tap **Done**.

For the full list of test emails, see the [Europe](/features/payment-methods/europe#multibanco-test-emails) page.

### Test SEPA Direct Debit IBANs

SEPA Direct Debit requires EUR and a Eurozone billing address. Use these test IBANs to force a specific outcome:

| Test IBAN | Behavior |
| :- | :- |
| `DE89370400440532013000` | The payment succeeds. |
| `DE62370400440532013001` | The payment fails. |
| `DE35370400440532013002` | The payment succeeds, then is immediately disputed. |
| `DE65370400440002222227` | The payment fails due to insufficient funds. |

For the full list of test IBANs, including per-country values, see the [Europe](/features/payment-methods/europe#sepa-test-ibans) page.

For complete European payment methods documentation, see the [Europe](/features/payment-methods/europe) page.

## Test Asia-Pacific Wallets

GCash, Alipay HK, FPS, and Touch 'n Go are QR code payments that only appear when the billing country and currency match.

<Steps>
  <Step title="Enable test mode">
    Turn off the **Live Mode** switch in the dashboard sidebar, and use API keys created in test mode. See [Test Mode vs Live Mode](/miscellaneous/test-mode-vs-live-mode).
  </Step>

  <Step title="Set billing country and currency">
    Create a one-time checkout with the matching pair:

    | Method | Billing Country | Billing Currency | Method Type |
    | :- | :- | :- | :- |
    | GCash | `PH` | `PHP` | `gcash` |
    | Alipay HK | `HK` | `HKD` | `ali_pay_hk` |
    | FPS | `HK` | `HKD` or `CNY` | `fps` |
    | Touch 'n Go | `MY` | `MYR` | `touch_n_go` |
  </Step>

  <Step title="Select the method and confirm">
    Select the method and click **Pay**. A QR code opens in a full-screen overlay and the checkout waits for the payment.
  </Step>

  <Step title="Verify the checkout behavior">
    Confirm the method appears only for the matching country and currency and the QR code renders.
  </Step>
</Steps>

<Note>
  Test-mode QR codes are issued by the wallet provider's test environment and may behave differently from a live payment.
</Note>

For complete documentation, see the [Asia-Pacific](/features/payment-methods/asia-pacific) page.

## Testing Best Practices

<AccordionGroup>
  <Accordion title="Test all payment scenarios">
    Don't test only successful payments. Test declines, cancellations, and edge cases like insufficient funds.
  </Accordion>

  <Accordion title="Verify webhook handling">
    Ensure your webhook endpoints correctly process all event types, especially `payment.succeeded`, `payment.failed`, and subscription events.

    Use the [Dodo Payments CLI](/developer-resources/sdks/cli#webhooks) to test webhooks locally:

    * `dodo wh listen` forwards live test webhooks to your local server
    * `dodo wh trigger` sends mock payloads for all supported webhook event types
  </Accordion>

  <Accordion title="Test on real devices">
    For Apple Pay and Google Pay, test on actual iOS and Android devices. Simulators don't fully replicate wallet behavior.
  </Accordion>

  <Accordion title="Test regional methods with correct addresses">
    Regional payment methods (UPI, iDEAL, etc.) require matching billing addresses. A US billing address won't show iDEAL.
  </Accordion>

  <Accordion title="Verify minimum amounts">
    Klarna and Afterpay require a \$50.01 minimum on USD checkouts. Test that they correctly appear or hide based on cart total.
  </Accordion>
</AccordionGroup>

## Related Pages

<CardGroup cols={2}>
  <Card title="Cards" icon="credit-card" href="/features/payment-methods/cards">
    Card testing, 3D Secure, and saved payment methods.
  </Card>

  <Card title="Digital Wallets" icon="wallet" href="/features/payment-methods/digital-wallets">
    Apple Pay, Google Pay, Amazon Pay testing.
  </Card>

  <Card title="BNPL" icon="calendar-days" href="/features/payment-methods/bnpl">
    Klarna, Afterpay, and Billie testing.
  </Card>

  <Card title="India" icon="indian-rupee-sign" href="/features/payment-methods/india">
    UPI and RBI mandate testing.
  </Card>

  <Card title="Pix" icon="brazilian-real-sign" href="/features/payment-methods/pix">
    Pix testing with test CPF.
  </Card>

  <Card title="Europe" icon="euro-sign" href="/features/payment-methods/europe">
    iDEAL, Bancontact, EPS, Multibanco testing.
  </Card>

  <Card title="Asia-Pacific" icon="earth-asia" href="/features/payment-methods/asia-pacific">
    GCash, Alipay HK, FPS, and Touch 'n Go testing.
  </Card>

  <Card title="Webhooks" icon="webhook" href="/developer-resources/webhooks">
    Set up webhooks for test events.
  </Card>

  <Card title="CLI Webhook Testing" icon="terminal" href="/developer-resources/sdks/cli#webhooks">
    Test webhooks locally with the Dodo Payments CLI.
  </Card>
</CardGroup>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.