What a dummy card number is
A dummy card number is a number that meets the format rules for a payment card but has no account behind it. Payment processors publish these numbers for developers. They work in sandbox mode. A live gateway declines them.
Numbers processors publish
- 4242 4242 4242 4242, Visa test number.
- 5555 5555 5555 4444, Mastercard test number.
- 3782 822463 10005, American Express test number.
Stripe, PayPal, and Adyen list these in developer docs. Each number pairs with a test expiry date and a test CVC. The numbers stay the same because they never authorize.
Format rules behind a number that looks valid
ISO/IEC 7812 sets the structure. The first six digits form the issuer identification number, or BIN. The remaining digits identify the account. The final digit is a check digit.
The check digit comes from the Luhn algorithm. Take 4242424242424242. Double the digits in even positions counting from the right. The result is eight 8s, which sum to 64. The other eight digits are 2s, which sum to 16. The total is 80. 80 divides by 10, so the number passes.
Dummy numbers compared with live card data
A dummy number has no BIN owner, no balance, and no cardholder. A live card number maps to an account at a bank. Data sold as fullz or dumps ties to real accounts and carries a balance and a billing address. A test number carries none of that. It passes a format check and fails an authorization check.
Where dummy numbers run
Sandbox and test modes at payment processors. Stripe test mode accepts 4242 4242 4242 4242 and returns a success response. Live mode returns card_declined or invalid_number. The same split applies at most gateways.
Legal limits in the United States
Using a test number at a live merchant to get goods or services is fraud. 18 U.S.C. § 1029 covers access devices, which includes card numbers. A first offense carries up to 10 years in some cases. The FTC tracks payment fraud reports and publishes them.
Checks to run on any number
- Run the Luhn check. A fail ends the test.
- Match the first six digits to a published BIN range.
- Send the number to the gateway and read the response code.
- Confirm the number sits in a test range before you use it in code.