Published Oct 27, 2026
# Code 39 Barcode: The Industrial Workhorse That Refused to Die
Code 39 is a variable-length one-dimensional barcode developed in 1974 that encodes 43 characters: uppercase A-Z, digits 0-9, a space, and the six punctuation marks dash, period, dollar sign, slash, plus and percent. Every symbol is framed by an asterisk (*), which serves as both start and stop. It has no built-in check digit, although a mod-43 check is an optional extension. According to Wikipedia, it is defined in ISO/IEC 16388 and remains the standard for military, automotive and many legacy asset-tracking lines.
The 43-Character Set
| Category | Characters | Count |
|---|---|---|
| Uppercase letters | A-Z | 26 |
| Digits | 0-9 | 10 |
| Space | (space) | 1 |
| Punctuation | - . $ / + % | 6 |
| Encodable data total | - | 43 |
| Start/stop delimiter | * | 1 (not encodable as data) |
Because there are no lowercase letters, the human-readable text above the bars is always uppercase. If your data contains lowercase or mixed case, Code 39 cannot hold it — that is the single most common reason teams move to Code 128.
Structure: 9 Elements per Character
Each character is five bars and four spaces — nine elements — of which three are wide and six are narrow. The wide-to-narrow ratio is usually set between 2:1 and 3:1 at print time. The asterisk is asymmetric, so a scanner can tell the reading direction from it. The format is deliberately simple: no start code to learn, no set switching, and no mandatory check, which is exactly why a barcode font can render it on any old printer. Another quirk of that simplicity: every character is self-contained, so a reader that catches a contiguous slice of bars can report partial content. That made Code 39 forgiving for long serial plates scanned at an angle, where the full symbol rarely sits flat in the window.
Optional Mod-43 Check Digit
Code 39 does not require a check digit, but most industrial deployments add one. In the common mod-43 scheme, digits 0-9 carry values 0-9, letters A-Z carry 10-35, and the space plus six punctuation marks carry 36-42; the check character is the weighted sum modulo 43, mapped back to the same 43-character table. The value table is fixed by the symbology, so a tool and a reader that disagree about character values will produce or reject a different check character — confirm both sides use the same table before blaming the printer.
Worked example: the string ABC1.
| Position | Character | Value | Weight | Product |
|---|---|---|---|---|
| 1 | A | 10 | 1 | 10 |
| 2 | B | 11 | 2 | 22 |
| 3 | C | 12 | 3 | 36 |
| 4 | 1 | 1 | 4 | 4 |
| - | Sum | - | - | 72 |
| - | 72 mod 43 | 29 | - | check character = J |
So the printed code reads ABC1J (asterisks shown as part of the code). The related variant Code 32 is simply Code 39 with a mandatory mod-43 check and a leading 4.
Where Code 39 Still Runs
- Military: asset and serial labels under MIL-STD-style practices are a long-standing Code 39 domain.
- Automotive and aerospace: legacy tooling, parts bins and test equipment.
- Oil, gas and utilities: pipeline markers and field equipment tags printed with basic barcode fonts.
- Postal heritage: some postal services still print Code 39, although the Universal Postal Union recommends Code 128.
- Hospital wristbands: Code 39 was the default patient-identifier symbology in many US hospitals before Code 128 and, more recently, QR-based wristbands took over, so legacy ward readers still expect it.
- DoD marking: US military property labels follow MIL-STD-130, which specifies Code 39 — one reason the symbology never lost the government-funded reader base that keeps it alive.
Code 39 vs Code 128, Measured
We encoded the same test IDs in both symbologies with the barcode generator and measured the rendered widths at an identical narrow-module size:
| Test data | Code 39 width | Code 128 width | Delta |
|---|---|---|---|
| 25 mixed-case characters | 364.5 units | 310 modules | Code 128 about 15% narrower |
| 24 digits | 351 units | 167 modules (Set C) | Code 128 about 52% narrower |
| 16-character VIN (A-Z, 0-9) | 243 units | 209 modules (Set B) | Code 128 about 14% narrower |
For short labels the two are close, but on long numeric IDs Code 128 wins by a wide margin — and it has a mandatory check digit. Code 39's remaining edge is compatibility: nearly every reader that decodes barcodes decodes Code 39, and no software is needed to generate it. If you are deciding between the two for a new line, start from EAN-13 vs Code 128 and the symbology overview before committing, and use the label maker for mixed text-and-code layouts.
Common Printing Errors
- Double asterisks. Paste data that already contains
*and the generator adds its own frame, producing a symbol likeDATAthat no reader accepts. The asterisk is framing, not data — strip it from the input. - Ratio drift. Printing from a 96-dpi screenshot and scaling it up distorts the wide-to-narrow ratio below the 2:1 floor, which shows up as intermittent reads that work at some angles and fail at others. Export SVG or PDF and let the RIP set the ratio.
- Quiet zone too small. Code 39 needs at least 10 times the narrow-bar width of clear space on each side. A logo or text line crowding the symbol creates a false start pattern, and the reader locks onto the wrong edge.
- Check-digit mismatch. Adding a mod-43 check when the receiving system expects raw data (or vice versa) makes the last character look like a data error. Agree on the pattern before printing the first label, because re-printing a full asset run is the expensive part.
- Non-uniform scaling. Stretching the symbol to fit a label changes the ratio in one axis only; a 20% horizontal stretch is enough to push the symbol below the reader's ratio tolerance even though it looks fine.