This document provides instructions for testing payments, refunds, disputes, and the other functions of WooPayments. To learn more about WooPayments, including how to set it up on your store, see our main documentation page.
WARNING: If you’re “testing” WooPayments by placing real orders while in live mode and then refunding yourself, the transaction fees associated with those orders will not be refunded. Please use test mode for all test orders!
Enabling test mode
↑ Back to topBy default, WooPayments will accept real payment methods, such as cards, and actually charge your customers. To test payments, refunds, disputes, and other such processes without accepting real funds, you will need to enable test mode.
NOTE: Test mode does not charge any fees. Even if you still see the fees for an order listed in various places, this is only to show what you would have been charged had the order been placed in live mode.
To enable test mode:
- Go to Payments > Settings in your site’s dashboard.
- Check the Enable test mode box.
- Select the Enable button in the confirmation dialogue box.
- Click Save changes at the bottom of the page.
Test orders
↑ Back to topWhen test mode is enabled, any test payments processed via WooPayments will also create orders in WooCommerce. You can read our managing orders documentation to learn more about how to handle test orders.
Test mode data
↑ Back to topWhile test mode is enabled, the pages under the Payments menu item will only show test mode data. This includes data shown under Payouts, Transactions, and Disputes.
To remind store owners that test mode is currently enabled, a notice is also displayed at the top of any page under the Payments menu item.
Additionally, any orders placed while test mode is enabled will feature a notice on the edit order page at WooCommerce > Orders. This notice will be visible while test mode is enabled or disabled.
Testing card payments
↑ Back to topTo place a test order in test mode:
- Enable test mode as shown above.
- Go to your site’s shop and add a product to your cart.
- Proceed to the checkout page and fill out the form.
- Enter a test card number, expiry date, and CVC code.
- Place your order.
The order will be processed just as if you had used a real card.
After you’re taken to the Order received page, you can go back into your site’s dashboard and find the test transaction under WooCommerce > Orders and the Payments > Transactions page.
Test cards
↑ Back to topWhen WooPayments is in test mode, the card payment form will show a basic test card number. Click the number to copy it, then paste it into the payment form.
You can also use any of the following test card numbers:
Number | Brand | Exp. Date | CVC Code |
---|---|---|---|
4242 4242 4242 4242 | Visa | Any future date | Any three digits |
4000 0566 5566 5556 | Visa (debit) | Any future date | Any three digits |
5555 5555 5555 4444 | Mastercard | Any future date | Any three digits |
5105 1051 0510 5100 | Mastercard (prepaid) | Any future date | Any three digits |
3782 8224 6310 005 | American Express | Any future date | Any three digits |
6011 1111 1111 1117 | Discover | Any future date | Any three digits |
NOTE: The generic test cards shown above are U.S. cards. If your account country is not the U.S., and you use one of those cards for testing, you may see additional (test) fees on those transactions. Please see the section below for country-specific test cards you can use to avoid this.
Country-specific test cards
↑ Back to topCards issued outside the country or region of your WooPayments account can incur additional fees in live mode. To test an international payment, use the following info.
Number | Country | Exp. Date | CVC Code |
---|---|---|---|
4000 0003 2000 0021 | Argentina | Any future date | Any three digits |
4000 0003 6000 0006 | Australia | Any future date | Any three digits |
4000 0004 0000 0008 | Austria | Any future date | Any three digits |
4000 0011 2000 0005 | Belarus | Any future date | Any three digits |
4000 0005 6000 0004 | Belgium | Any future date | Any three digits |
4000 0007 6000 0002 | Brazil | Any future date | Any three digits |
4000 0010 0000 0000 | Bulgaria | Any future date | Any three digits |
4000 0012 4000 0000 | Canada | Any future date | Any three digits |
4000 0015 2000 0001 | Chile | Any future date | Any three digits |
4000 0015 6000 0002 | China | Any future date | Any three digits |
4000 0017 0000 0003 | Colombia | Any future date | Any three digits |
4000 0018 8000 0005 | Costa Rica | Any future date | Any three digits |
4000 0019 1000 0009 | Croatia | Any future date | Any three digits |
4000 0019 6000 0008 | Cyprus | Any future date | Any three digits |
4000 0020 3000 0002 | Czech Republic | Any future date | Any three digits |
4000 0020 8000 0001 | Denmark | Any future date | Any three digits |
4000 0021 8000 0000 | Ecuador | Any future date | Any three digits |
4000 0023 3000 0009 | Estonia | Any future date | Any three digits |
4000 0024 6000 0001 | Finland | Any future date | Any three digits |
4000 0025 0000 0003 | France | Any future date | Any three digits |
4000 0027 6000 0016 | Germany | Any future date | Any three digits |
4000 0029 2000 0005 | Gibraltar | Any future date | Any three digits |
4000 0030 0000 0030 | Greece | Any future date | Any three digits |
4000 0034 4000 0004 | Hong Kong | Any future date | Any three digits |
4000 0034 8000 0005 | Hungary | Any future date | Any three digits |
4000 0035 6000 0008 | India | Any future date | Any three digits |
4000 0037 2000 0005 | Ireland | Any future date | Any three digits |
4000 0038 0000 0008 | Italy | Any future date | Any three digits |
4000 0039 2000 0003 | Japan | Any future date | Any three digits |
3530 1113 3330 0000 | Japan (JCB) | Any future date | Any three digits |
4000 0042 8000 0005 | Latvia | Any future date | Any three digits |
4000 0043 8000 0004 | Liechtenstein | Any future date | Any three digits |
4000 0044 0000 0000 | Lithuania | Any future date | Any three digits |
4000 0044 2000 0006 | Luxembourg | Any future date | Any three digits |
4000 0045 8000 0002 | Malaysia | Any future date | Any three digits |
4000 0047 0000 0007 | Malta | Any future date | Any three digits |
4000 0048 4000 8001 | Mexico | Any future date | Any three digits |
5062 2100 0000 0009 | Mexico | Any future date | Any three digits |
4000 0052 8000 0002 | Netherlands | Any future date | Any three digits |
4000 0055 4000 0008 | New Zealand | Any future date | Any three digits |
4000 0057 8000 0007 | Norway | Any future date | Any three digits |
4000 0059 1000 0000 | Panama | Any future date | Any three digits |
4000 0060 0000 0066 | Paraguay | Any future date | Any three digits |
4000 0060 4000 0068 | Peru | Any future date | Any three digits |
4000 0061 6000 0005 | Poland | Any future date | Any three digits |
4000 0062 0000 0007 | Portugal | Any future date | Any three digits |
4000 0064 2000 0001 | Romania | Any future date | Any three digits |
4000 0068 2000 0007 | Saudi Arabia | Any future date | Any three digits |
4000 0070 2000 0003 | Singapore | Any future date | Any three digits |
4000 0070 3000 0001 | Slovakia | Any future date | Any three digits |
4000 0070 5000 0006 | Slovenia | Any future date | Any three digits |
4000 0072 4000 0007 | Spain | Any future date | Any three digits |
4000 0075 2000 0008 | Sweden | Any future date | Any three digits |
4000 0075 6000 0009 | Switzerland | Any future date | Any three digits |
4000 0015 8000 0008 | Taiwan | Any future date | Any three digits |
4000 0076 4000 0003 | Thailand | Any future date | Any three digits |
4000 0078 4000 0001 | United Arab Emirates | Any future date | Any three digits |
4000 0082 6000 0000 | United Kingdom | Any future date | Any three digits |
4242 4242 4242 4242 | United States | Any future date | Any three digits |
4000 0085 8000 0003 | Uruguay | Any future date | Any three digits |
3D Secure test cards
↑ Back to topThe following card numbers can be used to test payments requiring 3D Secure Authentication.
Description | Number | Details |
---|---|---|
Authenticate unless set up | 4000 0025 0000 3155 | This card requires authentication for off-session payments unless you set it up for future payments. After you set it up, off-session payments no longer require authentication. |
Always authenticate | 4000 0027 6000 3184 | This card requires authentication on all transactions, regardless of how the card is set up. |
Already set up | 4000 0038 0000 0446 | This card is already set up for off-session use. It requires authentication for one-time and other on-session payments. However, all off-session payments succeed as if the card has been previously set up. |
Insufficient funds | 4000 0082 6000 3178 | This card requires authentication for one-time payments. All payments are declined for insufficient funds even after being successfully authenticated or previously set up. |
Declined cards
↑ Back to topThe following card numbers can be used to test what happens when the payment is declined by the customer’s bank for various reasons.
Description | Number |
---|---|
Generic decline | 4000 0000 0000 0002 |
Insufficient funds | 4000 0000 0000 9995 |
Lost card | 4000 0000 0000 9987 |
Stolen card | 4000 0000 0000 9979 |
Expired card | 4000 0000 0000 0069 |
Incorrect CVC | 4000 0000 0000 0127 |
Processing error | 4000 0000 0000 0119 |
Incorrect number | 4242 4242 4242 4241 |
Exceeding velocity limit | 4000 0000 0000 6975 |
Fraud prevention
↑ Back to topThe following card numbers can be used to test Stripe’s automated fraud prevention.
Description | Number |
---|---|
Blocked by Stripe Radar | 4100 0000 0000 0019 |
Elevated risk level | 4000 0000 0000 9235 |
Manual capture
↑ Back to topTo test a card payment authorization with manual capture:
- Go to Payments > Settings in your site’s dashboard.
- Enable test mode as shown above.
- Enable authorize and capture.
- Place a test order as explained here.
- Go to WooCommerce > Orders and open the order you just placed.
- Confirm the order has a note in the sidebar stating: “A payment of $XX.XX was authorized using WooPayments.”
- Capture the charge.
- Confirm the order now has a note in the sidebar like so: “A payment of $XX.XX was successfully captured using WooPayments.”
- Go to Payments > Transactions.
- Confirm that a corresponding transaction with the type Charge is listed.
Testing express checkouts
↑ Back to topHow to test each specific express checkout method varies depending on which one you’d like to test. Please see the links below, which go to the dedicated documents for those payment methods, for instructions on how to test them.
Testing non-card payments
↑ Back to topTest most non-card payment methods (e.g. Bancontact, EPS, and so on) is as simple as placing a test order while that payment method is selected. Most often, you’ll be taken to a page hosted by Stripe where you can choose to authorize or fail the test payment.
After you choose whether to authorize the test payment or fail it, you will automatically be redirected back to your site, and the relevant result shown.
Buy now, pay later
↑ Back to topPlease see the Testing section of the buy now, pay later document for full details on how to test our supported BNPL payment methods.
SEPA
↑ Back to topIn order to test a SEPA transaction, you will need to use one of the following IBANs. These use Austria as the country, since the country does not matter much for testing purposes.
Test IBAN | Result |
---|---|
AT611904300234573201 | Payment succeeds. |
AT861904300235473202 | Payment fails. |
AT591904300235473203 | Payment succeeds, but is disputed. |
Testing refunds
↑ Back to topTo test refunding an order:
- Place a test order as shown above.
- Go to WooCommerce > Orders.
- Click the order ID of the test order.
- Follow the refund process.
The order status should change to Refunded, and your test balance will be reduced.
Testing disputes
↑ Back to topTo simulate a dispute with WooPayments, place a test order as shown above using one of the cards from this table:
Description | Number | Details |
---|---|---|
Transaction not authorized | 4000 0000 0000 0259 | The charge will be disputed as unauthorized. This type of dispute is protected after 3D Secure authentication. |
Product not received | 4000 0000 0000 2685 | With default account settings, charge succeeds, only to be disputed as product not received. This type of dispute isn’t protected after 3D Secure authentication. |
The order will be processed, but the payment will be disputed immediately. You can then view and respond to the dispute by going to Payments > Disputes in your site’s dashboard.
Dispute responses
↑ Back to topAfter creating a dispute with a dispute test card above, you can also test the dispute response process.
- Go to Payments > Disputes in your site’s dashboard.
- Click the dispute in the list to open it up.
- Click Challenge Dispute.
- In the Additional Details field, do one of the following:
- Enter
winning_evidence
to win the dispute. - Enter
losing_evidence
to lose the dispute.
- Enter
- At the bottom, click Submit Evidence.
You can also accept the dispute in Step 3 instead of challenging it to test that scenario.