Code 128 barcode generator
The workhorse for anything that isn’t retail: SKUs, bin locations, serial numbers, shipping labels. Encodes all printable ASCII and packs digits densely.
Any printable ASCII. The default for shipping labels, inventory and asset tags.
Rendering…
SVG stays sharp at any size and is best for print. Keep the white margin either side of 1D barcodes (the quiet zone, at least 10× the narrowest bar); cropping it is the most common reason a printed barcode will not scan.
Why Code 128
Code 128 switches automatically between three character sets, so a long run of digits takes half the width it would in Code 39. It has a mandatory mod-103 check character built in (bwip-js adds it for you, it isn't printed). It needs no registration, so it's the right choice for internal stock, library-style tags and warehouse labels.
If your label carries GS1 data such as a GTIN, batch or expiry date for a trading partner, use GS1-128 instead: the same symbology with FNC1 and Application Identifiers.
Questions
Does Code 128 need a check digit?
It has one built in (modulo 103), calculated automatically and not shown in the human-readable text.
Can phones scan Code 128?
Yes. Our scanner and most scanning apps read it, as do all standard USB and Bluetooth barcode scanners.