Skip to content

Luhn Validator

Check any number against the Luhn checksum and see the working.

Quick Tool Overview

The Luhn Validator checks a number against the mod-10 checksum and shows the working — which digits double, what each contributes, and the final total — because seeing it is what makes the algorithm implementable.

What it does
Validates a number against the Luhn checksum
You give it
Any number, with or without separators
You get back
A verdict plus the full calculation
Best for
Card numbers, IMEIs and any Luhn-checked reference
Developer Tools Free, unlimited use No sign-up Runs in your browser

About the Luhn Validator

Paste a number and the Luhn checksum is calculated with the working shown: which digits are doubled, what each becomes, the running total and the final modulo. Seeing it is far more useful than a yes or no when you are implementing the check yourself.

The algorithm is used for far more than card numbers — IMEI numbers, some national identification numbers, and a variety of account references all use it. Where the input looks like a card number the scheme is identified from its prefix and length, and the expected check digit is shown when the number fails, which usually makes the typo obvious.

Key features of the Luhn Validator

The working shown

Each digit with whether it doubled and what it contributed, so you can implement the check yourself from what you see.

The expected digit

When a number fails, the check digit that would have been correct is given — which usually makes the typo obvious.

Scheme identified

A card number is matched to its scheme from the prefix and length.

Not just cards

IMEIs, some national identification numbers and many account references use the same checksum.

Clear about what it proves

Luhn catches typos. It says nothing about whether an account exists, and the page does not pretend otherwise.

How to use the Luhn Validator

  1. 1

    Paste the number

    Spaces and hyphens are ignored.

  2. 2

    Read the verdict

    Pass or fail, plus the check digit that would have been correct.

  3. 3

    Follow the working

    Each digit is shown with what it contributes to the total.

  4. 4

    Check the scheme

    Card numbers are identified from their prefix and length.

Frequently asked questions

Every single-digit error and almost every transposition of adjacent digits — which together are nearly all the mistakes a person makes typing a long number.

Reviews of the Luhn Validator

What people who use the Luhn Validator think of it. Reviews come from visitors and are posted as written.

No ratings yet

Yours would be the first.

  • 5 0 reviews rated 5 stars
  • 4 0 reviews rated 4 stars
  • 3 0 reviews rated 3 stars
  • 2 0 reviews rated 2 stars
  • 1 0 reviews rated 1 star

Write a review

Used this tool? Your rating helps the next person decide.

Your rating

Plain text only — links, email addresses and HTML are not accepted. Your name and review are shown publicly; nothing else is collected. See the privacy policy.

0 reviews

Newest first

No reviews yet

Be the first to rate the Luhn Validator. It takes half a minute and no account.

Write the first review

More developer tools