open-qr-code

Code 128 barcodes, explained

The workhorse barcode behind shipping labels, inventory tags, and tickets. Here is what it stores, why it is reliable, and when to reach for it instead of a QR code.

Code 128 is a one-dimensional (linear) barcode: a single row of bars and spaces read left to right by a laser or camera scanner. It earned its name because it can encode all 128 ASCII characters. That makes it far more flexible than older numeric-only symbologies, while staying compact and dependable.

What it can store

It does not store links, images, or long paragraphs. For a website, contact card, or Wi-Fi details, use a QR code instead.

Why it is reliable

Every Code 128 barcode carries a hidden check digit, a value calculated from the other characters. The scanner recomputes it and refuses the read if it does not match, which prevents a smudge or a misread from returning the wrong data. The symbology also uses three code sets (A, B, and C) that a good encoder switches between automatically to keep the bars as short as possible.

Code 128 vs QR code

 Code 128QR code
ShapeOne row of barsSquare grid
Best forShort IDs, SKUs, tracking numbersLinks, text, contacts, Wi-Fi
CapacitySmall, a short stringLarge, thousands of characters
Scan angleRoughly aligned, left to rightAny orientation
Reads withLaser scanners and camerasPhone cameras

Where you will see it

How to make one that scans

  1. Open the generator and switch to barcode mode.
  2. Type the value: a SKU, an order number, or any short ASCII string. The tool warns you if a character cannot be encoded.
  3. Keep it short. Long strings make a wide barcode that is harder to scan.
  4. Download and print with dark bars on a light background, and leave clear space (a quiet zone) at both ends.

Common mistakes

Generate a Code 128 barcode now, or read the FAQ for more.