Barcode Generator

Generate barcodes online for free — Code 128, EAN-13, EAN-8, UPC-A, Code 39, ITF-14, Codabar, MSI and Pharmacode, with check-digit validation, adjustable size and colours, and PNG or vector SVG downloads for print.

100% private — everything runs in your browser. Conversion happens on your device; nothing is uploaded.

100% private — runs in your browser

Check digits are validated for EAN, UPC and ITF codes. Keep strong contrast (dark bars on a light background) and the quiet zone so scanners can read it; SVG stays sharp at any print size. To sell products in stores you need officially registered numbers from GS1.

How to make a barcode

  1. Type the value to encode.
  2. Choose the barcode type.
  3. Adjust bar width, height, text and quiet zone.
  4. Download a PNG, or an SVG for print.

What you can use it for

  • Label products, stock and shelves
  • Print barcodes for packaging and retail
  • Create asset tags and library labels
  • Add barcodes to tickets, invoices and shipping labels

More free tools

Building for the web?

Format, minify, convert and generate code with our free, private developer tools.

See all free tools →

Frequently asked questions

Which barcode type should I use?

Code 128 encodes any text and suits internal labels and shipping. Retail products use EAN-13 (most of the world) or UPC-A (US and Canada). ITF-14 is for outer cartons.

Do I need to register barcode numbers?

For products sold in shops, yes — EAN and UPC numbers must come from GS1 so they're unique worldwide. For internal use (stock, assets, tickets), you can use any value.

Why does it say my EAN-13 is invalid?

The last digit is a check digit calculated from the others. Enter the first 12 digits and the check digit is added automatically, or correct the 13th digit.

PNG or SVG?

SVG is vector, so it stays perfectly sharp at any print size — best for packaging. PNG is easiest for documents and the web (downloaded at 3× for crisp printing).

Is it free for commercial use?

Yes. The barcodes you make are yours to use anywhere.

Does it add the check digit for me?

Yes, for the retail and carton types. Type 12 digits for EAN-13, 7 for EAN-8, 11 for UPC-A or 13 for ITF-14, and the last digit is calculated and added to the barcode for you. If you type the full length instead, your final digit is checked. When it doesn't match, the preview fades, a message explains what's needed, and nothing downloads until it's fixed.

Which characters can Code 128 encode?

Code 128 encodes the standard ASCII character set: upper- and lowercase letters A to Z, digits 0 to 9, spaces and keyboard punctuation such as hyphens, full stops, slashes and the # and @ signs. That suits SKUs, order numbers and asset tags that mix letters and numbers. Stick to these characters, because letters with accents, other alphabets and emoji are not part of the ASCII set.

Which characters do Code 39, Codabar, MSI and Pharmacode accept?

Code 39 takes capital letters A to Z, digits, spaces and the symbols – . $ / + %, and any lowercase letters you type are turned into capitals. Codabar takes digits and – $ : . + /, between a start and stop letter from A to D; leave the letters off and A is added at both ends. MSI takes digits only. Pharmacode takes one whole number from 3 to 131070.

Why did my value change when I switched barcode type?

Choosing a new barcode type fills the Value box with a working sample for that type, such as 5901234123457 for EAN-13 or MGD 2026 for Code 39, so the preview always shows a valid example. Whatever you typed before is replaced. To keep your own value, choose the barcode type first, then type or paste the value, and the preview updates as you type.

What size settings can I change?

Three sliders set the size. Bar width sets the narrowest bar from 1 to 4 pixels in half steps, starting at 2. Height runs from 30 to 200 pixels, starting at 90, and Text size from 10 to 36, starting at 18. The preview's pixel size is shown under it. The PNG download is drawn at three times these settings, while the SVG stays vector.

Can I change the colours, quiet zone or hide the number?

Yes. Use the Bars and Background colour pickers, which start at black on white; the background colour fills the whole image in both PNG and SVG. Quiet zone adds blank space on all four sides, from 0 to 40 pixels, starting at 12. Untick Show the number to download the bars without the digits underneath.

Why won't my barcode download?

Download PNG and Download SVG only work while the value is valid for the chosen barcode type. When it isn't, the preview fades and a message underneath explains the problem, for example “UPC-A needs 11 or 12 digits.” Correct the value and the buttons work again. Files are saved straight from your browser and named after the type, such as barcode-EAN13.png.