If two listings carry the same valid GTIN, they are almost certainly the same product. That makes identifiers the cheapest and most reliable way to match items across stores, and the place where most matching pipelines start. It also makes them a source of quiet errors: a dropped leading zero, a merchant SKU mistaken for a global code, a placeholder that passes as a number. This glossary covers what each identifier is, who issues it, and how far you can trust it.
Key takeaways
- UPC and EAN are names for GTIN formats: GTIN-12 is the UPC, GTIN-13 is the EAN (also JAN). GTIN-8 is for small items and GTIN-14 for cases.
- A GTIN padded with leading zeros is the same GTIN. Normalize everything to 14 digits before comparing.
- Every GTIN ends in a check digit. Validating it catches typos, but not every dummy value.
- ASINs are Amazon’s own catalog IDs, SKUs are each merchant’s own codes, and MPNs are only meaningful together with a brand.
The glossary
| Identifier | Issued by | Format | Unique across | Good for matching? |
|---|---|---|---|---|
| GTIN | Brand owners, via a GS1 member organization | 8, 12, 13 or 14 digits, last is a check digit | Globally, per trade item | Yes, the best when valid |
| UPC (UPC-A) | Same as GTIN | GTIN-12; mostly North America | Globally | Yes, after normalizing |
| EAN (EAN-13), JAN | Same as GTIN | GTIN-13; Europe and most of the world | Globally | Yes, after normalizing |
| GTIN-14 | Same as GTIN | 14 digits; cases and packaging levels | Globally | Rarely relevant for shelf items |
| ISBN | National ISBN agencies | ISBN-13 is a GTIN-13 starting 978 or 979 | Globally, per edition | Yes, for books |
| ASIN | Amazon | 10 alphanumeric characters; for books, usually the ISBN-10 | Amazon’s catalog | Only within Amazon |
| MPN | The manufacturer | Free-form part number | Within one brand | Yes, together with brand |
| SKU | Each merchant | Free-form | Within one merchant | No, except within a store |
GTIN formats from GS1’s explanation of GTIN, EAN and UPC. Google’s Merchant Center specification treats MPN as required only when a product has no GTIN.
GTIN, UPC and EAN are the same family
GS1 describes the GTIN as the number printed under a product’s barcode. UPC and EAN are not separate systems but names for two lengths of it: GTIN-12 is also called UPC, and GTIN-13 is also called EAN or JAN. GTIN-8 exists for items too small for a full barcode, and GTIN-14 identifies packaging levels such as a case of 12.
Because the formats nest, the same product can appear with different lengths in different places: 12 digits on a US retailer’s site, 13 in a European feed, 14 in a distributor’s system. Leading zeros make up the difference.
One product, three spellings
A 12-digit UPC padded with leading zeros to 13 and 14 digits is still the same GTIN
This is the most common identifier bug in matching pipelines. A US store lists 012345678905, a marketplace lists 0012345678905, a spreadsheet stored the number as an integer and kept 12345678905. String comparison says three products. Normalizing to 14 digits with leading zeros says one.
The check digit
The last digit of every GTIN is calculated from the others. Starting from the digit just left of the check digit and moving left, multiply the digits alternately by 3 and 1, add the results, and take the amount needed to reach the next multiple of ten.
How the check digit is calculated
Weights alternate 3, 1, 3, 1 starting from the digit next to the check digit
Data behind the chart
| Step | Value |
|---|---|
| Digits | 001234567890 |
| Weighted sum | 85 |
| Check digit | 5 |
| GTIN-13 | 0012345678905 |
Validating the check digit catches every single-digit typo and most swaps of adjacent digits. It does not catch every placeholder. “123456789012”, a favorite dummy value in sloppy feeds, happens to have a valid check digit, so validation also needs a short list of known dummy values. A failing GTIN should be stored as raw text and excluded from automatic matching, not silently “fixed”.
Validate and normalize in one step
Pythonimport re
DUMMIES = {"123456789012", "1234567890128", "12345678901231"} # extend from your data
def gtin14(raw):
"""Return the GTIN as 14 digits, or None if it is not a valid GTIN."""
if raw is None:
return None
digits = re.sub(r"[\s-]", "", str(raw))
if not digits.isdigit() or len(digits) not in (8, 12, 13, 14):
return None
body, check = digits[:-1], int(digits[-1])
total = sum(int(d) * (3 if i % 2 == 0 else 1)
for i, d in enumerate(reversed(body)))
if (10 - total % 10) % 10 != check:
return None
if set(digits) == {"0"} or digits.lstrip("0") in DUMMIES:
return None
return digits.zfill(14)
assert gtin14("012345678905") == gtin14("0012345678905") == "00012345678905" Note what the function does not accept: an 11-digit number that lost its leading zero when a spreadsheet treated it as an integer. You can sometimes recover those by left-padding and re-checking, but only when you know the source dropped zeros, and the result should be flagged.
ASIN: Amazon’s catalog number
An ASIN is the 10-character identifier Amazon assigns to a product page in its catalog. For books it is generally the ISBN-10. For everything else it is Amazon’s own code. It is extremely useful inside Amazon, where every offer from every seller hangs off one ASIN, and useless as a key outside it. To connect an Amazon listing to other stores you still need the GTIN, brand or MPN shown on the listing, and on Amazon those are not always displayed.
MPN and SKU: local identifiers
A manufacturer part number is assigned by the brand, so WH-1000XM5 means something only alongside “Sony”. The pair (brand, MPN) is a strong matching key, provided you normalize case, spaces and punctuation, and watch for retailers who append their own suffixes for colors or bundles.
A SKU is the retailer’s own stock-keeping code. It is unique inside one store and meaningless across stores, even when it looks like an MPN. Treat a field labeled “SKU” on a product page as merchant-scoped unless you have evidence otherwise.
How to use them for matching
- Normalize and validate GTINs; match on valid ones first.
- For products without a valid GTIN, match on normalized brand plus MPN, with attribute checks (pack size, color, capacity) to veto near-misses.
- Use titles and attributes only for what remains, and send low-confidence pairs to review.
That cascade, and what the academic benchmarks say about the last step, is covered in how to match products across stores. Expect identifiers to cover less than you hope: in apparel and private-label goods, shared GTINs are often missing entirely.
Quick answers
What is the difference between GTIN, UPC and EAN?
GTIN is the umbrella standard from GS1. UPC is the 12-digit form (GTIN-12), used mainly in North America, and EAN is the 13-digit form (GTIN-13), used in Europe and most other countries.
Is a UPC with a leading zero the same as an EAN?
Yes. A 12-digit UPC padded with a leading zero becomes a valid 13-digit EAN for the same product. Normalizing all GTINs to 14 digits makes them directly comparable.
How do I check whether a GTIN is valid?
Recalculate the check digit: multiply the digits alternately by 3 and 1, starting from the digit next to the check digit, sum them, and the check digit is the amount needed to reach the next multiple of 10.
Can I use an ASIN to match products outside Amazon?
No. An ASIN is Amazon’s own catalog identifier. Outside Amazon you need the product’s GTIN, or its brand and manufacturer part number.
What is the difference between an MPN and a SKU?
An MPN is assigned by the manufacturer and is meaningful together with the brand. A SKU is assigned by each retailer for its own inventory and is unique only within that store.
Matched product data across stores
We validate identifiers, normalize GTINs and match listings across retailers, with review for the cases identifiers can’t settle. See price monitoring.
