Barcodes Code 39 Runs in your browser

Code 39 Barcode Generator

Generate Code 39 barcodes for IDs, badges and inventory.

Your data is processed locally in your browser and is not uploaded to our servers.

What is Code 39?

Code 39 is a long-established barcode used for ID cards, badges, inventory and government or military systems. It's simple and widely supported by older scanners.

How to create one

Enter your data using the supported characters. Lowercase letters are converted to uppercase; unsupported characters are flagged so you can correct them before generating.

Supported characters

Code 39 supports A–Z, 0–9, space and the symbols - . $ / + %. It doesn't support lowercase or most punctuation, which keeps it robust but limits capacity.

Where to use it

Common on name badges, asset labels, library cards and industrial tracking where compatibility with legacy equipment matters more than density.

Scanning and printing tips

Code 39 is less dense than Code 128, so it needs more width per character. Keep it short, print at a generous size, and maintain contrast.

Limitations

Limited character set and lower density make it unsuitable for long or mixed-case data. Consider Code 128 when you need more.

What Code 39 can and cannot encode

Code 39 has exactly 43 characters: 0–9, A–Z (uppercase only), space, and - . $ / + %. The asterisk * is the start and stop character and cannot appear in your data — the tool adds it and you should not type it.

Lowercase letters, punctuation such as _, # or @, and anything non-ASCII are simply not representable. There is a "Full ASCII Code 39" convention that encodes them as two-character sequences (+A for lowercase a, and so on), but it only works if the reading scanner is configured for it — and if it is not, the scanner returns the escape sequence as literal characters. Unless a trading partner has specified full-ASCII mode, treat the 43 characters as the whole alphabet and design your identifiers to fit.

The check character, and why it is usually off

Code 39 is self-checking: each character's bar pattern is constructed so that a single misprinted or misread element does not produce a different valid character. That is why a check character is optional here when it is mandatory in Code 128.

The optional modulo-43 check character assigns each of the 43 characters a value, sums them, and takes the remainder modulo 43. It catches transposition errors that self-checking does not.

Enable it when the data is a number that has to be right (asset tags, serial numbers, anything feeding a database) and you control both ends. Leave it off when a scanner or system you do not control will read the code — because a reader not configured to expect it will hand the check character to your software as an extra data character, which is a confusing failure. When in doubt, off is the safer default.

Why the symbol is so wide

Code 39 uses nine elements per character, three of them wide — hence the name — plus a narrow gap between characters. Every character costs roughly 13 to 16 modules against Code 128's 11, and numeric data cannot be paired. A 10-digit value that fits in about 41 mm as Code 128 typically needs 80–100 mm as Code 39 at the same X-dimension.

On a 50 mm asset label that difference decides whether the barcode fits. Three ways to deal with it, in order of preference:

  1. Use Code 128 instead, if nothing forces Code 39.
  2. Shorten the identifier. Six characters is usually plenty for internal numbering; the check character costs one more.
  3. Reduce the X-dimension — but not below what the printer resolves. At 203 dpi one dot is 0.125 mm, so an X-dimension must be a whole number of dots: 0.25 mm (2 dots) or 0.375 mm (3 dots), never 0.3 mm. The size calculator flags this.

Reducing the narrow-to-wide ratio is not on that list. It is fixed between 2:1 and 3:1, and going outside it produces a symbol many scanners reject.

Frequently asked questions

Why was a character rejected?

Code 39 supports only A–Z, 0–9, space and - . $ / + %. Lowercase is auto-converted to uppercase; other symbols are not allowed.

Code 39 or Code 128?

Use Code 39 for legacy compatibility and simple IDs; use Code 128 for denser, mixed-case data.

Does it need start/stop characters?

The required start and stop markers are added automatically.

Why will it not accept lowercase letters?

Code 39 has 43 characters and none of them is lowercase. There is a full-ASCII convention that encodes lowercase as two-character sequences, but it only works if the reading scanner is configured for it — otherwise the escape characters arrive as literal data.

Should I turn on the check character?

Enable it when the data must be right and you control both ends. Leave it off when a scanner you do not control will read the code, because a reader not expecting it hands the check character to your software as extra data.

Why is my Code 39 barcode so much wider than Code 128?

Nine elements per character with no numeric pairing. A 10-digit value that fits in about 41 mm as Code 128 typically needs 80–100 mm as Code 39. If nothing forces Code 39, use Code 128 instead.

Curious how we build and check these codes? Read our methodology, and the disclaimer on what a generated barcode image is and is not.