What data is encoded in various barcodes?

Barcode Information | Tutorials | Examples

Some barcode types, or symbologies, encode only numbers while others encode letters and numbers. Other barcode types can actually encode files, pictures and other binary data. Here is a basic breakdown of a few barcode types and what they encode:

 Barcode symbologyTypes of data encoded
 Code 39Numbers and upper case letters with a few symbols
 Code 128All numbers, letters and punctuation plus ASCII 0 to 127
 Data MatrixAll numbers, letters and punctuation, ASCII 0 to 127 plus files and bytes.
 Interleaved 2 of 5Numbers only
 MSI CodeNumbers only
 PDF417All numbers, letters and punctuation, ASCII 0 to 127 plus files and bytes.
 PostnetNumbers only

Recommendations for barcoding:

If the intended use of the barcode fonts is for printing, check the type of data to encode:

  • Only numbers, up to about 20 digits, choose Codabar or Interleaved 2 of 5. Codabar is the densest self-checking symbology. ITF is a numeric-only barcode used for encoding pairs of numbers in a high-density barcode format.
  • Only uppercase letters, numbers and these symbols (- . $ / + %), up to about 15 digits, choose Code 39. Code 39 is the densest self-checking alpha-numeric barcode type.
  • Uppercase and lowercase letters, numbers, punctuation, any letter or symbol appearing on the US keyboard and lower ASCII functions such as returns and tabs, up to about 20-30 digits, use Code 128.
  • Several lines of data of any type over 20 digits, use PDF417AztecQR-CodeorData Matrix.

If the intended use is a barcode component or label printing application, check the type of data to encode:

About Barcode Accuracy and Misreads

In a study at Ohio University, several different bar code symbologies were tested to determine their accuracy and are listed below. Keep in mind that a well-trained data entry operator will usually make a data entry error once every 300 keystrokes. Therefore, even implementing the least accurate symbology is a huge step forward to increase production and reduce data entry errors. The most inaccurate symbology (UPC) is used in the retail industry.

 Barcode TypeWorst Case AccuracyBest Case Accuracy
 Data Matrix1 error in 10.5 million1 error in 612.9 million
 PDF4171 error in 10.5 million1 error in 612.4 million
 Code 1281 error in 2.8 million1 error in 37 million
 Code 391 error in 1.7 million1 error in 4.5 million
 UPC1 error in 394 thousand1 error in 800 thousand