EAN-13 vs UPC-A: which barcode does your product need?
If you are getting a product ready for shops or online marketplaces, you will be asked for a barcode, usually an EAN-13 or a UPC-A. They are closely related, and choosing between them is easier than it looks. The more important question is where your numbers come from.
Barcodes · Published 2026-10-07
What they have in common
Both EAN-13 and UPC-A are retail barcodes that identify a specific product, often called a GTIN (Global Trade Item Number). Both encode digits only, both end with a check digit, and both are designed to be scanned at checkouts all over the world.
The differences
- Length: UPC-A has 12 digits, EAN-13 has 13.
- Origin: UPC-A was created in the United States and is traditional in the US and Canada. EAN-13 is used in almost every other country.
- Compatibility: a UPC-A number is effectively an EAN-13 with a leading zero. Since 2005, retailers in North America have been expected to scan EAN-13 as well, so in practice both work almost everywhere.
A simple rule: if your company's barcode numbers come from GS1 US, you will usually print UPC-A. If they come from GS1 in any other country, you will usually print EAN-13.
Where the numbers come from (this matters most)
Anyone can draw a barcode, but the number inside it must be unique worldwide. Retail product numbers are managed by GS1, a non-profit organisation with an office in most countries. You license a company prefix from GS1, and then assign numbers to each of your products, including each size and colour.
Cheap barcodes sold online by resellers are often old numbers originally registered to another company. Many large retailers and marketplaces check numbers against the GS1 database, and products with mismatched barcodes can be rejected or removed. If you plan to sell through major stores or marketplaces, get your numbers from GS1 directly.
For internal use, such as stock in your own shop or warehouse that never leaves your business, you do not need GS1 numbers. Code 128 is usually a better choice there.
How the check digit works
The last digit of an EAN-13 or UPC-A is calculated from the others so that scanners can detect a misread. For EAN-13, the first twelve digits are multiplied alternately by 1 and 3, added up, and the check digit is whatever brings the total up to the next multiple of ten.
You never need to calculate it by hand. A barcode generator either adds it automatically or tells you when the one you entered is wrong, which is a useful sign of a typo.
Printing size and quality
At 100% magnification, an EAN-13 or UPC-A symbol is roughly 37 mm wide and 26 mm tall. GS1 allows scaling between 80% and 200%. Going below 80% or cutting the height short (truncation) makes scanning unreliable and may be rejected by retailers.
- Print black bars on a white or light background. Red bars are invisible to many scanners.
- Keep the clear space to the left and right of the bars empty.
- Use a vector format (SVG or PDF) for packaging artwork.
- Test print samples with a real scanner or a phone scanning app.
What about EAN-8?
EAN-8 is a shorter 8-digit version for very small packages where an EAN-13 will not fit, such as lip balm or chewing gum. EAN-8 numbers are allocated individually by GS1 and only when there is genuinely no room for an EAN-13.
Generating them with Zonlet
Once you have your numbers, Zonlet's barcode generator creates EAN-13, EAN-8 and UPC-A barcodes as PNG, SVG or PDF, one at a time or in a batch from a spreadsheet. It checks that the number is valid and adds the human-readable digits under the bars.