Barcode Check Digit Validator
Validate the check digit on a UPC, EAN, GTIN, ISBN or SSCC code — or calculate the right one — with the GS1 working shown.
Every GTIN, UPC, EAN, ISBN-13 and SSCC ends in a check digit — one final digit whose only job is to catch typing and scanning mistakes. It is worked out from all the other digits by a fixed formula, so if a single digit in the code was mistyped, transposed or misread, the check digit almost never still fits. This page runs that formula both ways: paste a complete code and it tells you whether the last digit is the one the formula produces, or paste the code without its last digit and it calculates the digit that belongs there, showing the full working either way.
Type or paste a barcode number. In Validate mode the code must be complete, last digit included. In Calculate mode leave the last digit off and the tool works out what it should be — either way you see every step of the working.
A pass means the digits agree with each other — not that the code is registered or yours to use. Commercial barcodes need numbers licensed from GS1. Algorithms last verified: November 2026.
Quick answers
How is a barcode check digit calculated?
For UPC, EAN, GTIN and SSCC codes: starting from the digit immediately left of the check digit and moving left, multiply alternate digits by 3 and by 1, add everything up, and the check digit is whatever makes the total a multiple of 10 — formally, (10 − (sum mod 10)) mod 10.
Take the EAN-13 4006381333931. Its first twelve digits, weighted 3, 1, 3, 1… from the right, sum to 89. The next multiple of 10 is 90, so the check digit is 1 — and the printed code ends in 1. The weighting is anchored to the right-hand end, which is why the same recipe works unchanged for 8, 12, 13, 14 and 18-digit codes.
Does a valid check digit mean a barcode is genuine?
No. A valid check digit means only that the digits are mathematically consistent with each other. Anyone can calculate a correct check digit for an invented number, so a pass says nothing about whether GS1 assigned the number, who it belongs to, or whether it matches the product in the box.
Think of the check digit as a spelling check, not an identity check. Marketplaces and retailers verify codes against GS1’s databases for assignment and ownership; this tool verifies arithmetic. It is the right test for catching typos, transposed digits and bad supplier data — and the wrong test for proving a code is licensed.
Which barcode formats does this validator cover?
The full GS1 modulo-10 family — GTIN-8 / EAN-8, GTIN-12 / UPC-A, GTIN-13 / EAN-13 including ISBN-13, GTIN-14 and SSCC-18 — plus ISBN-10 with its modulo-11 scheme and X check character. Paste a full code to validate it, or the code minus its last digit to calculate what belongs there.
The format is recognised from the length of what you paste, and the result names the format it assumed, so a mismatch is visible rather than silent. UPC-E is the one common format left out on purpose: its check digit belongs to the expanded UPC-A form, so an honest check has to expand the number first.
How to use
- Choose Validate to check a complete code, or Calculate to work out the missing last digit.
- Paste or type the code — spaces and hyphens are ignored, and an ISBN-10 may end in X.
- Read the verdict, then walk the step table: every digit, its multiplier and its product, exactly as the formula sees them.
- If a code fails, the corrected version is shown — retype the original from its source rather than trusting the correction, because the wrong digit may not be the last one.
About this tool
The same modulo-10 recipe covers the whole GS1 family — GTIN-8 (EAN-8), GTIN-12 (UPC-A), GTIN-13 (EAN-13, and ISBN-13, which is an EAN-13 built on the 978 or 979 prefix), GTIN-14 and the 18-digit SSCC used on pallets and shipping units. Only the length changes. ISBN-10 is the one older scheme in the set: it uses a modulo-11 calculation whose answer can be 10, printed as the letter X, and this page handles that too. UPC-E is deliberately not covered: its check digit is worked out on the expanded UPC-A form of the number, not on the eight printed digits, so checking it directly would give wrong answers.
Sellers meet check digits in unglamorous, expensive places: a marketplace listing rejected because one digit of a UPC was copied wrong, a case label whose GTIN-14 fails a warehouse scan test, a spreadsheet of supplier codes that needs a fast self-consistency pass before import. A check-digit pass cannot tell you a code is genuine, licensed or attached to the right product — only the GS1 registry can speak to assignment — but it reliably tells you a code is broken, and it tells you before a platform or a customer does.
Everything runs in your browser. The codes you paste are never uploaded, sent to a server or stored.
How it works
GS1 modulo-10 (GTIN-8/12/13/14, UPC-A, EAN-8/13, ISBN-13, SSCC-18): number the data digits from the right, starting next to where the check digit sits. Multiply digits in odd positions of that count (1st, 3rd, 5th…) by 3 and the rest by 1. Add all the products. Check digit = (10 − (sum mod 10)) mod 10. A complete code is valid when its last digit equals that result.
ISBN-10 modulo-11: multiply the nine data digits by 10, 9, 8 … down to 2 and add the products. Check character = (11 − (sum mod 11)) mod 11, with 10 written as X. That is why an ISBN-10 can end in a letter while no other code in this family can.
Worked examples
A valid UPC-A: 036000291452: The eleven data digits weighted from the right sum to 58, so the check digit must be 2 — and the code ends in 2. Verdict: valid.
Calculating an EAN-13 check digit: Enter 400638133393 in Calculate mode: the weighted sum is 89, the check digit is 1, and the complete code is 4006381333931.
A code that fails: 4006381333932 weights to the same 89, so its last digit should be 1, not 2. Verdict: invalid — the page shows the corrected code, and the likely story is a typo in the last digit or one of the digits before it.
ISBN-10 with its older maths: 0306406152: the nine data digits weighted 10 down to 2 sum to 130; 130 mod 11 is 9, so the check character is 2. The code ends in 2 — valid.
Formats covered, at a glance
| Format | Full length | Enter this many to calculate | Scheme |
|---|---|---|---|
| GTIN-8 / EAN-8 | 8 | 7 | GS1 modulo-10 |
| ISBN-10 | 10 (may end in X) | 9 | Modulo-11 |
| GTIN-12 / UPC-A | 12 | 11 | GS1 modulo-10 |
| GTIN-13 / EAN-13 / ISBN-13 | 13 | 12 | GS1 modulo-10 |
| GTIN-14 (case / carton codes) | 14 | 13 | GS1 modulo-10 |
| SSCC-18 (pallets / shipments) | 18 | 17 | GS1 modulo-10 |
UPC-E is not listed: its check digit is calculated on the expanded UPC-A form, so it cannot be checked honestly from the eight printed digits alone.
Frequently asked questions
What is a check digit for?
It is an error trap. Keying a 13-digit code by hand or scanning a damaged label goes wrong in predictable ways — one digit substituted, two neighbouring digits swapped — and a single well-chosen extra digit catches the great majority of those mistakes at the moment the code is read, before the error reaches an order, a listing or a warehouse system.
Why did my code fail when only the last digit looks wrong?
Possibly the last digit really is the wrong one — it is the digit most often dropped and retyped. But a failure only proves the digits disagree with each other; the actual mistake can sit anywhere in the code. Use the corrected version this page shows as a lead, then confirm against the product, the GS1 record or your supplier paperwork before changing anything official.
Is ISBN-13 checked the same way as EAN-13?
Yes — an ISBN-13 is an EAN-13 that starts with 978 or 979, and it uses the identical modulo-10 check digit. ISBN-10 is the different one: modulo-11, weights running 10 down to 2, and a check character that can be X. This page picks the scheme from the length of the code you paste.
Can this tool check a UPC-E?
No, and deliberately. A UPC-E compresses a UPC-A by removing zeros, and its check digit is calculated on the full UPC-A form. Running the short printed digits through the formula directly would pronounce good codes bad, so UPC-E is out of scope rather than wrong — expand the number to UPC-A first, then validate that.
I made up a number and added the right check digit. Can I use it on my products?
The arithmetic will pass, but the number is not yours to use. GTINs are licensed through GS1 member organisations, and marketplaces increasingly cross-check listings against GS1 data — an unassigned or borrowed number can get listings removed and, printed on retail packaging, creates problems with every retailer downstream. For internal-only labels that never enter retail, a private numbering scheme with a Code 128 barcode (see the generator linked below) avoids the GTIN system entirely.
What is an SSCC, and why is it 18 digits?
The Serial Shipping Container Code identifies one logistic unit — a pallet, a carton, a shipment — uniquely for its journey through the supply chain. Its 18 digits are an extension digit, your GS1 company prefix, a serial reference you assign, and the same modulo-10 check digit as the rest of the family, which is why this page can validate it alongside the product codes.
More free tools
Merchandise Processing Fee Calculator
Estimate the US Merchandise Processing Fee (MPF) on an import entry — FY2027 CBP rates: 0.3464% of value, minimum $34.58, maximum $670.86.
AQL Calculator
Look up the AQL sampling plan for your lot: code letter, sample size and accept / reject numbers per ANSI/ASQ Z1.4 and ISO 2859-1.
Code 128 Barcode Generator
Turn any text or SKU into a scannable Code 128 barcode — drawn in your browser, downloadable as PNG or SVG.
A+ Brief Studio
Turn a product photo and your selling points into an Amazon A+ / Shopify product-page creative brief — module copy structure, hero-image storyboard and a comparison outline, generated in your browser.
QR Code Generator
Turn any link or text into a scannable QR code in seconds.
Word Counter
Count words, characters, sentences and reading time as you type.