Luhn / Verhoeff / Damm Check Digits

Enter numbers one per line, choose Luhn, Verhoeff or Damm and validate or generate a check digit. Spaces and dashes in the input are ignored.

Use the tool

Why this tool exists

Card numbers, IMEI numbers, national ID numbers and many account references end in a check digit that catches mistyped digits before a request is ever sent. Luhn is the best known and catches any single-digit error and most swaps of neighbouring digits. Verhoeff and Damm catch every single-digit error and every adjacent swap, at the price of lookup tables. Developers building forms need to test their validators, and support staff sometimes need to see whether a number is simply mistyped. This tool checks a list of numbers or computes the digit to append. It shows only whether the arithmetic works, not whether a number was ever issued, so passing it says nothing about whether a card is real. Nothing leaves your browser.

How to use it

  1. Enter one number per line; spaces and dashes are ignored.
  2. Choose Luhn, Verhoeff or Damm and select validate or generate.
  3. Read valid or INVALID for each line, or the check digit to append.

Frequently asked questions

What is the difference between Luhn, Verhoeff and Damm?

Luhn is simple and widespread, used for payment cards. Verhoeff and Damm use tables and catch all single-digit errors and all adjacent transpositions, which Luhn does not (it misses 09 and 90).

Does a valid check digit mean the number is real?

No. It only means the digits are consistent. A number can pass and still be unissued or belong to someone else. Never treat it as proof of validity.

How does generate mode work?

Enter the number without its check digit. The tool shows the digit to add and the full number with it appended.

What input is accepted?

Digits only, after removing spaces and dashes. Letters or other symbols raise an error naming the offending line.