View Categories

Testing

1 min read

Simulate payments to test your integration.

To test your integration, simulate transactions without moving money by using special test values in a test environment.

Test cards act like fake credit cards and allow you to simulate the following scenarios:
• Successful payments depending on the brand or country of the card
• Card errors due to declines, fraud, or invalid data
• Disputes and refunds


How to use test cards #

Interactive testing
When doing interactive testing, use a card number like 4242 4242 4242 4242. Enter the card number in the Dashboard or in any payment form.


• Use a valid future date, such as 12/34
• Use any 3-digit CVC (4 digits if using an American Express card)
• Use any value for the other fields in the form


Cards by brand #

To simulate a successful payment for a specific card brand, use the test cards from the list below.

Cards that simulate successful payments

Card NumberTypeResultExpiryCVC
4242 4242 4242 4242VisaSuccessful paymentAny future123
4000 0566 5566 5556Visa (3D Secure)3DS AuthenticationAny future123
5555 5555 5555 4444MastercardSuccessful paymentAny future123
3782 8224 6310 005American ExpressSuccessful paymentAny future1234


Cards that simulate errors #

To test your integration’s error-handling logic by simulating payments that are declined for various reasons by the card issuer, use the test cards in this section. Using one of these cards will result in a card error with the corresponding error code and decline code.

DescriptionCard NumberError CodeDecline Code
Generic decline4000 0000 0000 0002card_declinedgeneric_decline
Insufficient funds4000 0000 0000 9995card_declinedinsufficient_funds
Lost card4000 0000 0000 9987card_declinedlost_card
Stolen card4000 0000 0000 9979card_declinedstolen_card
Expired card4000 0000 0000 0069expired_cardNone
Incorrect CVC4000 0000 0000 0127incorrect_cvcNone
Processing error4000 0000 0000 0119processing_errorNone
Incorrect number4242 4242 4242 4241incorrect_numberNone


Based on Stripe official documentation: docs.stripe.com/testing

Powered by BetterDocs

Add a Comment

Your email address will not be published.

DISSAU

Typically replies within a day