EAN-13 Barcodes Explained: Structure, Checksum & Bulk Generation
EAN-13 Barcodes Explained: Structure, Checksum & Bulk Generation
Look at the back of almost any product in a supermarket outside North America and you will find it: a strip of black bars with 13 digits printed underneath. That is an EAN-13 barcode — the global language of the retail checkout.
EAN-13 (originally “European Article Number”, today maintained by GS1 as the International Article Number) encodes a 13-digit Global Trade Item Number. When a cashier scans your product, the register reads those digits and looks up the price. Simple — but every digit has a job, and the last one is pure mathematics.
Whether you are launching a product, organizing a warehouse, or printing price labels for a market stall, understanding EAN-13 will save you from expensive mistakes. This guide covers exactly what each digit means, how the check digit is calculated (with a fully worked example), how EAN-13 differs from UPC-A, the most common errors to avoid, and how to generate hundreds of EAN-13 barcodes in bulk — free, right in your browser.
What Is an EAN-13 Barcode?
EAN-13 is a linear (1D) barcode symbology standardized by GS1, the non-profit organization that governs product identification worldwide. It encodes exactly 13 numeric digits as a pattern of bars and spaces, with the digits printed in human-readable form below.
Those 13 digits form a GTIN-13 — a Global Trade Item Number. Think of it as a product’s passport number: the digits identify the numbering authority, the brand owner, and the specific item. Unlike a QR code, which can store URLs and text, EAN-13 stores only those 13 digits, and
New to the numbering system? Read our GTIN number explained for the four GTIN formats, how GS1 numbers are licensed, and how to create scannable GTIN barcodes free.
that limitation is its strength. Every point-of-sale scanner in the world knows how to read it, and the fixed length makes validation straightforward.
EAN-13 is the default retail barcode across Europe, Asia, Africa, Latin America, and Oceania. In the United States and Canada, its 12-digit sibling UPC-A dominates — but the two are closely related, as you will see below.
EAN-13 Structure: What the 13 Digits Mean
The 13 digits fall into four logical groups. The boundary between the two middle groups varies from brand to brand, but the structure is always the same:

1. GS1 Prefix — the first 2–3 digits
The GS1 prefix identifies the GS1 member organization that issued the company number. Common examples include 400–440 for Germany, 500–509 for the United Kingdom, 690–699 for China, and 000–139 for the United States (the range used for UPC-A codes).
One widespread misunderstanding: the prefix does not tell you where the product was manufactured. It only indicates where the brand licensed its GS1 company prefix.
2. Company Number — the next group of digits
GS1 assigns this number to a brand owner when they license a company prefix. Its length varies: a company that needs numbers for many products receives a shorter company number, leaving more digits available for product references.
3. Product Reference — the remaining digits
The brand owner assigns these digits to individual products. Each size, color, or flavor should get its own number — this is what makes checkout prices accurate.
4. Check Digit — the 13th digit
The final digit is never assigned. It is calculated from the first 12 using a fixed formula, and its only job is error detection: if a digit is mistyped or misread, the check digit will not match, and the scanner or software rejects the code.
An illustrative example. Take the code 4006381333931. One plausible grouping is:
- 400 — GS1 prefix (Germany)
- 63813 — company number
- 3393 — product reference
- 1 — check digit
Keep in mind that the split between company number and product reference differs for every brand — only GS1 and the brand owner know the exact allocation.
How the EAN-13 Check Digit Is Calculated
The check digit uses a modulo-10 algorithm. Here is the procedure for the first 12 digits:
- Number the 12 digits from the left, positions 1 through 12.
- Add the digits in the odd positions (1st, 3rd, 5th, 7th, 9th, 11th).
- Add the digits in the even positions (2nd, 4th, 6th, 8th, 10th, 12th), then multiply that sum by 3.
- Add the two results together.
- Find the remainder of that total divided by 10.
- The check digit is 10 minus the remainder. If the remainder is 0, the check digit is 0.
Worked example: 400638133393 → ?
| Position | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Digit | 4 | 0 | 0 | 6 | 3 | 8 | 1 | 3 | 3 | 3 | 9 | 3 |
- Odd positions (1, 3, 5, 7, 9, 11): 4 + 0 + 3 + 1 + 3 + 9 = 20
- Even positions (2, 4, 6, 8, 10, 12): 0 + 6 + 8 + 3 + 3 + 3 = 23, then 23 × 3 = 69
- Total: 20 + 69 = 89
- Remainder: 89 ÷ 10 leaves a remainder of 9
- Check digit: 10 − 9 = 1
The complete EAN-13 code is 4006381333931. Any good barcode generator computes this automatically, so you never need to do the arithmetic by hand — but knowing the method lets you spot a corrupted number instantly. If the check digit does not match, something is wrong with the other twelve.
Where EAN-13 Barcodes Are Required
EAN-13 is the price of admission to retail shelves across most of the world:
- Brick-and-mortar retail. Supermarkets, pharmacies, and department stores throughout Europe, Asia, Africa, and Latin America scan EAN-13 at checkout.
- Online marketplaces. Platforms such as Amazon require a valid GTIN (EAN-13 or UPC-A) to list most branded products.
- Books and magazines. ISBN-13 is simply an EAN-13 beginning with 978 or 979; magazine barcodes use the 977 prefix.
- Warehousing and logistics. The same code that rings up at the till tracks the item through the entire supply chain.
To obtain legitimate, globally unique numbers for products you sell, license a GS1 company prefix from your national GS1 organization. Numbers from unofficial resellers may be recycled or duplicated — and many retailers now verify GTIN ownership before accepting a new product.
EAN-13 vs UPC-A: What’s the Difference?
| EAN-13 | UPC-A | |
|---|---|---|
| Digits | 13 | 12 |
| GTIN format | GTIN-13 | GTIN-12 |
| Primary region | Europe, Asia, rest of world | United States, Canada |
| Check digit | Yes (modulo-10) | Yes (modulo-10) |
The two are closer than they look: a UPC-A code is numerically identical to an EAN-13 with a leading zero. The UPC-A number 03600029145 and the EAN-13 number 003600029145 identify the same GTIN.
What this means in practice:
- Almost all modern scanners read both symbologies, so an EAN-13 scans without trouble on a US checkout.
- If you sell internationally, standardize on EAN-13 — it works everywhere, including North America.
- If you sell only in the US and Canada, UPC-A (using a GS1 US prefix from the 000–139 range) remains the traditional choice.
Our generator supports both formats — along with EAN-8, Code 128, Code 39, ITF-14, and QR codes in bulk — so you can produce whichever symbology your market requires.
7 Common EAN-13 Mistakes (and How to Avoid Them)
- Guessing the check digit. The 13th digit is a calculated value, not a free choice. Always let software compute it — a wrong check digit produces an unscannable code.
- Getting the digit count wrong. EAN-13 needs exactly 13 digits. Twelve digits is a UPC-A missing its leading zero; fourteen digits is simply invalid.
- Using numbers you don’t own. Random or reseller-bought GTINs can collide with another brand’s products or get your listings rejected. License your prefix from GS1.
- Reusing one GTIN across variants. Every size, color, and flavor needs its own number. Shared GTINs corrupt inventory data and confuse marketplaces.
- Printing too small or with poor contrast. Retail scanners expect a minimum width and sharp black-on-white contrast. Decorative colored barcodes may look attractive and scan never.
- Stretching the barcode or crowding the quiet zones. The blank margins on either side — the “quiet zones” — are part of the code. Scale proportionally and never crop them.
- Using the wrong symbology for retail. Code 39 and Code 128 are excellent for warehouses, but retail point-of-sale systems expect EAN-13 or UPC-A on consumer packaging.
How to Generate EAN-13 Barcodes in Bulk (Free)

