Skip to main content
Version: v2

Card Validation

Card validation in Stripe ensures that the card information provided is accurate and can be used for transactions. Below are the key steps and checks Stripe performs during card validation:


Key Validation Steps​

1. Basic Format Checks​

  • Card Number: Stripe checks the card number format using the Luhn algorithm.
  • Expiration Date: Ensures the date is valid and not expired.
  • CVC (Card Verification Code): Checks for correct length and format.

2. Card Brand Identification​

  • Stripe identifies the card brand (Visa, Mastercard, etc.) based on the card number prefix (BIN/IIN).

3. Test Card Detection​

  • Stripe automatically detects if a test card number is being used (useful for development and testing).

4. Zero-Value Authorization​

  • Zero-Value Authorization is a process where a temporary authorization of $0 or $1 is placed on a card. This authorization does not result in an actual charge on the customer’s statement. It is used to verify the card’s validity and detect issues such as expired cards or incorrect information, and can also support fraud prevention efforts.

5. Address Verification System (AVS)​

  • When provided, Stripe can use the billing address to perform an AVS check, verifying the address with the card issuer.

6. Card Verification Code (CVC) Check​

  • Stripe can verify the CVC provided with the card issuer for additional security.

7. 3D Secure​

  • For stronger authentication, Stripe supports 3D Secure verification when enabled, prompting the cardholder for additional authentication (e.g., SMS code, app approval).

tip

Not all checks are performed for every card or transaction. The specific validation steps may vary based on card type, issuer, and Stripe configuration.