tooloora

Barcode Generator — EAN-13, UPC, Code 128 and ITF-14

Enter a number or text and pick the barcode type: the generator calculates the check digit, keeps the standard quiet zones and exports SVG in millimetres or PNG at print resolution. Everything runs in your browser.

Runs locally — nothing is uploaded

Barcode type

Retail outside North America: the 13-digit number on almost every pack (GTIN-13).

12 digits – the generator works out the check digit. With 13 digits it verifies it. Spaces and hyphens are fine.

Your barcode appears here.

Enter a number or some text – or load an example.

The SVG stays sharp at any size and carries its dimensions in millimetres, which suits print artwork. The PNG carries the chosen resolution so label and office software print it at the right size.

Size

GS1 allows 80 to 200% for retail barcodes; 100% equals a module width of 0.330 mm.

mm

Nominal height at this magnification: 22.85 mm

Options

Colours

Black on white is the safest choice. The warnings are estimates from the screen colour; only a test scan shows how well the printed barcode reads.

The generator draws the barcode for a number; it does not assign numbers. A retail EAN/GTIN comes with a membership of your national GS1 organisation.

Preview and colour warnings do not replace a test scan: print a sample before a run and read it with the scanner that will be used.

Everything runs in your browser and nothing is uploaded. Your last input and settings are kept in your device’s local storage.

What this barcode generator does

Enter a number or some text and pick the barcode type: the generator creates EAN-13, EAN-8, UPC-A, ISBN, Code 128, Code 39 and ITF-14 barcodes right in your browser. If the check digit is missing, it calculates it; if it is wrong, it tells you the correct one. Quiet zones follow the standards, and you download the result as an SVG in millimetres or as a PNG at print resolution.

Which barcode type do I need?

That depends on where the code will be scanned:

UseBarcodeContent
Retail productsEAN-1313 digits (GTIN-13)
Very small packsEAN-88 digits
Retail in the USA and CanadaUPC-A12 digits
BooksISBN as EAN-13978 or 979 plus 10 digits
Outer cartons and palletsITF-1414 digits (GTIN-14)
Warehouse, shipping, internal labelsCode 128letters, digits, punctuation
Older warehouse and industrial systemsCode 39A–Z, 0–9 and seven symbols

For the same content, Code 128 is usually much narrower than Code 39. Choose Code 39 only when an existing system requires it.

Do I get an EAN number here?

No. The generator draws the barcode for a number you already have. Retail numbers are issued by GS1: you join your national GS1 organisation (GS1 UK, GS1 US and so on), receive a company prefix and number your products from it. A number you invent may already belong to someone else’s product. ISBNs come from your national ISBN agency rather than GS1 — Nielsen in the UK and Ireland, Bowker in the US. For internal labels such as shelf locations, assets or work orders you need no registration; use Code 128.

How is the check digit calculated?

EAN-13, EAN-8, UPC-A and ITF-14 use the modulo 10 method from the GS1 General Specifications: weight the digits from right to left alternately by 3 and 1, add them up, and the check digit fills the sum to the next multiple of ten. For 400638133393:

3 × 3 + 9 + 3 × 3 + 3 + 3 × 3 + 1 + 8 × 3 + 3 + 6 × 3 + 0 + 0 × 3 + 4 = 89

One more makes 90, so the complete number is 4006381333931. If you type the check digit yourself, the generator verifies it. When it does not match, you are told the correct digit instead of having it silently replaced — a mismatch usually means two digits were swapped somewhere. Code 128 always carries its own check character (modulo 103), which the generator adds and which is not printed in the text line. For Code 39 you can switch on the optional modulo 43 check character.

How large does an EAN barcode have to be?

The GS1 General Specifications define the nominal size (100%) through the module width, the width of the narrowest bar: 0.330 mm. An EAN-13 is then 37.29 mm wide including its quiet zones, with bars 22.85 mm high. Retail barcodes scanned at the checkout may range from 80% to 200%:

MagnificationModule widthEAN-13 widthBar height
80%0.264 mm29.83 mm18.28 mm
100%0.330 mm37.29 mm22.85 mm
150%0.495 mm55.94 mm34.28 mm
200%0.660 mm74.58 mm45.70 mm

