2D code

from Wikipedia, the free encyclopedia

A 2D code ( 2D barcode or matrix barcode ) refers to optoelectronically readable fonts that consist of lines or dots of different widths and gaps in between with the highest possible contrast. Unlike the one-dimensional bar codes ( English bar code ) the data is not only in one direction (one-dimensional) codes, but as an area over two dimensions, the term of which is derived. The advantage is a higher density of useful information. In this context, the term code does not represent any type of encryptionbut for mapping data in symbols .

The data in a 2D code with optical reading devices, such as camera scanners , machine-read and electronically processed further. Common uses of 2D codes are in the area of logistics for product labeling and mobile tagging . Due to their higher storage density, they are also used for optical data storage. For example, digital audio signals are stored between the perforation holes in the film in the form of 2D codes in the optical sound method .


The simplest form of 2D codes represent the one-dimensional stacked bar codes ( English Stacked bar code ), which are arranged in several rows. Examples of stacked barcodes are PDF417 and Codablock . The postal code RM4SCC is not a real 2D code, but additional information is encoded in the second dimension over the bar length.

Array codes receive the information in the form of a rectangular matrix such as the QR code , DataMatrix or Aztec code . Point codes use individual points to encode information.

There are also 2D codes that arrange the information in circular rings, such as the ShotCode . The transition to higher-dimensional codes with three or more dimensions takes place, for example, via the colors used, as is the case with the High Capacity Color Barcode (HCCB).

Stacked codes


Codablock-F example

Codablock was developed by Heinrich Oehlmann as a stacked version of the standard barcodes Code39 and Code128 between 1990 and 1994 in Germany. Codablock can best be compared with a line break in a text editor. As soon as one line is full, the next is broken, whereby the line number is inserted into each line and the number of lines is inserted into the finished block. A checksum follows at the end.

Code 49

CODE 49, 4 rows with parity

Code 49 is a barcode with three error correction methods and therefore fulfills increased security requirements compared to other identification methods. Code 49 is the first multi-row code and was developed in 1987 for logistic applications in space travel by David Allais at Intermec (USA).


"Wikipedia" as PDF417 code

PDF417 stands for "Portable Data File". In contrast to other stacked barcodes such as Codablock, Code 16k or Code49, it does not require complete line congruence. A maximum of 2000 characters can be stored in a PDF417. The PDF417 is not a real matrix code like the DataMatrix code. There are adjustable error correction levels (0–9). In terms of data content in relation to size, the PDF417 scores very poorly compared to DataMatrix. It makes sense (if not particularly efficient) to use it in connection with laser scanners that cannot capture matrix symbologies. As soon as camera systems are used as scanners, real matrix codes are the method of choice. The PDF417 was originally developed by Symbol Technologies . The PDF417 is now also specified in an ISO / IEC standard.

Matrix codes

Matrix codes could previously only be read with CCD camera scanners. The alignment in the CCD image is practically irrelevant, so that the reading is omnidirectional. In the meantime, some scanner manufacturers have developed laser scanners that perform automatic x / y scanning and generate an image from the data obtained. This means that matrix codes can also be scanned with laser scanners. These have slightly more favorable optical properties than cameras.

QR code

QR code for text "Version 2"

QR code stands for Quick Response Code , a two-dimensional code that is very common in Japan . Many cell phones with built-in cameras can read the code. The QR code was developed by Denso (Japan) in 1994 . It is square and easy to recognize thanks to its search aids, nested light and dark squares in three corners. The symbol elements are squares, of which at least 21 × 21 and a maximum of 177 × 177 elements are in the symbol. There are four error correction levels that allow a reconstruction in the event of damage from 7% (level L) to 30% (level H). More than 4000 alphanumeric characters can be encoded per code. Larger content can be divided into up to 16 individual codes. The micro QR code can hold up to 35 digits.

Standard: ISO / IEC 18004


DataMatrix 2D code

When data matrix code which adds Reed-Solomon Error correction of redundant data. As a result, between approx. 30% and 60% of the code words are code words for error correction. This allows some faulty modules to be corrected without endangering the decoding. The code is defined in the international standard ISO / IEC 16022. This type of 2D code is currently gaining in importance. Examples are electronic postage stamps ( Internet stamps ), part labeling in the automotive industry, the aerospace industry and in medical technology.

