EAN-13 barcodes: getting, checking and printing them

Updated

The EAN-13 is the 13-digit barcode printed on almost every product sold in Europe and the UK. It identifies one product worldwide: two different products must never share the same number. That is what lets a till, a marketplace or a warehouse know exactly what has been scanned.

What the 13 digits mean

An EAN-13 (also called a GTIN-13) has three parts:

Getting EAN-13 barcodes for retail

To sell through supermarkets, chemists or most online marketplaces, the barcodes must be registered to your company. In the UK this means joining GS1 UK. You receive a company prefix, create your product numbers and record each product’s data with GS1. The annual fee depends on turnover; current prices are published by GS1 UK.

You will find barcodes sold online for a few pounds each. These are usually numbers from old prefixes registered to another company. They may work in a small independent shop, but retailers and Amazon increasingly check that the barcode belongs to the brand selling the product. A mismatch can block your listing.

This generator prints barcodes you already own. It does not issue “official” numbers: making up an EAN-13 risks copying the number of an existing product.

What about internal use?

For stock, bin locations, tools or samples you don’t need GS1 numbers:

Working out the check digit

The generator adds the check digit if you enter 12 digits, and rejects a 13-digit code whose check digit is wrong. Here is the calculation for the internal example 200123456789:

  1. Starting from the right, multiply the digits alternately by 3 and by 1: 9×3, 8×1, 7×3, 6×1, 5×3, 4×1, 3×3, 2×1, 1×3, 0×1, 0×3, 2×1.
  2. Add them up: 27 + 8 + 21 + 6 + 15 + 4 + 9 + 2 + 3 + 0 + 0 + 2 = 97.
  3. The check digit is what’s needed to reach the next multiple of ten: 100 − 97 = 3.

So the full code is 2001234567893. One typo in the first twelve digits changes the result, which is why a mistyped code is rejected by the scanner.

Printing an EAN-13 that scans at the till

If a printed barcode won’t scan, see barcode not scanning.