The quiet zones matter at least as much: 11 modules on the left and 7 on the right for EAN-13, 9 on each side for UPC-A, 7 for EAN-8, and at least 10 modules for Code 128 (ISO/IEC 15417), Code 39 (ISO/IEC 16388) and ITF-14. Nothing may be printed there, not even a border or text. Shortening the bars saves space but costs readability: the checkout scanner then only reads the code from a few angles.

How to create a barcode

  1. Pick the barcode type. The line below it tells you what it is meant for.
  2. Enter the number or text. For EAN, UPC and ITF-14 you can leave out the check digit.
  3. Set the size: through the GS1 magnification for EAN, UPC and ISBN, through the module width in millimetres for the others, plus the bar height.
  4. Check the colours. The generator warns about swapped colours, low contrast and red bars.
  5. Download: SVG for print artwork, PNG at 203 or 300 dpi for label printers.

Why does Code 128 switch code sets?

Code 128 has three code sets: A for upper-case letters and control characters, B for upper- and lower-case letters, C for pairs of digits. In set C, two digits take up a single 11-module symbol character. The generator works out the shortest possible sequence instead of following a rule of thumb and shows below the preview which sets it chose. “AB1234” therefore needs five data characters instead of six: A and B in set B, one switch character, then 12 and 34 in set C.

Characters outside ASCII, such as accented letters, are not encoded. Code 128 could only represent them through the FNC4 function character, which this tool does not support. GS1-128 with application identifiers (FNC1) is not built in either.

What should I watch out for when printing?

  • Dark bars on a light background. Black on white is the safest choice. Many scanners use red light, under which red, orange and yellow bars disappear.
  • Keep the quiet zones clear, including when the barcode later sits next to text or a frame.
  • Do not stretch it freely. The SVG carries millimetres and the PNG its resolution. Scaling the barcode by hand in another program changes the module width.
  • Scan a sample before a print run. Print quality is measured with a verifier according to ISO/IEC 15416; a screen preview and colour warning cannot replace that measurement.

Privacy

Encoding, preview and export run entirely in your browser, and nothing is uploaded. Your last input and settings are kept in your device’s local storage so the tool reopens where you left off.

Frequently asked questions

Does this generator give me a valid EAN for my products?

No. It draws the barcode for a number you already have. GTINs for retail (EAN-13, UPC-A, ITF-14) are issued by GS1: you join your national GS1 organisation, get a company prefix and number your products from it. A number you make up may already belong to someone else’s product. For purely internal labels such as shelf locations or asset tags you do not need GS1 – use Code 128 there.

Which barcode type do I need?

Retail products: EAN-13 (UPC-A in the USA and Canada, EAN-8 for very small packs). Books: the ISBN as an EAN-13 starting with 978 or 979. Outer cartons and pallets: ITF-14 with the 14-digit GTIN of the case. Warehouse, shipping and internal labels with letters: Code 128, which is more compact than Code 39. Use Code 39 only when an existing system asks for it.

How is the EAN check digit calculated?

With the GS1 modulo 10 method: weight the digits from right to left alternately by 3 and 1, add them up and fill the sum to the next multiple of ten. For 400638133393 the weighted sum is 89, so the check digit is 1 and the complete number is 4006381333931. EAN-8, UPC-A and ITF-14 use the same rule. If you type a check digit that does not match, the generator tells you which one would be correct instead of silently changing it.

How large does an EAN-13 barcode have to be?

The GS1 General Specifications define 100% as a module width of 0.330 mm, which makes an EAN-13 37.29 mm wide including its quiet zones, with bars 22.85 mm high. Retail barcodes may be scaled from 80% to 200% (0.264 to 0.660 mm). Keep the quiet zones of 11 modules on the left and 7 on the right free of print, and avoid cutting the bars shorter than the nominal height.

SVG or PNG – which file should I use for printing?

SVG for print artwork and design software: it is vector-based, stays sharp at any size and carries its dimensions in millimetres. PNG for label printers and office software: choose the printer’s resolution (203 or 300 dpi are common for label printers). The generator gives every module a whole number of pixels and writes the resolution into the file, so the image prints at the intended size.

Is anything I enter uploaded?

No. Encoding, preview and export all run in your browser; there is no server involved. Your last input and settings are kept in your device’s local storage so the tool opens where you left off – clearing your browser data removes them.