Luhn Algorithm Validator
Validate and generate Luhn check digits (mod 10 algorithm) for credit cards, IMEI, ICCID, and other identifier numbers. Everything runs in your browser — numbers are never transmitted.
Card / Identifier Number
Result
Enter a number above to validate
How the Luhn Algorithm Works
- Starting from the rightmost digit (the check digit), move left.
- Double the value of every second digit. If doubling results in a number greater than 9, sum the digits (e.g., 7×2=14 → 1+4=5).
- Sum all the digits (both doubled and untouched).
- If the total mod 10 = 0, the number is valid.
Where Luhn Is Used
| Identifier | Typical Length | Check Digit |
|---|---|---|
| Credit / Debit Card (PAN) | 13–19 digits | Last digit |
| IMEI (mobile device ID) | 15 digits | Last digit |
| ICCID (SIM card serial) | 19–20 digits | Last digit |
| NPI (US healthcare provider) | 10 digits | Last digit |
| Canadian SIN | 9 digits | Last digit |
Privacy note: All validation runs in your browser using JavaScript. No card numbers are ever sent to a server. Test numbers provided are industry-standard test PANs — not real cards.