Cognex Mobile Barcode Scanner SDK
GS1 DataBar

What is GS1 DataBar?

GS1 DataBar (formerly known as Reduced Space Symbology), is a relatively new barcode symbology. As the use of UPC and EAN barcodes matured, retailers and other supply chain members sought the ability to represent even more data in a smaller area. Further, the number of available UPC and EAN codes began to run out in the 1990s. These factors led to the development of Reduced Space Symbology or RSS. The initial specification for RSS was released in 1999 by AIM, the Association for Automatic Identification and Mobility. In 2007, GS1 officially adopted its use for supply chain members, renaming it GS1 DataBar.

DataBar is a linear, or one-dimensional (1D) barcode. This means that data in the barcode is represented by the varying width and spacing of a set of parallel lines (or bars). DataBar barcodes come in several different formats (e.g., standard, stacked, and expanded). The most common of these will be discussed later.

DataBar is highly efficient as compared to UPC and EAN. The standard DataBar symbol, called DataBar Omnidirectional, can represent 14 digits in less than half the space required for a complimentary UPC/EAN code (which is only 12 or 13 digits).

Another important characteristic of DataBar is that it permits omnidirectional scanning in most of its formats. This means the barcode symbol can be scanned in any direction (forward or backward) without regard to the specific orientation of the barcode to the scanner. Omnidirectional barcode scanners are most commonly found at checkout counters.

DataBar Omnidirectional

The standard DataBar symbol is most often referred to as DataBar Omnidirectional (formerly called RSS-14). It is specifically designed to carry a 14-digit GS1 Global Trade Identification Number (GTIN-14). Other GTINs (GTIN-8, GTIN-12, and GTIN-13) can be represented as well: leading zeros are added to the number to pad it to 14 digits. Below is a simple example:




In order to achieve its high data density, DataBar Omnidirectional uses a complex data representation scheme with the barcode broken into 8 regions:

  • The left guard pattern (two modules);
  • A data character starting with a space;
  • A left finder pattern;
  • A data character starting with a bar;
  • A data character starting with a bar;
  • A right finder pattern;
  • A data character starting with a space;
  • The right guard pattern (two modules).

The left and right finder patterns are used to represent a check digit. The first and last data characters are 16 modules wide, while the middle data characters are 15 modules wide

Other, more traditional linear barcodes (e.g., Code 11, Code 25, Code 39) have a direct relationship between the data digits being encoded and bar/space patterns used. That is, for each digit 0-9, there is a specific, unique bar/space pattern for that digit. DataBar, though, employs a sophisticated data encoding and compaction technique: there is no one-to-one correspondence between the digits stored in the barcode and the bar/space patterns of the data characters used (after all, DataBar is encoding 14 digits with just 4 data characters). This also means that some software algorithms need to be used to encode and generate a DataBar symbol; it cannot be generated with just check digit computation and a font.

Here is our example from above, diagramed for clarity. Note that the text string below the barcode has been removed for readability:




The specification for DataBar Omnidirectional requires that the symbol be at least 33 modules in height to support omnidirectional scanning.

DataBar Truncated

If omnidirectional scanning is not required (i.e., the DataBar is not intended to be scanned by a point-of-sale system), barcode heights of less than 33 modules can be used (but no less than 13). This format is referred to as DataBar Truncated and, other than the barcode height, is identical to DataBar Omnidirectional in all other aspects. Here is our example from above, using a height of 13 modules instead of 33:




DataBar Stacked Omnidirectional

DataBar Stacked Omnidirectional (formerly known as RSS-14 Stacked Omnidirectional) is used to represent GTIN-14s when horizontal space is limited. Essentially the DataBar Omnidirectional barcode is “split” into two parts and “stacked” as two rows with the addition of a separator pattern between the two rows and row guard patterns (one at the end of the first row and another at the start of the second row). Here is the same GTIN as our previous example, now encoded as DataBar Stacked Omnidirectional:




