EAN-13 Barcode: What It Means and How to Make One

An EAN-13 barcode is the 13-digit product barcode printed on most items sold in shops around the world. The bars are a machine-readable copy of a 13-digit number, and the last digit is a check that helps a scanner catch reading mistakes. You can make one in a few seconds with the free Barcode Generator: type 12 digits and the tool adds the 13th for you. This guide explains what the digits mean, how to work out the check digit by hand, how EAN-13 differs from UPC-A, and what to check before you print. For a wider overview of barcode types, see our free barcode generator guide.

crossorigin="anonymous">

What is an EAN-13 barcode?

EAN-13 is a barcode format that stores exactly 13 digits. It was built for retail, so a till or a stock system can read a product number fast.

The format has no letters. If you need letters or symbols, try Code 128 instead (see how to make a Code 128 barcode).

What do the 13 digits mean?

In general terms, the 13 digits split into four parts:

  • Prefix: the first few digits come from the numbering system that issued the number. The prefix points to the GS1 office that gave out the range. It does not always tell you where the product was made.
  • Company number: digits that identify the business that holds the number range.
  • Item number: digits the company picks to tell its products apart, for example one per flavor or pack size.
  • Check digit: the final digit, calculated from the other twelve.

The middle parts vary in length, so do not read meaning into them. To look up a code on a package, see the barcode of a product page.

Where is an EAN-13 barcode used?

  • On packaged goods on shop shelves.
  • On books: the ISBN-13 number is printed as an EAN-13 barcode.
  • In warehouses and online marketplaces, where sellers are often asked for a product barcode number.

How is the EAN-13 check digit calculated?

The check digit is the 13th digit. You can work it out from the first 12 with five plain steps:

  1. Write down the 12 digits and number them from the left: position 1 to position 12.
  2. Add the digits in the odd positions (1, 3, 5, 7, 9, 11). Their weight is 1.
  3. Add the digits in the even positions (2, 4, 6, 8, 10, 12) and multiply that sum by 3.
  4. Add the two results together.
  5. Find how much you must add to reach the next multiple of 10. That number is the check digit. If the total already ends in 0, the check digit is 0.

A worked example

Take the 12 digits 590123412345.

  • Odd positions: 5, 0, 2, 4, 2, 4. The sum is 17.
  • Even positions: 9, 1, 3, 1, 3, 5. The sum is 22, and 22 x 3 = 66.
  • Total: 17 + 66 = 83.
  • The next multiple of 10 is 90, and 90 – 83 = 7.

The check digit is 7, so the full number is 5901234123457. If you type those 12 digits into the generator, the tool shows the same 13th digit.

EAN-13 vs UPC-A: what is the difference?

UPC-A has 12 digits and is common in the United States and Canada. EAN-13 has 13 digits and is used in most other places. The two are closely related: a UPC-A number can be written as an EAN-13 by adding a 0 at the front, and the check digit stays the same.

The Barcode Generator can draw both. For UPC-A you type 11 digits (the check digit is added) or 12 digits (the last one must be a valid check digit). Pick the one your seller platform or shop asks for.

How do I make an EAN-13 barcode online?

Here is how to do it with the Barcode Generator. It runs in your browser, and the value you type is not uploaded.

  1. Open the tool and choose EAN-13 as the barcode type.
  2. Type your 12 digits. The tool adds the check digit. If you type 13, the last must already be valid, or the tool shows a clear error.
  3. Change the bar width, bar height and margin if you like. You can also show or hide the number under the bars.
  4. Download a PNG at 1x, 2x or 4x size, or download an SVG file.

Choose the 4x PNG or the SVG for print.

Do I need to buy or register my numbers?

The Barcode Generator only draws the bars. It does not issue or register product numbers, and a number you invent may already belong to another product. Retail EAN and UPC numbers for products sold in shops come through GS1. Check the GS1 website or your local GS1 office for how it works in your country, what it costs and which rules apply.

For private use, such as boxes in your own storage room, you can choose your own numbers.

How big should I print it, and how do I test it?

  • Keep a blank margin. Leave clear white space on the left and right of the bars. Text or a border placed too close can stop a scan.
  • Use dark bars on a light background. Black on white is the safest choice. Pale or low-contrast colors can fail.
  • Do not stretch the image. Scale it evenly. If width and height change by different amounts, the bars are distorted.
  • Do not shrink it too far. Tiny bars blur in print. For retail products, check the GS1 size guidance.
  • Test-scan the printed result. We tested that the tool’s output for all six barcode types can be decoded by a barcode reader library. Even so, ink and paper change the result, so scan a real printout. Our barcode scanner guide explains scanning options.

What are the most common EAN-13 mistakes?

  • Typing 13 digits when you only know 12, so the last digit is not a valid check digit.
  • Using made-up numbers on products you plan to sell in shops.
  • Printing in light gray or on a dark or glossy background.
  • Skipping the test scan.

Frequently Asked Questions

How many digits does an EAN-13 barcode have?

It has 13 digits. The first 12 carry the prefix, company and item information, and the 13th is the check digit.

Can I make an EAN-13 barcode from only 12 digits?

Yes. Type the 12 digits into the Barcode Generator and it calculates and adds the check digit for you.

Why does the tool say my check digit is wrong?

If you type all 13 digits, the last one has to match the check digit worked out from the first 12. If it does not, the tool shows an error. Remove it and let the tool add the right one.

Does the Barcode Generator give me an official product number?

No. It only draws the bars. Retail numbers for products sold in shops come through GS1, so check the GS1 website or your local GS1 office.

Can a phone scan an EAN-13 barcode?

Many phone cameras and scanner apps can read it, but results depend on print quality and light. Always test a printed copy before you make a large batch.

More free tools

Leave a Comment