What is a Check Digit? How It Works, Modulo-10 Formula & Examples
A check digit is the final, calculated digit found at the far right of a barcode number (such as a 12-digit UPC-A, 13-digit EAN-13, or 14-digit GTIN-14). It is derived using a standardized mathematical algorithm (GS1 Modulo-10) to safeguard against human typing errors, transmission bugs, and scanner misreads.
Interactive Modulo-10 Check Digit Calculator
Test the Modulo-10 formula live: Enter 7, 11, 12, or 13 digits to calculate the missing check digit.
Why Do Barcodes Need Check Digits?
Every day, billions of retail items, pallets, and parcels are scanned across distribution centers and grocery stores. However, optical scanning isn't 100% foolproof:
- Single-digit substitution errors: A scanner might mistake an imperfectly printed
8for a3. - Transposition errors: A human typist entering a barcode manually might type
14instead of41. - Partial/truncated scans: A laser passing across only half of a damaged barcode could return an incomplete number.
The GS1 check digit algorithm is engineered so that virtually 100% of single-digit errors and over 98% of transposition errors result in a checksum failure, immediately alerting the system before wrong charges or incorrect deliveries occur.
How to Calculate a Check Digit (The Modulo-10 Formula)
The GS1 system utilizes the Modulo-10 algorithm. Regardless of whether you are calculating a check digit for an 8-digit EAN-8, a 12-digit UPC-A, a 13-digit EAN-13, or a 14-digit GTIN-14, the core logic remains identical:
Step-by-Step Breakdown for UPC-A (12 Digits)
Let's calculate the check digit for the 11-digit UPC data 03600029145:
| Position | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 |
|---|---|---|---|---|---|---|---|---|---|---|---|
| Digit | 0 | 3 | 6 | 0 | 0 | 0 | 2 | 9 | 1 | 4 | 5 |
| Weight | ×3 | ×1 | ×3 | ×1 | ×3 | ×1 | ×3 | ×1 | ×3 | ×1 | ×3 |
| Product | 0 | 3 | 18 | 0 | 0 | 0 | 6 | 9 | 3 | 4 | 15 |
1. Sum of products: 0 + 3 + 18 + 0 + 0 + 0 + 6 + 9 + 3 + 4 + 15 = 58
2. Modulo 10: 58 % 10 = 8 (remainder)
3. Check digit: (10 - 8) = 2
4. Complete 12-digit UPC: 036000291452
Check Digit Weight Rules Across Different Barcode Formats
A common point of confusion is whether the leftmost digit is multiplied by 3 or by 1. The golden rule is to always assign weights starting from the rightmost data digit moving left:
- UPC-A (11 data digits): Rightmost is odd (position 11), so it starts with
3. Moving left, position 1 (the first digit) also gets weight3. - EAN-13 (12 data digits): Rightmost is even (position 12), so it gets weight
3. Moving left, position 1 (the first digit) gets weight1. - GTIN-14 (13 data digits): Rightmost is odd (position 13), so it gets weight
3. Position 1 (Packaging Indicator) gets weight3.
Online Verification & Tools
To automate check digit calculation or bulk verification without manual arithmetic, explore our tools:
- GTIN Check Digit Calculator & Validator - Live calculation for GTIN-8, 12, 13, and 14.
- UPC-A Generator - Generate 12-digit retail barcodes with automated checksums.
- EAN-13 Generator - International retail barcodes with country prefix decoding.
- ITF-14 Generator - Master carton shipping barcodes with bearer bars.