Skip to content
feedlab Request early access

Free tool

GTIN, EAN and UPC validator

This validator checks whether a barcode is a structurally valid GTIN: the right length for EAN-8, UPC-A, EAN-13 or ITF-14, and a check digit that matches the digits before it. It accepts a whole column pasted from a catalogue at once.

Paste one identifier per line, or a column copied straight out of a spreadsheet. Each value is checked for length and for its check digit, and where a code is one digit short the correct check digit is calculated for you.

Runs entirely in your browser. Nothing you paste is uploaded or stored.

Validate identifiers

Checked
Valid
Invalid
Value Result Detail

Frequently asked questions

What makes a GTIN valid?

Two things: a length of 8, 12, 13 or 14 digits, and a final check digit that matches a calculation over the digits before it. Anything else is not a GTIN, whatever else it might be.

How is the GTIN check digit calculated?

Working right to left from the digit before the check digit, each digit is multiplied alternately by 3 and 1 and the results are added. The check digit is whatever is needed to bring that total up to the next multiple of ten.

Why does my barcode fail when it looks right?

Usually a lost leading zero or a transposed pair of digits. A spreadsheet strips the zero, which shortens the value, and a typo keeps the length correct while breaking the check digit.

Is an ISBN a GTIN?

An ISBN-13 is, and it validates here. An ISBN-10 is not a valid GTIN length: prefix it with 978 and recalculate the check digit to convert it.

What should I do with the invalid values?

Do not send them. An invalid identifier is treated as an error while a missing one is only a warning, so route those products to brand with mpn instead, or declare identifier_exists where they genuinely have no barcode.

Attributes this relates to

Errors this helps you avoid

Related concepts

Primary sources

Channel specifications change. These are the official documents this page is based on.