When you need dozens or hundreds of EAN-13 labels — a new product line, a warehouse intake, price tags for a market stall — creating them one by one is not an option. Here is the fastest free workflow using our bulk EAN-13 generator:
Step 1 — Prepare your numbers. List your 13-digit EAN codes (each with a valid check digit — see the calculation method above), one per line, in a text file or spreadsheet column.
Step 2 — Enter them. Paste the list directly into the generator, import a CSV file, or use sequential-number autofill when your codes run in a series.
Step 3 — Generate. Click generate — up to 500 barcodes per batch, processed entirely in your browser. Nothing is uploaded to any server, so your product data stays private.
Step 4 — Download. Export as PNG or JPG for documents, SVG for print-quality vector artwork, PDF for label sheets, or grab everything at once as a ZIP archive.
Step 5 — Print. Use the built-in A4 and Letter label-sheet layouts, with grid or custom spacing, to produce retail-ready labels on any standard printer.
No signup, no watermark, no cost. Learn more about us, or reach out through our contact page if you need a hand.
Frequently Asked Questions
What does EAN-13 stand for?
EAN originally stood for “European Article Number.” The system is now maintained by GS1 as the International Article Number, but the EAN-13 name stuck.
How many digits are in an EAN-13 barcode?
Exactly 13: a 2–3 digit GS1 prefix, a company number, a product reference, and a final check digit calculated from the other twelve.
Can I create my own EAN-13 numbers for free?
You can format any 13 digits as an EAN-13 symbol, but for products sold at retail or on marketplaces you should license a GS1 company prefix so your numbers are globally unique and verifiable. For internal warehouse labeling, self-assigned numbers are fine as long as they never leave your operation.
What is the difference between EAN-13 and UPC-A?
EAN-13 has 13 digits and is the retail standard outside North America; UPC-A has 12 digits and dominates the US and Canada. A UPC-A code equals an EAN-13 with a leading zero, and most scanners read both.
Do I need GS1 membership to print EAN-13 barcodes?
Not to print the symbol itself — any barcode tool can draw it. You need GS1 membership to own legitimate, globally unique GTINs for products sold through retail channels.
How can I generate EAN-13 barcodes in bulk for free?
Use our bulk EAN-13 generator: paste up to 500 codes or import a CSV, generate everything in your browser, and download as PNG, SVG, PDF, or ZIP — no signup required.
Conclusion
EAN-13 looks like a humble strip of bars, but it carries a carefully engineered system: a GS1 prefix that traces the brand, a product reference you control, and a check digit standing guard against errors. Understand the structure, respect the math, and avoid the common mistakes — and you will never ship an unscannable label again.
Ready to put it into practice? Generate up to 500 EAN-13 barcodes in seconds with our free bulk barcode generator — no signup, no watermark, processed privately in your browser.
Try our free ean13 generator to create up to 500 EAN-13 barcodes from Excel or CSV in seconds.






One Comment