Pick a standard, type the code and get its check digit, or paste a full code to see whether it is valid. The weighted sum is laid out digit by digit, and related forms (GTIN-14, EAN-13, ISBN-10 or ISBN-13) are shown too.
Last updated:
Enter the code without its check digit to calculate it, or the full code to validate it.
Enter your values to see the result.
Advertisement
Advertisement
How to use the Check Digit Calculator
Choose the standard, for example UPC-A or ISBN-10.
Enter the code without its check digit to calculate it, or in full to validate it.
Click Calculate (results also update as you type).
Read the check digit or verdict and the converted forms.
Follow the weighted sum in the table if you want to check the maths by hand.
Check digit rules at a glance
Standard
Length
Weights
Check digit
Example
UPC-A
12
3, 1 from the right
(10 − sum mod 10) mod 10
036000291452
EAN-13 / GTIN-13
13
3, 1 from the right
(10 − sum mod 10) mod 10
4006381333931
EAN-8
8
3, 1 from the right
(10 − sum mod 10) mod 10
96385074
GTIN-14 / ITF-14
14
3, 1 from the right
(10 − sum mod 10) mod 10
10012345000017
SSCC
18
3, 1 from the right
(10 − sum mod 10) mod 10
shipping container code
ISBN-13
13
1, 3 from the left
(10 − sum mod 10) mod 10
9780306406157
ISBN-10
10
10, 9 … 2
(11 − sum mod 11) mod 11, 10 = X
0306406152
ISSN
8
8, 7 … 2
(11 − sum mod 11) mod 11, 10 = X
0317-8471
Mod 11 (2–7)
any
2, 3, 4, 5, 6, 7 from the right, repeating
(11 − sum mod 11) mod 11
123455
Worked example: UPC-A 03600029145
From the right: 5×3 + 4×1 + 1×3 + 9×1 + 2×3 + 0×1 + 0×3 + 0×1 + 6×3 + 3×1 + 0×3 = 15 + 4 + 3 + 9 + 6 + 0 + 0 + 0 + 18 + 3 + 0 = 58. The next multiple of 10 is 60, so the check digit is 2 and the full UPC is 036000291452.
Tips
Counting weights from the right means the same rule works for every GS1 length: the digit next to the check digit always gets weight 3.
An ISBN-13 is just an EAN-13 with a 978 or 979 prefix. An ISSN becomes a 977 EAN-13 barcode with a two-digit issue code before the new check digit.
For card numbers and IMEIs, which use the Luhn algorithm, use the Luhn Algorithm Checker.
Frequently asked questions
How is a UPC or EAN check digit calculated?
Starting from the digit next to the check digit and moving left, multiply the digits alternately by 3 and 1, then add the products. The check digit is the amount needed to reach the next multiple of 10: (10 − sum mod 10) mod 10. For the UPC 03600029145 the sum is 58, so the check digit is 2.
Is the GTIN check digit the same for UPC, EAN and GTIN-14?
Yes. All GS1 identifiers use the same mod 10 rule with weights 3 and 1 counted from the right. That is why you can pad a UPC-A or EAN-13 with leading zeros to 14 digits and the check digit stays the same.
Why does an ISBN-10 sometimes end in X?
ISBN-10 uses mod 11, so the check value can be 0 to 10. A single character is needed for 10, and the Roman numeral X is used. ISSN uses the same idea.
How do I convert a UPC-A to EAN-13?
Put a 0 in front. The 13-digit code has the same check digit because the leading zero adds nothing to the weighted sum.
What does a check digit protect against?
It catches typing and scanning mistakes. The GS1 rule catches all single-digit errors and most swaps of neighbouring digits; mod 11 schemes like ISBN-10 catch all single errors and all adjacent swaps.
Does a valid check digit mean the product or book exists?
No. It only shows the number is internally consistent. Barcode numbers must still be licensed from GS1, and ISBNs and ISSNs are assigned by their national agencies.
Can I calculate other schemes?
Yes. Choose Custom weights to enter any weight pattern (such as 7, 3, 1), the direction they are applied, the modulus and whether the check is the remainder or its complement.
Are all the tools on FreeToolCabin tested for quality and accuracy?
Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.