Credit Card Validator
Validate credit card numbers with Luhn algorithm and detect card network
This tool validates credit card numbers using the Luhn algorithm (MOD-10 check) and identifies the card network (Visa, Mastercard, Amex, Discover, etc.) from the Bank Identification Number (BIN). Everything runs in your browser — card numbers are never transmitted.
The Luhn Algorithm
Hans Peter Luhn invented this checksum formula in 1954. It works by:
- Starting from the rightmost digit, double every second digit
- If doubling produces a number greater than 9, subtract 9
- Sum all digits
- If the total modulo 10 equals 0, the number is valid
The Luhn check catches all single-digit errors and most transpositions of adjacent digits — the most common data entry mistakes.
Card Network Detection
The first 6-8 digits (BIN/IIN) identify the card issuer:
- Visa: Starts with 4 (13, 16, or 19 digits)
- Mastercard: Starts with 51-55 or 2221-2720 (16 digits)
- American Express: Starts with 34 or 37 (15 digits)
- Discover: Starts with 6011 or 65 (16 digits)
Privacy Notice
This is one of the most privacy-sensitive tools you can use online. Never enter real credit card numbers into online validators that send data to a server. This tool runs the Luhn algorithm entirely in JavaScript in your browser — verify in DevTools Network tab that zero requests are made.