EAN vs UPC: what is the difference?

UPC-A is a 12 digit barcode used mainly in the United States and Canada, while EAN-13 is a 13 digit barcode used in most other countries; a UPC-A is simply an EAN-13 that starts with 0. Scanners worldwide read both, so the real question is which number your retailer or marketplace asks for and where your company registered it.

6 min read

The short answer

UPC-A (Universal Product Code) holds 12 digits and was created in the United States in the 1970s. EAN-13 (European Article Number, now officially called International Article Number) holds 13 digits and was built on top of UPC so that the rest of the world could join the same system. Both encode a product number called a GTIN: a UPC-A carries a GTIN-12, an EAN-13 a GTIN-13.

The key fact is that the two are compatible. Put a 0 in front of a 12 digit UPC-A and you get a valid EAN-13 with the same check digit. Since 2005, retail scanners in North America have been required to read EAN-13 as well, so a product with either barcode can be sold in most stores. You choose the format based on where you sell and which number your GS1 office issued, not on scanner support.

Try it here: EAN-13 Barcode Generator

Open the full tool page

Side by side comparison

The two symbols look almost identical: the same bar widths, the same longer guard bars at the start, middle and end, and the same 95 module wide structure. The differences are in the number of digits and how they are printed under the bars.

FeatureUPC-AEAN-13
Digits1213
Product numberGTIN-12GTIN-13
Main regionUnited States, CanadaEurope, Asia, Latin America, most of the world
Check digitLast digitLast digit
Human readable digitsFirst and last digit outside the barsFirst digit outside the bars, then two groups of six
Short version for small packsUPC-E (6 digits)EAN-8 (8 digits)
Read by scanners worldwideYesYes
Convert to the otherAdd a leading 0Only possible if it starts with 0

How the digits are built

An EAN-13 starts with a GS1 prefix of two or three digits. It identifies the GS1 member organization that issued the number, not the country where the product was made. A Turkish company gets numbers starting with 869, a Spanish one 84, a Mexican one 750, but all of them can produce goods anywhere. Next comes the company prefix, then the item reference chosen by the company, and finally the check digit.

Some prefixes have special meanings worth knowing: 978 and 979 are used for books (the EAN-13 is the ISBN), 977 for magazines and other serials, and 20 to 29 are reserved for in-store use such as weighed products, so they are not unique outside one retailer. Numbers starting with 0 are UPC compatible and were issued by GS1 US or GS1 Canada.

In a UPC-A the first digit is the number system digit (0, 1, 6, 7, 8 and 9 for regular products, 2 for weighed items, 3 for medicines, 5 for coupons), followed by the company prefix, the item reference and the check digit.

How the check digit is calculated

Both formats end with a check digit that lets the scanner catch a misread. The calculation is the same idea in both. For EAN-13, multiply the first 12 digits alternately by 1 and 3, starting with 1 on the left, add everything up, and the check digit is the number that brings the total to the next multiple of 10.

Example: for 590123412345 the weighted sum is 83, so the check digit is 7 and the full code is 5901234123457. For UPC-A the weights start with 3 on the left instead: for 03600029145 the sum is 58 and the check digit is 2, giving 036000291452. Written as an EAN-13, that is 0036000291452, with the same check digit, which is why adding a 0 always works.

You do not need to calculate it yourself. In the generator above, type 12 digits for EAN-13 (or 11 for UPC-A) and the check digit is added; type the full code and it is verified. A wrong digit is reported with its line number and the correct code, for example The check digit should be 7. With Barcode type on Automatic, a 12 digit number whose last digit is a valid UPC check digit is drawn as UPC-A; any other 12 digit number is treated as an EAN-13 without its check digit, and the 13th digit is added. Since a 12 digit EAN number can happen to pass the UPC check, pick UPC-A or EAN-13 yourself when you want to be sure.

Which one do you need?

  • Selling in stores or on marketplaces in the US and Canada: retailers and Amazon US accept both, but numbers from GS1 US are traditionally printed as UPC-A. Use the format your GS1 office gave you.
  • Selling in Europe, Turkey, Latin America, the Middle East or Asia: use EAN-13. This is what local GS1 offices issue and what retailers expect.
  • Very small packages: EAN-8 exists for items with no room for a full symbol, but EAN-8 numbers are issued separately by GS1 and are not a shortened version of your EAN-13.
  • Books: use the ISBN as an EAN-13 starting with 978 or 979.
  • Internal use only (your own warehouse, shelf labels, stock codes): you do not need GS1 numbers at all. Code 128 is usually a better choice because it also holds letters.

Where barcode numbers come from

A barcode is only as good as the number inside it. The generator draws a correct symbol for any valid number, but retailers and large marketplaces check whether the number is registered to your company in the GS1 database. Numbers bought cheaply from resellers often belong to someone else, and listings with them can be blocked.

The safe route is to join the GS1 organization in your country, which assigns a company prefix and lets you number your own products. The fee depends on the country and on how many numbers you need.

Printing tips that prevent scan failures

  • Keep the size. The standard EAN-13 and UPC-A symbol is about 37.3 mm wide and 25.9 mm tall at 100%. Scanners handle roughly 80% to 200% of that; go smaller only after testing.
  • Do not cut the bars short. Truncating the height to fit a label makes the code harder to scan from an angle.
  • Leave the light margins. EAN-13 needs a quiet zone of 11 modules on the left and 7 on the right; UPC-A needs 9 on each side. Never print text or a border inside them.
  • Use dark bars on a light background. Black on white is safest; red bars or a dark background often fail because scanners use red light.
  • Print labels at 100% scale. When printing the PDF label sheet, choose actual size, not fit to page, so every bar keeps its width.

Step by step

  1. Enter the numbersType one code per line, 12 digits for EAN-13 or 11 for UPC-A, and add a tab or semicolon with a product name if you want it on the label.
  2. Choose the barcode typePick EAN-13 or UPC-A under Barcode type. Automatic recognizes a full 12 digit UPC by its check digit, but choosing the type yourself removes any doubt.
  3. Check the previewValid codes are drawn right away; lines with a wrong check digit or length are listed with the correction.
  4. DownloadChoose PNG, SVG or PDF labels, set the size and height, and download one file, a ZIP or an A4 label sheet.

Frequently asked questions

Can I use an EAN-13 barcode in the United States?

Yes. North American retail scanners have been required to read EAN-13 since 2005, and marketplaces such as Amazon accept EAN-13. Some retailers still ask for UPC numbers in their own systems, so check their supplier requirements.

How do I convert a UPC to an EAN-13?

Add a 0 in front of the 12 digit UPC-A. The check digit stays the same, so 036000291452 becomes 0036000291452.

Can I convert an EAN-13 to a UPC?

Only if the EAN-13 starts with 0. Remove that 0 to get the UPC-A. An EAN-13 starting with any other digit has no UPC-A equivalent.

Does the prefix show where my product was made?

No. The prefix shows which GS1 office issued the number. A product with a 869 or 84 prefix can be manufactured anywhere.

Is the barcode generator free, and are my codes uploaded?

It is free, and everything runs in your browser. Your codes and product names are not sent to any server.

Can I make up my own EAN numbers?

For internal use, yes. For selling in stores or on marketplaces, no: the number must be registered to your company through GS1, or the listing can be rejected.