Like DataBar Omnidirectional, each row must be at least 33 modules high to allow for omnidirectional scanning. Note that DataBar Stacked Omnidirectional barcodes typically appear without the printed digits of the GTIN to conserve print space.

DataBar Stacked

Similar to a DataBar Truncated, when omnidirectional scanning is not required, a DataBar Stacked barcode can be used in lieu of DataBar Stacked Omnidirectional. DataBar Stacked is not quite as simple as reducing the height of the rows as was the case with DataBar Truncated:

  • The row separator pattern is only a single module in height (in DataBar Stacked Omnidirectional it is 3 modules);
  • The top row must be at least 5 modules in height;
  • The bottom row must be at least 7 modules in height.

Here again, is our previous sample GTIN, now formatted as a DataBar Stacked:




DataBar Limited

DataBar Limited (also known as RSS Limited) is smaller than DataBar Omnidirectional and DataBar Truncated and is not intended for omnidirectional scanning by point-of-sale laser systems. Like the other previously discussed DataBar formats, Limited is fixed length, numeric only, and is specifically designed to carry a GTIN-14. Below is a simple example:




DataBar Limited also uses a complex data representation scheme with the barcode broken into 5 segments:

  • The left guard pattern (two modules);
  • A data character starting with a space;
  • A check character starting with a space;
  • A data character starting with a space;
  • The right guard pattern (two modules).

The data characters are each 26 modules wide, while the check character is 18 modules wide:





DataBar Limited has a minimum height of 10 modules.

DataBar Expanded

Unlike the other DataBar formats previously discussed, DataBar Expanded is variable length and alphanumeric. DataBar Expanded was designed to represent a GTIN-14 with supplemental data (like product weight, “best by” date, serial number, etc.), and yet still be scanned by properly configured point-of-sale, omnidirectional scanners.

DataBar Expanded also uses sophisticated data encoding and compactions techniques, again requiring some software algorithms to encode the data message and generate the barcode symbol.

The example below encodes both a GTIN-14 (012345678912) and a production date (April 23, 2015, as 150423):




The minimum height of a DataBar Expanded symbol is 34 modules.

DataBar Expanded Stacked

DataBar Expanded Stacked works much like DataBar Stacked Omnidirectional: the symbol can be broken into multiple rows (as many as 11) and “stacked” when horizontal space is limited. Here is our example from above with a third element added; Product Variant (06):




Similar to DataBar Stacked Omnidirectional, adjacent rows of a DataBar Expanded Stacked barcode are separated with a 3-module high separator pattern and each data row must be at least 34 modules in height.

Who uses GS1 DataBar?

GS1 has adopted the DataBar bar code to complement and potentially displace the use of UPC and EAN at the point of sale and elsewhere in the supply chain. Though most consumer products and point-of-sale systems still rely heavily on UPC/EAN, the GS1 DataBar has made inroads into a number of segments:

  • Fresh food products – GS1 Stacked Omnidirectional barcodes now appear on produce, meat, seafood, deli, dairy, and even bakery items in many US and other international grocery stores. Loose produce items can be scanned at the point-of-sale versus the less accurate, error-prone manual keying process;
  • Warehousing – GS1 Databar is being used more frequently for case and palette marking in the warehouse and distribution center. Formats like Databar Expanded and Databar Expanded Stacked allow labelers to include supplemental product information like package date, sell-by-date, and weight to prove better inventory monitoring and control;
  • Coupons – manufacturer coupons have been using GS1 Databar barcodes in the US for years.

How do we help developers using DataBar?

The Cognex Mobile Barcode Scanner SDK supports DataBar detection, enabling developers to gather relevant workflow and application data into their own barcode scanning apps. You can download the SDK for free by registering on the Cognex Mobile Barcode Developer Network. Packaged with the consumer product barcodes of EAN, UPC, PDF417, and QR Code, the SDK Consumer Developer License (CDL) lets you deliver a powerful retail experience quickly and easily into your barcode scanning apps. In addition, the Barcode Scanner SDK supports a broad range of symbologies to meet your growing development needs.

Get Started