Skip to content
TextArray
100% local

Credit card number checker

Check card numbers against the Luhn checksum and detect the scheme — a developer tool for test numbers, not a card verifier.

Input

Credit card number checker

This is a checksum and format checker for developers and testers — not a card verifier. It runs the Luhn (mod 10) algorithm over each number and tells you whether the digits are self-consistent, plus which scheme the prefix and length suggest: Visa, Mastercard, American Express or Discover. It cannot tell whether a card actually exists, is active or has funds — no such check is possible without a payment network, and this tool never contacts one.

Use it when building or testing payment forms: verify that your fixture data passes the same Luhn check a real gateway performs, confirm that a validation regex accepts 13-digit Visa and 15-digit Amex numbers, or generate quick sanity checks for standard test numbers like 4111 1111 1111 1111 (Visa) or 5500 0000 0000 0004 (Mastercard). Paste one number per line — spaces and dashes inside a number are fine — and each line comes back annotated as valid, invalid checksum, or not a card number when it is not 12–19 digits.

The Show option switches between the full annotated report and a filtered list of only the valid or only the failing lines, which is handy for cleaning a fixture file. Scheme detection can be switched off if you only care about the checksum.

Everything runs locally in your browser: nothing is sent, logged or stored anywhere. Still, treat real card numbers as the sensitive data they are — this tool is meant for the publicly documented test numbers used in development.

FAQ

Does a "valid" result mean the card is real?
No. Valid only means the digits pass the Luhn checksum and have a plausible length. Whether a card exists, is active or has funds can only be answered by a payment network — this tool never contacts one.
Which card schemes are detected?
Visa (starts with 4; 13, 16 or 19 digits), Mastercard (51–55 or 2221–2720; 16 digits), American Express (34 or 37; 15 digits) and Discover (6011, 65, 644–649 or 622126–622925; 16–19 digits). Other prefixes are checked for the Luhn checksum only.
Can I paste numbers with spaces or dashes?
Yes. Spaces and dashes inside a number are ignored, so 4111-1111-1111-1111 and 4111 1111 1111 1111 both work. Anything that is not 12–19 digits after that is reported as not a card number.
What test numbers can I use?
The publicly documented ones: 4111 1111 1111 1111 (Visa), 5500 0000 0000 0004 (Mastercard), 3782 822463 10005 (American Express) and 6011 1111 1111 1117 (Discover) all pass the Luhn check.
Are the numbers I paste uploaded anywhere?
No. The check runs entirely in your browser and nothing is sent, logged or stored. Even so, use the documented test numbers rather than real cards.