EAN-13 is one of the most recognisable barcode formats in the world. It is commonly printed on consumer products and scanned at retail checkouts.
The symbol contains 13 digits and represents a GTIN-13, a Global Trade Item Number used to identify a trade item. The barcode carries the number in a form that a scanner can read quickly.
What is an EAN-13 barcode?
EAN-13 is a linear, one-dimensional barcode in the EAN/UPC family.
It is designed for high-speed scanning in retail environments. You will see it on food, cosmetics, stationery, household goods, books, and many other packaged products.
An EAN-13 barcode contains:
- a 12-digit item reference;
- a final check digit;
- guard patterns that help a scanner recognise the symbol;
- human-readable digits printed below the bars.
The check digit helps detect common data-entry and scanning errors. It is calculated from the preceding digits rather than chosen freely.
What do the 13 digits mean?
The structure of a GTIN-13 depends on how the number was allocated.
It may include:
- a GS1 prefix;
- a company prefix or licensed number range;
- an item reference assigned by the brand owner;
- a check digit.
The first digits do not reliably tell you where a product was manufactured. They relate to the GS1 organisation through which the number was allocated, and businesses may manufacture products in other countries.
Avoid describing the prefix as a country-of-origin code on product pages or internal documentation.
Do I need to obtain an EAN number from GS1?
For products sold through normal retail and marketplace channels, you will generally need a legitimate GTIN allocated through GS1 or otherwise accepted by the relevant trading partner.
Barcode Safe generates the EAN-13 image from a value you provide. It does not issue or register GTINs.
Before printing packaging, confirm:
- who owns the brand;
- who is responsible for allocating the GTIN;
- whether the retailer requires GS1-issued identifiers;
- whether each product variant needs a different GTIN;
- whether the number has already been assigned.
You can use GS1’s verification services to check information associated with a GTIN where available.
EAN-13 and the check digit
The thirteenth digit is a check digit calculated from the first 12 digits.
A simplified calculation works like this:
- Starting from the right of the first 12 digits, multiply alternating digits by 3.
- Add those results to the remaining digits.
- Find the amount needed to reach the next multiple of 10.
- That amount is the check digit.
Most barcode software calculates or validates this automatically.
A correct check digit only confirms that the number follows the mathematical rule. It does not prove that the GTIN is registered, belongs to your company, or is assigned to the correct product.
EAN-13 versus UPC-A
EAN-13 contains 13 digits, while UPC-A contains 12.
A UPC-A number can be represented within the GTIN system by adding leading zeros. Modern retail scanners commonly support both symbols, but a retailer or marketplace may still specify which one it expects.
Use EAN-13 when your market or trading partner expects GTIN-13. Use UPC-A when the North American retail workflow specifically asks for a UPC symbol.
For a detailed comparison, read UPC-A vs EAN-13: What Is the Difference?.
How to generate an EAN-13 barcode
To create the image:
- Obtain the correct 12- or 13-digit value.
- Open the Free Barcode Generator.
- Select EAN-13.
- Enter the number.
- Confirm the displayed digits.
- Download the barcode as PNG, SVG, or PDF.
- Test the final printed version.
If you enter 12 digits, the generator may calculate the check digit. If you enter all 13, it should validate that the final digit is correct.
Always confirm the behaviour of the tool before using the output in production.
How large should an EAN-13 barcode be?
EAN-13 symbols have defined size and quiet-zone requirements. Reducing a barcode too far can make it difficult or impossible to scan.
The correct dimensions depend on the applicable GS1 specifications, the printing process, packaging, and scanner environment.
As a practical rule:
- use the recommended size whenever the packaging allows;
- scale width and height proportionally;
- do not make the bars shorter simply to fit a design;
- preserve the quiet zones;
- ask your printer about expected print gain and resolution.
Do not rely on visual appearance alone. A barcode can look sharp but still fall outside the required dimensions.
Colour and contrast
Black bars on a white background remain the safest option.
Scanners need clear contrast between the dark bars and light spaces. Some colour combinations may look strong to the human eye but perform poorly with red-light scanners.
Avoid:
- red or orange bars;
- dark backgrounds behind black bars;
- transparent backgrounds over complex artwork;
- metallic or reflective inks;
- gradients through the barcode;
- reversing the barcode to light bars on a dark field.
Where brand colours are essential, test and verify the final printed symbol.
Common EAN-13 mistakes
Using an invented number
A generator can create a valid-looking image for any mathematically valid number. That does not make the number suitable for retail use.
Reusing one GTIN across different products
Different sizes, colours, formulations, pack counts, or product changes may require separate identifiers under GS1 rules.
Cropping the quiet zones
The white margins help scanners locate the start and end of the barcode.
Stretching the artwork
Changing width without changing height, or vice versa, can damage the symbol.
Testing only on screen
Print quality, label material, curves, seams, and packaging finishes all affect scanning.
EAN-13 checklist
Before publishing or printing:
- Confirm the GTIN is authorised for the product.
- Confirm the check digit.
- Confirm the product variant.
- Use a vector file for packaging artwork where possible.
- Preserve quiet zones and proportions.
- Print a production sample.
- Scan it using the intended equipment.
- Store the approved barcode with the related product data.
EAN-13 is simple to generate, but reliable implementation depends on accurate numbering and careful print production.