Skip to content
QR and barcode guides

How to use a barcode generator: CODE128, EAN and UPC

Published 3 min read

Barcodes label products, boxes, files and tickets. With Convertada's barcode generator you can create six common types in your browser: you pick the type, enter a value and download the image. This guide explains which type to choose and what each one accepts.

Barcode types and what they accept

| Type | What you can enter | | --- | --- | | CODE128 | Any ASCII text | | CODE39 | Letters, digits and - . $ / + % and space | | EAN-13 | 12 digits (the check digit is added) or 13 digits | | EAN-8 | 7 digits (the check digit is added) or 8 digits | | UPC-A | 11 digits (the check digit is added) or 12 digits | | ITF-14 | 13 digits (the check digit is added) or 14 digits |

Which type should I use?

  • CODE128 is a flexible choice for internal labels, asset tags, order numbers and file references, because it takes letters and digits.
  • CODE39 is an older type for letters, digits and a few symbols. Use it when a system or standard specifically asks for it.
  • EAN-13 and EAN-8 are the numbers on retail products in many countries. An EAN is not something you can simply invent: retail products normally use numbers issued through the official numbering system, so check with your retailer or the numbering organisation in your country.
  • UPC-A is the 12-digit retail code used mainly in North America, with the same rule about official numbers.
  • ITF-14 is used for cartons and shipping cases of products.

If you only need to label things inside your own business, CODE128 is usually the simplest.

Step-by-step: create a barcode

  1. Open the barcode generator.
  2. Select the Barcode format.
  3. Enter the Value. The hint under the field shows what the chosen type accepts.
  4. For EAN, UPC and ITF-14 you can enter one digit fewer than the full length and the tool adds the check digit. If you enter the full length, the check digit must be correct, or you see "The check digit is wrong".
  5. Adjust the Bar width (1 to 4 px) and Height (30 to 240 px).
  6. Change the bar colour and background if needed, and decide whether to show the value below the barcode.
  7. Download the barcode as a PNG or an SVG.

Tips for barcodes that scan

  • Keep high contrast. Dark bars on a white background are the safest choice.
  • Leave blank space on both sides of the barcode. Do not crop tightly.
  • Do not stretch the image. Resize it proportionally.
  • Use SVG for print, so the bars stay sharp at any size.
  • Test with the scanner you will really use, not only with a phone camera.

Common problems and how to fix them

"Wrong length: N digits expected." Count the digits. EAN-13 needs 12 or 13, UPC-A 11 or 12, and so on.

"Digits only." EAN, UPC and ITF-14 take numbers only.

"CODE39 supports letters, digits, space and - . $ / + %." Remove other symbols, or use CODE128.

"Only ASCII characters are supported." CODE128 here accepts ASCII text. Accented letters and other scripts are not supported.

Frequently asked questions

Is the barcode generator free?

Yes, and it needs no account.

Are my values uploaded?

No. The barcode is drawn in your browser.

Can I make a QR code here too?

That is a separate tool. See the QR code generator guide.

Can I use these for products in shops?

The images are technically valid, but retailers usually require official product numbers. Ask your retailer before you print them.

Conclusion

Pick the type that matches where the barcode will be used, enter a valid value and download it as SVG or PNG. For codes that open links and pages, use a QR code instead.