If the DataMatrix code is used with the ECC200 error correction method and together with the GS1 data structure, then the result is called GS1 DataMatrix. (The EAN organizations have all renamed themselves GS1, so the CCG in Cologne became GS1 Germany.)

  • Standard: ISO / IEC 16022
  • GS1 data structure: ISO / IEC 15418 with reference to ANSI MH10.8.2



The MaxiCode was developed by UPS in 1989 for the rapid identification, tracking and sorting of packages. It contains the UPS tracking number, the weight, the type of service of the shipment and the address details. The concentric circles in the middle (so-called bull's eye) are supposed to help scanners to find the code. In contrast to other 2D codes, the individual points have a hexagonal shape.

Aztec code

Aztec code

The Aztec code is an independent 2D code type. It is laid down in the ISO / IEC 24778 standard. The Aztec code is also described in the literature volume 2 listed below. The German railway , the Austrian Federal Railways and the Swiss Federal Railways use this 2D code on their online tickets or Mobile Tickets ( MMS ) DB. The US government also uses this code to store biometric data upon entry and exit (US VISIT program).

JAB code

The text "Wikipedia" in JAB code with 8 colors

The JAB Code (of J ust A nother B ar code ) is a colored advancement of two-dimensional bar codes by the Fraunhofer Institute for Secure Information Technology . Because of the additional color coding, it has a higher data density than the black and white codes.

Han Xin Code

Han Xin barcode

The Han Xin code is a matrix code that was developed by the Chinese AIM and GS1 (Article Numbering Center China, ANCC) and declared as the Chinese standard (GB / T 21049-2007) in 2007.

Its specialty is the support of Chinese characters. This is another reason why this form of code is largely unknown in Europe - it is only supported by a few barcode reader apps. In China, the code is particularly widespread in industry. The source code is public domain.

The Han-Xin code is standardized and recorded in ISO / IEC JTC1 SC31.

Point codes


Point codes, English dot code , are two-dimensional optical codes with high information density and good reading reliability. The main area of ​​application is the marking of various materials with specific printing techniques, in particular embossing and engraving techniques. Furthermore, the code can even be created using drilling techniques. Applications: e.g. B. when marking axes on the face. The code is not identical to the open data matrix code according to ISO / IEC 16022 and DIN V 66401.

Examples of real dot codes are the Dot Code A or the Snowflake Code or the BeeTagg . The DataMatrix code according to ISO / IEC 16022 is not a dot code. However, there are applications and labeling processes that also work with DataMatrix codes in so-called DPM (Direct Part Marking) processes (e.g. dot peening). The individual modules of these dot codes, based on the data matrix, are no longer square and connected, but round and separated. In industrial applications for part identification, this is now a common application that suppresses the real dot codes or does not even allow them to come into play.

Features: compact code, flexibility in adapting information on a given area; it can be read omnidirectionally.

Special forms

Composite codes

Composite codes , also called double code symbols, are made up of a linear barcode (1D) and a 2D code located directly above it.


RM4SC code

The English Royal Mail 4 State Customer Code RM4SCC is an alphanumeric code (only capital letters) from Great Britain, but is now also used in other countries (Switzerland, Austria, Denmark, Australia). The Universal Postal Union has also issued corresponding specifications.

The RM4SCC is in itself a 1D code, but uses the second dimension in the form of bars of different lengths for coding in order to tolerate image distortions that are caused by the very high printing speeds in mail sorting systems during direct printing in larger areas than other codes.

Individual evidence

  1. Information on the Aztec code at Taltech
  2. Han Xin Code | BarMatrixCode. Retrieved April 23, 2019 .
  3. GS1 CHINA. Retrieved April 23, 2019 .


  • Bernhard Lenk: manual of automatic identification. Volume 2: 2D codes, matrix codes, stacked codes, composite codes, dot codes . Lenk Monika Fachbuchverlag, Kirchheim unter Teck 2002, ISBN 978-3-935551-01-4 .

Web links

Commons : Barcode  album with pictures, videos and audio files