A valid number may be made up
About 1 in 10 random numbers has a correct check digit. Google says to submit a GTIN only when you are sure it is correct, and to leave it out when in doubt.
Calculate the check digit from the first 7, 11, 12 or 13 digits of a GTIN, or validate a full GTIN-8, UPC (GTIN-12), EAN (GTIN-13) or GTIN-14 before it goes into your product feed. Every step of the mod-10 sum is shown.
Berend Vrakking, founder. Last updated .
Your result
The check digit for 871234567890 is 6. The full GTIN is 8712345678906, a GTIN-13 (EAN-13).
The sum, digit by digit
| Position from the right | Digit | Weight | Product |
|---|---|---|---|
| 1 | 0 | × 3 | 0 |
| 2 | 9 | × 1 | 9 |
| 3 | 8 | × 3 | 24 |
| 4 | 7 | × 1 | 7 |
| 5 | 6 | × 3 | 18 |
| 6 | 5 | × 1 | 5 |
| 7 | 4 | × 3 | 12 |
| 8 | 3 | × 1 | 3 |
| 9 | 2 | × 3 | 6 |
| 10 | 1 | × 1 | 1 |
| 11 | 7 | × 3 | 21 |
| 12 | 8 | × 1 | 8 |
| Sum | 114 | ||
| Next multiple of ten | 120 | ||
| Check digit | 6 | ||
The start values are illustrative data.
How it works
Illustrative data. The first 12 digits of a GTIN-13 are 871234567890. Number them from the right, weight them 3, 1, 3, 1 and so on, and add the products.
| Step | Calculation | Result |
|---|---|---|
| Digit 1: 0 | 0 × 3 | 0 |
| Digit 2: 9 | 9 × 1 | 9 |
| Digit 3: 8 | 8 × 3 | 24 |
| Digit 4: 7 | 7 × 1 | 7 |
| Digit 5: 6 | 6 × 3 | 18 |
| Digit 6: 5 | 5 × 1 | 5 |
| Digit 7: 4 | 4 × 3 | 12 |
| Digit 8: 3 | 3 × 1 | 3 |
| Digit 9: 2 | 2 × 3 | 6 |
| Digit 10: 1 | 1 × 1 | 1 |
| Digit 11: 7 | 7 × 3 | 21 |
| Digit 12: 8 | 8 × 1 | 8 |
| Sum | 0 + 9 + 24 + 7 + 18 + 5 + 12 + 3 + 6 + 1 + 21 + 8 | 114 |
| Next multiple of ten | 114 rounded up | 120 |
| Check digit | 120 − 114 | 6 |
The check digit is 6, so the full GTIN is 8712345678906. To validate a GTIN, run the same sum on every digit except the last and compare the result with the last digit. Weighting the check digit too, with weight 1, brings the total to 120, a multiple of ten.
Formats
Merchant Center treats UPC, EAN, JAN, ISBN-13 and ITF-14 codes as GTINs. The calculator tells them apart by length, and by the 978 or 979 start of an ISBN-13.
| Digits | Format | Barcode names |
|---|---|---|
| 8 | GTIN-8 | EAN-8, JAN |
| 12 | GTIN-12 | UPC (North America) |
| 13 | GTIN-13 | EAN (Europe), JAN, ISBN-13 for books |
| 14 | GTIN-14 | ITF-14, for multipacks |
Google asks for 12-digit codes instead of 8-digit UPC-E codes, and for ISBN-13 instead of ISBN-10. This calculator does not convert either: it reads 8 digits as a GTIN-8.
Limits
About 1 in 10 random numbers has a correct check digit. Google says to submit a GTIN only when you are sure it is correct, and to leave it out when in doubt.
Google says not to submit numbers that start with 02, 04 or 2 (restricted) or 05, 98 or 99 (coupon). The calculator flags them for 8, 12 and 13 digit codes.
A different colour or size has its own GTIN, so check each variant row, not the product once.
A UPC that starts with 0 loses it when a spreadsheet stores the number as a number. Add the zero back before you validate, and keep the column as text.
Paste this script tag into your own page to show the calculator there, with the same maths and no sign-up. It fits the width of your page, resizes with the calculator and follows the visitor’s light or dark setting.
The script adds the calculator and a link to the full version under it. Keep the attribution link: it credits the calculator.
Product Metrics does not edit your feed. It segments your products by advertising clicks and return against your target, then writes each segment to a Merchant Center label your campaigns use.