Ttooleras
📊

Barcode Generator

Generators

Generate barcodes in Code 128, Code 39, EAN-13, UPC-A, ITF-14, Codabar, and more formats with custom size and label options. Download as PNG or SVG for print, shipping, or inventory.. Free, private — all processing in your browser.

Advertisement

Barcodes run on a half-dozen different symbologies, each with its own rules about allowed characters, length, check digits, and density. Picking the right one and generating a scannable image used to require expensive desktop software or vendor-specific tools. This generator covers every commonly-used barcode symbology in the browser, lets you preview and tune the output, and downloads as PNG or SVG for print, label, or screen use.

Code 128 is the workhorse — dense, supports all 128 ASCII characters, and scans reliably. Use it for shipping labels, warehouse bins, and anywhere you need a flexible alphanumeric code. EAN-13 and UPC-A are the retail standards printed on every product in a supermarket. Code 39 is the older, sparser symbology still used in logistics and military applications. ITF-14 is for shipping cartons. Codabar is common in libraries and blood banks. Each has different input constraints, and the tool validates your input against the symbology before rendering.

Size, height, and label options are configurable. Setting the correct width (in bar module size or overall pixel width) and height matters for scanner reliability — too small and you get read failures, too large wastes label real estate. The tool shows a live preview, a recommended print DPI, and a downloadable SVG that scales cleanly to any size. For batch generation of similar barcodes, pair this tool with the bulk QR generator or an automated script using the same library under the hood.

Barcode Generator — key features

Every common symbology

Code 128, Code 39, EAN-13, EAN-8, UPC-A, UPC-E, ITF-14, Codabar, MSI, Pharmacode, and more.

Auto-validated input

Flags invalid characters or lengths for the chosen symbology before rendering.

Check-digit automation

Computes check digits for EAN, UPC, and ITF codes when you only know the payload.

PNG and SVG download

SVG for crisp print at any size, PNG for immediate use on screens.

Label text toggle

Show or hide the human-readable label underneath the barcode.

Size controls

Module width, height, quiet zone, and font size for the label are all adjustable.

Live preview

See changes instantly as you adjust settings to find a scannable size.

How to use the Barcode Generator

  1. 1

    Pick the symbology

    Choose based on your use case. Code 128 for general shipping and inventory; EAN/UPC for retail.

  2. 2

    Enter your data

    Type or paste the payload. The tool validates against the symbology's rules.

  3. 3

    Adjust size and label

    Set module width and height for the expected print size. Toggle human-readable label if useful.

  4. 4

    Preview and test scan

    Look at the preview. Scan with a phone or barcode scanner to confirm it reads correctly.

  5. 5

    Download

    Get SVG for print-quality scaling or PNG for screen use.

Common use cases for the Barcode Generator

Retail and e-commerce

  • :
  • :
  • :

Logistics and shipping

  • :
  • :
  • :

Inventory and asset tracking

  • :
  • :
  • :

Specialty

  • :
  • :
  • :

Barcode Generator — examples

Code 128

Shipping tracking number

Input
Code 128: 1Z999AA1
Output
dense barcode with checksum

EAN-13

Retail product

Input
EAN: 978012345678
Output
13-digit barcode with auto check digit

UPC-A

North American retail

Input
UPC: 01234567890
Output
12-digit barcode with check digit

Code 39

Asset tag

Input
Code 39: ASSET-42
Output
sparse barcode, readable directly

ITF-14

Shipping carton

Input
ITF-14: 12345678901231
Output
14-digit carton barcode

Technical details

Barcodes are an encoding of digits or alphanumeric text into patterns of vertical bars and spaces of varying widths. A scanner reads the widths and decodes them back to characters. Different symbologies handle different character sets and density tradeoffs.

Common symbologies covered here:
- Code 128: encodes full ASCII, uses three subsets (A, B, C) with auto-switching, includes a mandatory check digit. The densest general-purpose code.
- Code 39: encodes A-Z, 0-9, and a few specials. Less dense than 128 but visually recognizable and still widely used in defense and auto industries.
- EAN-13: 13 digits including country prefix, manufacturer code, product code, and check digit. The standard retail barcode outside the US.
- EAN-8: 8 digits, compact version for small products.
- UPC-A: 12 digits, the standard retail barcode in North America.
- UPC-E: 8 digits, compressed UPC-A for small products.
- ITF-14: 14 digits for shipping cartons in GS1 systems.
- Codabar: 0-9 plus a few specials; self-checking; used in libraries and medicine.
- MSI Plessey: numeric only, used in some inventory systems.
- Pharmacode: numeric only, used for pharmaceutical packaging verification.

This tool validates input per symbology, computes check digits automatically for EAN/UPC/ITF, and renders using the JsBarcode/bwip-js style library. Output is vector SVG (infinitely scalable for print) or PNG rasterized at a chosen DPI for immediate use. Always test scan with your actual scanner before mass-printing — scanner tolerance and label printer quality can interact in surprising ways.

Common problems and solutions

Wrong symbology for use case

UPC/EAN are reserved for registered GS1 members. Do not use them for internal inventory — use Code 128 or Code 39.

Too small to scan

Below about 0.5mm bar width, most scanners fail. Print-time scaling matters more than on-screen appearance.

Missing quiet zones

Bar code requires blank space (quiet zone) on either side. Cropping too tight can cause scan failures.

Printer resolution issues

Low-DPI thermal printers can blur barcode bars. Use SVG and print at the printer's native DPI.

Mobile camera vs laser scanner

Phone cameras handle 2D codes (QR) better than 1D. For phone scanning prefer QR.

Check digit mismatch

Pasting a barcode that already has a check digit as a plain string can cause the tool to add another. Read the settings carefully.

Barcode Generator — comparisons and alternatives

Dedicated barcode apps and desktop tools are powerful but expensive and overkill for simple labels. Online generators often cover only one or two symbologies or add watermarks. Command-line libraries like JsBarcode, bwip-js, and Python's python-barcode work well but require code. This tool gives you every popular symbology in a single browser interface, with validation, check-digit automation, size controls, and both SVG and PNG download. Perfect for occasional batches and anyone who needs a reliable scan-ready barcode without setup.

Frequently asked questions about the Barcode Generator

Can I use this for retail products?

Use UPC/EAN only if you have registered with GS1 and have a valid GTIN. Otherwise use Code 128 or 39 for internal use.

What size should I print a barcode?

Follow the symbology's minimum module width. EAN-13 is 0.33mm per module at 100% scale; print 80-200% depending on scanner distance.

Why use SVG instead of PNG?

SVG is vector — it scales without losing sharpness. Essential for print output at any size.

Can I generate barcodes for free?

Yes, this tool is free. Registering a UPC/EAN number with GS1 costs money; generating the barcode image does not.

Can I embed the barcode in a PDF?

Generate SVG and paste into your PDF tool, or generate PNG for fixed-size insertion.

Will barcodes scan on a phone?

Most 1D codes scan on modern phones with apps. For maximum phone compatibility prefer QR codes (2D).

What is the difference between UPC-A and EAN-13?

UPC-A is 12 digits (US/Canada); EAN-13 is 13 digits (international). EAN-13 includes the country prefix at the start.

Can I make my own GS1 codes?

No. GS1 prefix must be assigned by GS1 itself to ensure uniqueness. For test data in dev environments, use codes with the 200-299 prefix (reserved for internal use).

Additional resources

Advertisement

Related tools

All Generators

Explore more tools

200+ free tools that run in your browser.

Browse all tools →