Barcode generator

Generate an EAN-13, UPC-A, Code 128 or Code 39 barcode and download it as SVG or PNG. Free, no account, no watermark. The tool also tells you the smallest size we found each format still scans at, measured on a home laser printer, not copied from a spec sheet.

SVG stays sharp at any size and is what you want for printing. PNG is easier to drop into a spreadsheet or listing.

Everything runs in your browser. Nothing you type is sent anywhere.

How small can you print a barcode before it stops scanning?

On a consumer laser printer, a bar narrower than about 0.165 mm stops scanning reliably. EAN-13 and UPC-A held down to 50% magnification (X = 0.165 mm); Code 128 and Code 39 became unreliable one step earlier, at 65% (X = 0.214 mm). Below 0.132 mm nothing scanned at all.

Smallest size that scanned first try · X-dimension shown

EAN-13
50% · X=0.165mm
15.7 mm wide
UPC-A
50% · X=0.165mm
15.7 mm wide
Code 128
65% · X=0.214mm
24.0 mm wide
Code 39
65% · X=0.214mm
30.7 mm wide

Brother HL-L2375DW mono laser · Plain A4 copier paper · Standard quality · Pixel 9 Pro XL rear camera · Bright indoor light · 2026-08-02

Is a barcode you generate here valid for retail?

Not on its own. This tool encodes whatever number you give it into a valid barcode symbol. It does not register that number to you, and an unregistered number is not a GTIN.

Watch out for silent print scaling

Most print dialogs shrink pages by around 4% without telling you. Printers cannot print to the very edge of the paper, so drivers quietly scale the page down to fit inside the hardware margin. On the printer used for this test, a line specified at 100 mm came out at 96 mm, and there was no scale control anywhere in the mobile print dialog to turn it off.

Four percent sounds harmless. On a barcode already near its limit it is the difference between scanning and not. Before you trust any printed barcode dimension, print a line of known length and measure it. On desktop, choose Actual size or 100% rather than Fit to page.

Explore more

Which format? See the barcode types guide or the barcode chart. Each format also has its own pre-selected generator: EAN-13, UPC-A, Code 128, Code 39, or check a number with the UPC finder. Trying to identify a product from its code instead? See barcode lookup. Looking for ITF-14, SSCC, or a 2D barcode? Those pages cover what we do and don’t support. Need many at once? Try the bulk generator or bulk from a spreadsheet.

Selling on a marketplace? Check whether you need a GS1 number first. Platform notes for Shopify, Amazon, Amazon FNSKU, Walmart, USPS, and internal LPN tracking.

Printing and labels: print settings that matter, generating UPC labels, label sizes, garments, transparent labels, label examples, or why FedEx rejects a label.

A barcode generated on this page is not a registered GTIN. It encodes whatever number you enter into a valid, scannable symbol. It does not register that number to you. Selling through a retailer or listing on a marketplace under most categories requires a number issued to your business by GS1. See do you need a GS1 number before you print at scale.

Written by Robert Wells · Published 2026-08-02