Barcode Generator: Code 128, EAN-13, UPC and More

Type a value, pick the barcode type and download a clean barcode as PNG or SVG. Checks the input and tells you what a format accepts.

Loading tool…

How to use the Barcode Generator

  1. Choose the barcode type, for example Code 128 for general use or EAN-13 for retail.
  2. Enter the value. A message tells you if it is not valid for that type.
  3. Adjust bar width, height and colours, and choose whether to show the number.
  4. Download PNG or SVG.
  5. Optional: open Batch, enter one value per line and download all of them as a zip of SVG files.

About this tool

Different barcode types suit different jobs. Code 128 encodes any text and is the usual choice for inventory, shipping and asset labels. EAN-13 and UPC-A are the retail product codes. EAN-8 is for tiny packages. ITF-14 is used on cartons, Code 39 is common in older industrial and ID systems, and Codabar appears in libraries and blood banks.

For the retail formats, the last digit is a check digit calculated from the others. You can enter the number without it and the tool adds it, which is why EAN-13 takes 12 digits. Generating a valid-looking code is not the same as owning it: to sell products in shops you need numbers allocated by GS1 India (or your local GS1 body), otherwise the code can clash with someone else's product. In India, GS1 India allocates company prefixes; a code made with this tool is suitable for testing, internal tracking and labels, not for selling through retail.

For reliable scanning, keep high contrast, leave a quiet zone on each side, and print at a size where the thinnest bar is at least about 0.25 mm. Use SVG for print because it scales without blurring, and always test a printed sample with a scanner.

Frequently asked questions

Which barcode type should I use?

Code 128 for internal labels, inventory and shipping. EAN-13 or UPC-A only for retail products with registered GS1 numbers.

Why does my EAN-13 code show an error?

EAN-13 needs 12 digits (the check digit is added) or 13 digits with a correct check digit, with no letters or spaces.

Can I use these barcodes in shops?

Only if the number is registered to you through GS1. The tool creates the picture, it does not register numbers.

PNG or SVG for printing?

SVG, since it stays sharp at any size. The PNG is generated at three times the preview resolution for documents and screens.

Can I make many barcodes at once?

Yes. Open the Batch section, enter one value per line (up to 200) and download a zip of SVG files in the type and style you chose. Values that are invalid for that type are skipped and listed.

Need a custom tool or website?

IDM Valley builds web apps, calculators, AI chatbots and automation for businesses. Fixed prices, code in your name.

Get a free quote

Have a project in mind?

Tell us what you need: a website, landing page, AI chatbot or automation. You get a clear scope and a fixed price within one working day. Free, no obligation.


  • avshack
  • DivineBamboo
  • goldleaf
  • janapril
  • kaizen
  • kwc
  • modv
  • pixelrush
  • revital
  • riderzplanet
  • sandsfashions
  • avshack
  • DivineBamboo
  • goldleaf
  • janapril
  • kaizen
  • kwc
  • modv
  • pixelrush
  • revital
  • riderzplanet
  • sandsfashions