Code 128 Barcode Generator

Type any letters and numbers. Print labels for shelves, bins and parts.

Best For
Shelves, bins, parts and parcels
You Type
Anything on a keyboard
Usual Size
0.72 x 2.14 in

The Generator

Type Your Text

Letters, numbers and signs, up to 80.

Print or Download

Code 128 barcode reading SHELF A-12SHELF A-12
When Scanned, This Types
SHELF A-12
Label Size
0.72 x 2.14 in (18.3 x 54.5 mm)

30 Labels, as Avery 5160

Type your text first.

Size and Details

What Code 128 Holds

Code 128 holds every character on a US keyboard: capital and small letters, digits, punctuation and spaces.

Each character is three bars and three spaces. Each of those is 1 to 4 times as wide as the thinnest bar.

Two digits can share one character, so a long number takes about half the space. The generator does that wherever it makes the barcode shorter.

Every barcode ends with a check character that the scanner tests and does not report.

Sizes That Scan

SizeBar WidthBar HeightWhole Label
Smallest0.191 mm15.00 mm0.66 x 1.24 in (16.9 x 31.5 mm)
Usual0.330 mm15.00 mm0.72 x 2.14 in (18.3 x 54.5 mm)
Largest1.016 mm15.00 mm0.83 x 6.6 in (21.1 x 167.6 mm)
  • SHELF A-12 with its quiet zones, the blank ends, and its text line.
  • A character is as wide as 11 thin bars, and the last mark is 13.
  • Bars and spaces are 1 to 4 times as wide as the thinnest.

The Last Digit

This check digit follows your code.

Code 128 barcode reading SHELF A-12StartSHELF A-12CheckStopSHELF A-12
The Bars, Enlarged

Code 128 SHELF A-12

How This Sum Works

Check digit sum for SHELF A-12
CharacterValueWeightProduct
Start B1041104
S51151
H40280
E373111
L444176
F385190
space060
A337231
-138104
1179153
21810180

The products add up to 1380. Divided by 103, that leaves 41, which stands for 41

Common Mistakes

Putting Too Much on One Label
80 characters at 0.33 mm is about 294 mm wide. Encode a short ID and keep the detail in your list.
Adding Your Own Check Digit
The barcode already has one. Type only your text.
Filling the Margins
Leave a blank margin on each side, as wide as 10 thin bars.

Frequently Asked Questions

What Is Code 128 Used For?

Shelf and bin labels, parcels, parts and assets: any place that needs letters as well as digits.

Does Code 128 Support Small Letters?

Yes. It holds capital and small letters, digits and punctuation.

Is GS1-128 the Same as Code 128?

GS1-128 uses Code 128 bars with a marker at the start and agreed identifiers for each field, such as a batch or a date.

How Long Can a Code 128 Be?

The barcode itself has no limit. This generator takes 80 characters, which is already wider than a page at the usual bar width.