Bulk Barcodes from Excel or CSV: The Pre-Print Checklist That Stops Reprints
Generating one barcode is easy. Generating four thousand of them from a spreadsheet, printing them on label sheets, and having every single one scan at the checkout or the warehouse gate is a different job — and almost every failure we see traces back to the data file or the print settings, not the barcode itself. This is the checklist we use before a bulk run.
Key points
- Excel is the most common source of broken barcodes: it drops leading zeros and turns 13-digit numbers into
6.9E+12. Store codes as text before you export. - Pick the symbology by what the reader expects — EAN-13/UPC-A for retail items, ITF-14 for cases, Code 128 (or GS1-128) for logistics and internal use, Code 39 only where legacy systems require it.
- Check digits are computed, not typed. A GTIN with a wrong check digit will not scan; let the generator calculate it and validate what you already have.
- Print at 100 % scale, never "fit to page", and keep the quiet zones — a 10 × X-dimension margin on Code 128, 11 X left and 7 X right on EAN-13.
- Grade a sample from the start, middle and end of the run. A code that reads on your phone can still fail a fixed-mount scanner.
1. Fix the data before you touch the generator
Bulk generation is a data job first. These are the spreadsheet problems that produce unreadable or wrong codes, in the order we meet them:
| Symptom in the file | What happened | Fix |
|---|---|---|
6.9E+12 instead of a 13-digit number | Excel treated the GTIN as a number and switched to scientific notation | Format the column as Text before pasting, or export with =TEXT(A2,"0000000000000") |
| Codes that should start with 0 are one digit short | Leading zeros dropped on import | Same fix; UPC-A and many internal codes start with 0 |
| Some rows scan to a different value than displayed | Trailing spaces or non-breaking spaces copied from a web page or ERP export | Trim every cell; check for U+00A0 |
| Two products share a barcode | Duplicate rows, or a GTIN reused after a product change | De-duplicate on the code column, not the description |
| Generator rejects a batch of rows | Wrong length or invalid characters for the symbology (letters in an EAN, lowercase in Code 39) | Validate length and character set per symbology before export |
Characters render as é or ?? | CSV saved in a legacy encoding | Save as CSV UTF-8; a BOM is fine for our tool |
Export a clean CSV or TXT with one code per line — optionally a second column for text above the bar and a third for text below. Keep a copy of the exact file you generated from; if a code is questioned later, that file is your audit trail.
2. Choose the symbology by where it will be scanned
| Symbology | Encodes | Check digit | Use it for | Avoid it for |
|---|---|---|---|---|
| EAN-13 / UPC-A | 12 + 1 digits (GTIN-13) / 11 + 1 (GTIN-12) | Mod-10, mandatory | Retail items scanned at point of sale | Anything without a GS1-allocated GTIN |
| ITF-14 | 13 + 1 digits (GTIN-14) | Mod-10, mandatory | Shipping cases and trade units; prints well on corrugated | Retail POS — most checkout scanners are not set up for it |
| Code 128 | Full ASCII; subset C packs digit pairs | Mod-103, built in | Serials, lot numbers, internal asset tags, logistics; densest 1D option | Nothing in particular — it is the default for non-retail |
| GS1-128 | Code 128 with FNC1 + Application Identifiers | Mod-103 + AI-level checks | Pallet labels, SSCC, expiry/lot data for trading partners | Plain internal codes where AIs add nothing |
| Code 39 | Uppercase A–Z, 0–9, a few symbols | Optional mod-43 | Legacy systems that mandate it | New projects — it is about twice as wide as Code 128 for the same data |
Two rules that save reprints. First, do not invent GTINs: an EAN-13 that was not allocated from a GS1 company prefix will collide with someone else's product at retail. Second, if your data contains only digits and you have a free choice, Code 128 subset C gives the shortest symbol — the generator picks subsets automatically, but an all-numeric input lets it do its best work.
3. Check digits: compute, don't type
EAN-13, UPC-A and ITF-14 all end in a mod-10 check digit computed from the preceding digits with alternating weights of 1 and 3. Scanners use it to reject misreads; a symbol whose check digit does not match its data will simply not decode. Two practical consequences:
- If your spreadsheet holds 12-digit GTIN bodies, let the generator append the check digit. If it holds 13 digits, ask it to validate them instead — a surprising share of "13-digit" columns in the wild contain typos in the last position.
- Never pad a 12-digit code to 13 with a zero to make the length fit. The result is a valid-looking number with a wrong check digit, and it will fail at the till.
Code 128's check character is internal to the symbol and is always generated — you do not see it in the human-readable text, and you should not try to include one in your data.
4. Size, quiet zones and print settings
The X-dimension is the width of the narrowest bar. Everything else scales from it, and the printing process sets the floor:
- Thermal transfer at 203 dpi — one dot is 0.125 mm; practical minimum X is about 0.25 mm (2 dots) so bars land on whole dots. At 300 dpi, 0.17 mm is achievable but 0.25 mm is safer for retail.
- EAN-13 at retail — nominal (100 %) X is 0.330 mm, giving a symbol about 37.3 × 25.9 mm including quiet zones. GS1 permits 80 %–200 % magnification for point-of-sale; below 80 % expect problems at older lanes.
- Quiet zones — the blank margins are part of the symbol. EAN-13 needs 11 X on the left and 7 X on the right; Code 128 and ITF-14 need at least 10 X on both sides. Artwork borders and label edges eat them first.
- Bar height — truncating an EAN-13 below about 60 % of nominal height makes omnidirectional scanning unreliable. On Code 128 keep at least 15 % of the symbol width or 6.35 mm, whichever is larger.
The single most common print mistake: the PDF is correct, the printer dialog is set to "fit to page" or "shrink to printable area", and every barcode on the sheet comes out 4 % smaller with bars that no longer align to printer dots. Print at 100 % / actual size, and measure one label with a ruler before running the batch.
5. Laying out label sheets
For sheet labels the generator needs the physical grid, not just the barcode:
- Sheet size and grid — A4 65-up (38.1 × 21.2 mm), A4 24-up (70 × 37 mm), US Letter 30-up (2⅝ × 1 in) are the common stock sizes. Match the exact product code of the sheets you bought; two "24-up" layouts from different brands often differ by a millimetre in gap.
- Margins — most desktop printers cannot print within 3–5 mm of the edge; sheet layouts already account for this, so do not add your own page margin on top.
- One code per label, centred, with the human-readable text below — leave room for it; regulators and receiving departments want to read the number when the scanner cannot.
- Test on plain paper first, hold it over a real label sheet against a window, and check registration before feeding the expensive sheets.
For roll labels on a thermal printer, skip the sheet step: export a ZIP of individual PNGs or SVGs and let the label software drive the printer, or send the CSV straight to the printer's own batch template.
6. Verify before you ship
- Print three samples — first, middle and last row of the batch.
- Scan them with the reader the codes will actually meet: a retail imager, a warehouse gun, a fixed-mount tunnel scanner. A phone camera is far more forgiving and proves little.
- For retail or trading-partner use, grade with a verifier against ISO/IEC 15416. GS1 asks for at least grade 1.5 (C) for most applications; anything lower will be rejected somewhere downstream.
- Confirm the decoded value equals the spreadsheet value — including any leading zeros — for at least a random ten rows.
The batch barcode generator takes a CSV or TXT with one code per line (plus optional text above and below), generates EAN-13, UPC-A, Code 128, ITF-14 or Code 39 with check digits computed or validated, and exports a ZIP of PNG/SVG files or an A4 / Letter sheet PDF. For single codes and detailed symbology settings use the barcode generator; for GTIN check digits on their own, GS1's own check-digit calculator.
Generate the whole batch in one go
Upload a CSV, pick the symbology and sheet layout, and download print-ready PDF or a ZIP of vector files — check digits handled for you. Open the batch generator →
References
This article is based on the following primary sources; always check the edition in force before printing.
- GS1 — General Specifications (symbol dimensions, quiet zones, magnification ranges, check digit calculation)
- GS1 — Check digit calculator and algorithm
- GS1 — Barcode types: EAN/UPC, ITF-14, GS1-128
- ISO/IEC 15416 — Bar code print quality test specification, linear symbols
- ISO/IEC 15420 — EAN/UPC bar code symbology specification
- ISO/IEC 15417 — Code 128 bar code symbology specification
Frequently asked questions
Why do my barcodes from Excel come out wrong or one digit short?
Excel stores a 13-digit GTIN as a number, drops leading zeros and, above 11 digits, displays it in scientific notation such as 6.9E+12. Format the column as Text before you paste the codes, or export with a TEXT() formula that pads to the required length, then save as CSV UTF-8.
Which barcode type should I use for bulk product labels?
EAN-13 or UPC-A for items scanned at retail checkout — using GTINs allocated from a GS1 company prefix. ITF-14 for shipping cases. Code 128 for serials, lot numbers, internal assets and most logistics labels; GS1-128 when trading partners need Application Identifiers such as lot and expiry. Code 39 only when a legacy system requires it.
Do I have to calculate check digits myself?
No. EAN-13, UPC-A and ITF-14 use a mod-10 check digit that the generator computes from your 12 or 13 digits; if your file already contains 13-digit codes, validate them rather than regenerate. Code 128's check character is built into the symbol and is never part of your data.
What size should a bulk-printed barcode be?
Choose the X-dimension for the printer: about 0.25 mm on 203 dpi thermal transfer, and 0.33 mm (100 % magnification) for EAN-13 at retail, where GS1 allows 80 %–200 %. Keep the quiet zones — 11 X left and 7 X right on EAN-13, 10 X each side on Code 128 and ITF-14 — and print at 100 % scale, never "fit to page".
How do I check a whole batch scans correctly?
Print samples from the first, middle and last rows, scan them with the reader they will actually meet rather than a phone, and for retail or trading-partner use grade them with a verifier against ISO/IEC 15416 to at least grade 1.5 (C). Compare the decoded values, including leading zeros, against the source spreadsheet for a random sample of rows.
Can I print the batch on roll labels instead of sheets?
Yes. Export a ZIP of individual PNG or SVG files and let your label software drive the thermal printer, or feed the same CSV into the printer's own batch template. Sheet PDFs are for desktop laser and inkjet printers with pre-die-cut label stock.