Retail · 13 digits

EAN-13 barcode generator

Enter your twelve digits and the check digit is calculated as you type. The preview shows exactly what will print, including the quiet zones and the guard bars that drop below the rest of the symbol.

Barcode

·

Enter 12 digits and the thirteenth is calculated, or paste all 13 to have it checked.

Size
Appearance

Keep dark bars on a light background — scanners read contrast, not colour.

Preview

Your barcode appears here.

The number

What the thirteen digits mean

An EAN-13 is not an arbitrary number. It is a GTIN-13, and every part of it is allocated deliberately.

  • The first two or three digits are the GS1 prefix. They identify the GS1 member organisation that issued the company number — 73 for Sweden, 50 for the UK, 40–44 for Germany. They do not tell you where the product was manufactured, which is a common misreading.
  • The company number follows. Its length varies: a business that licenses capacity for ten products gets a long company number and few product digits; a business with a hundred thousand products gets a short one.
  • The item reference is whatever is left. You assign these yourself, one per sellable variant — a different size, colour or pack quantity is a different item and needs its own number.
  • The check digit closes the number. It is derived from the twelve before it, so a scanner that misreads one bar can tell that something is wrong instead of returning the wrong product.

The maths

How the EAN-13 check digit is calculated

Working from the right of the twelve-digit payload, digits are multiplied alternately by 3 and 1. Add the products together, then subtract that sum from the next multiple of ten. For 590123412345 the weighted sum is 63, the next multiple of ten is 70, and the check digit is 7 — giving 5901234123457.

This is the same mod-10 algorithm used by UPC-A, EAN-8, ITF-14 and SSCC-18, with the weights lining up from the right in each case. If you want to see the arithmetic laid out digit by digit, the check digit calculator shows every step.

Printing

How large should an EAN-13 be?

The nominal size — what GS1 calls 100% magnification — is 37.29 mm wide and 25.93 mm tall, with an X-dimension of 0.33 mm. You may scale between 80% and 200%, which puts the X-dimension between 0.264 mm and 0.660 mm. The readout under the preview shows your current X-dimension so you can check before printing rather than after.

Two mistakes account for most unreadable retail labels. The first is going below 80%: the bars end up narrower than the scanner's optical resolution and it simply sees noise. The second is truncating the bar height to make the symbol fit a cramped label. Height is not decoration — it lets an operator sweep the scanner across at an angle and still cross every bar. If space is genuinely tight, move to EAN-8 rather than squashing an EAN-13.

Leave the quiet zones alone as well. EAN-13 needs eleven blank modules on the left and seven on the right, which is roughly 3.6 mm each side at nominal size. Every file this tool produces already includes them, so the safe rule is never to crop a downloaded barcode.

Before retail

Where the number itself comes from

This tool draws the symbol; it does not issue numbers. If your product will be scanned at a till in a shop you do not own, you need a GTIN licensed through your national GS1 organisation, either as a single number or as a company prefix. Retailers verify that the prefix belongs to you, so a number invented at random will fail their onboarding even though it produces a perfectly valid-looking barcode.

If the label is for your own warehouse, a market stall, a library or a workshop, none of that applies. You can pick any number that fits the format and print it. Many people use the 20–29 prefix range, reserved for in-store use, precisely because it will never collide with a manufacturer's real GTIN.

Questions

Frequently asked questions

Can I enter 13 digits instead of 12?

Yes. Paste the full thirteen and the tool verifies the check digit, telling you the correct one if it does not match. Enter twelve and it appends the right digit for you.

Is EAN-13 the same as GTIN-13?

The number is a GTIN-13; EAN-13 is the barcode symbol that carries it. In everyday use the two names are used interchangeably.

Will an EAN-13 scan in the United States?

Yes. US retail systems have accepted 13-digit codes since the Sunrise 2005 deadline, though some older equipment and some marketplace listings still expect a 12-digit UPC-A.

Can I print EAN-13 on a home inkjet?

For internal labels, yes — print the SVG at 100% or larger on plain white paper and test it. For retail packaging, a print shop or thermal transfer printer holds bar widths far more reliably.

What if my number starts with a zero?

That is fine and usually means it is a UPC-A number expressed as thirteen digits. Both forms encode to the same bars.

Do I need a new number for each size or colour?

Yes. Anything a customer can buy separately, or that has a different price, needs its own GTIN. Only identical items share a number.