2D Codes Explained: What’s the Difference Between a Data Matrix Code and a QR Code?

  • By Domino Printech
  • October 08, 2021
  • General
  • Beverage
  • Beauty & Grooming
  • Food
  • Life Sciences
  • Tobacco
Get in touch

QR codes and Data Matrix codes are both 2D barcodes or ‘2D codes’, and are both becoming much more commonly used by manufacturers, but in very different ways.

From extending product packaging to communicate brand messaging to providing options for internal track and trace and anti-counterfeiting measures, 2D codes can offer a wealth of opportunities for manufacturers in all industries.

But, which 2D code is right for your business?

In this blog, we seek to outline the fundamental differences between Data Matrix codes and QR codes, so that you can make an informed decision on which 2D code is right for you.

Before we look at the best ways to use them, let’s explain how to distinguish a Data Matrix code from a QR code.

What is a Data Matrix code?

A Data Matrix is a 2D barcode that encodes data in black and white, or contrasting dark and light, cells arranged in a grid. Unlike 1D barcodes, Data Matrix codes are omnidirectional, meaning that they can be read from any angle.  

The Data Matrix was invented in 1994, by US company International Data Matrix, Inc. (I.D. Matrix).

The number of rows and columns within a Data Matrix increases with the amount of information stored in the code; this is limited to 2,335 alphanumeric characters.

What does a Data Matrix code look like?

Data Matrix codes are usually square, or sometimes rectangular in shape, and are made up of multiple light and dark square dots, or ‘cells’, arranged in a grid or ‘matrix’.  

Though typically printed in black and white, Data Matrix codes can be printed in different colour combinations, provided there is sufficient contrast between dark and light cells to ensure readability.

Data Matrix codes are defined by an L-shaped pattern at one side of the code, creating two solid adjacent borders. This ‘finder pattern’ helps camera scanners to locate the code.

Data matrix code

How do you scan a Data Matrix code?

Data Matrix codes can be scanned from any angle (0-360°) using a Data Matrix code scanner, or omnidirectional camera scanner. Some smart phone cameras are physically capable of scanning Data Matrix codes; however, many smart phones do not have the functionality built in and will require a third-party app to read the information.

What is a QR code?

A QR code, or Quick Response code, is also a 2D barcode that encodes data in black and white, or contrasting dark and light, cells arranged in a grid. Like other 2D codes, QR codes are omnidirectional meaning that they can be read from any angle. 

The QR code was invented in 1994, by the Denso Corporation of Japan.

QR codes can store a maximum of 4,296 alphanumeric characters, determined by the number of rows and columns contained within the code.

What does a QR code look like?

A QR code consists of dark- or light-coloured squares arranged in a grid on a contrasting background.

Though often printed in black and white, QR codes and can be printed in many different colours, provided there is sufficient contrast between dark and light cells.

To help scanners identify the code, QR codes include a ‘finder pattern’ of three identical square structures located in the top left, top right, and bottom left corners of the code.

QR code

How do you scan a QR code?

Like Data Matrix codes, QR codes can be scanned from any orientation using a specialist QR code scanner, or camera scanner. QR codes can also be scanned using a smart phone camera. In recent years, some mobile phone manufacturers have started to include QR code readability within standard camera functionality. This gives QR codes a slight edge over Data Matrix codes in customer-facing applications, as users may be able to scan a code direct from their phone camera, without using a specialist app.

What’s the difference between a Data Matrix code and a QR code?

Data Matrix and QR codes are both 2D barcodes, which can carry all the same information included with traditional linear or ‘1D’ barcodes. GS1 – the global standards organisation – develops and maintains global standards for different barcode types, including Data Matrix codes and QR codes. This means that Data Matrix codes and QR codes and can carry all GS1 ID keys including a GTIN (Global Trade Item Number) – a unique, internationally recognised number used to identify products.

Both codes can be used to store information including item expiry dates, serial numbers, and batch/lot number, and can contain URLs to ‘extend’ product packaging, by directing consumers to an external website with useful information such as allergen and lifestyle suitability, or recipe and usage instructions.

In addition, both codes have error correction capabilities – which means that, unlike a standard 1D barcode, the data can still be read even if the code is partially removed or damaged. Error correction capabilities for both codes is achieved by using the Reed-Solomon Error Correction algorithm – a mathematical error correction method which adds backup data into a code.

However, there are some slight differences between the two codes which make them more suitable for different applications.

Data Matrix codes are physically smaller than QR codes, offering high data density in a very small size, making them an ideal solution for marking individual product parts, where space might be limited. The US Electronic Industries Alliance (EIA) recommends using Data Matrix for labelling small electronic components. Data Matrix codes are also the only 2D codes approved by GS1 for regulated healthcare items; they are also the default code type for automotive and aerospace applications.

By comparison, QR codes are larger and can contain more data than Data Matrix codes. In addition, while Data Matrix codes are only capable of encoding information in numeric and alphanumeric characters, because QR codes were invented in Japan, they can also include Kanji, and other multi-byte character sets, making them suitable for use with non-European languages.

Both QR codes and Data Matrix codes are public domain codes; this means that they are royalty free, so you don’t need to pay for a licence to use them. Published specifications and print requirements for each code are available from the International Organization for Standardization (ISO). If you want to understand more about how the codes work and how to create them, you can check out the relevant ISO standard for more detail:

  • Requirements for Data Matrix codes are specified under the ISO/IEC 16022 international standard.
  • Requirements for QR codes are specified under the ISO/IEC 18004 international standard.

 2D code comparison

Code type Data Matrix code QR code 

Maximum capacity

 

Numeric: 3116

Alphanumeric characters: 2335

Bytes: 1556

Numeric: 7089

Alphanumeric characters: 4296

Bytes: 2953

Size

Min 10×10 cells  

Max 144×144 cells

Min 21×21 cells

Max 177×177 cells

Error correction

Reed-Solomon Error Correction algorithm 

Error correction capability of 25–33%

Level is not adjustable

 

Reed-Solomon Error Correction algorithm 

Error correction for QR codes can be adjusted to allow for greater error correction capabilities. Four error correction levels are available – for each level a greater amount of back-up data is required, which increases the size of the QR code.  

  • Level L 7%
  • Level M 15%
  • Level Q 25%
  • Level H 30%

 

Which 2D code is right for you?

Despite their differences, both codes can be used in very similar ways – both provide options to encode more data than a traditional 1D barcode and can be used to provide additional information for internal traceability, and consumer marketing purposes.

In practice, however, Data Matrix codes are most often used for internal product identification and anti-counterfeiting applications, while QR codes have become the standard format for most consumer-facing applications.

Some typical applications for both codes are outlined in the table below.

2D Code Applications

Data Matrix code QR code
  • Supply chain traceability, including direct parts marking, such as with electronic components
  • Anti-counterfeiting through serialisation, such as in pharmaceutical packaging
  • Additional product information
  • Usage instructions and recipes
  • Social sharing
  • Auto-linking for spares ordering and guarantee registration
  • Promotions, contests, and gamification

 

Printing 2D codes

As with any product labelling, it is also important to ensure that 2D codes are printed correctly, by choosing the right printing application, and an accompanying code verification system, to check the quality and accuracy of the final code.

While Data Matrix and QR codes provide a greater tolerance for errors than traditional 1D barcodes, it is imperative to ensure that codes are clean, crisp, and correct to ensure that they can be used effectively by consumers and trusted by retailers and those within the wider supply chain.

Code verification systems, such as Domino’s R-Series, provide the ability to scan codes after printing, to ensure that the printed code meets print quality requirements, and can also be used to check data accuracy.

What’s the best technology for printing 2D codes?

If you are considering adding a Data Matrix code or QR code to your product packaging and need more information on how best to do this, please get in touch. We have a range of different printing and labelling solutions to suit the requirements for all industries and packaging types. We also offer a range of specialist code verification systems, designed to work alongside the Domino family of products. Our experts are on hand to talk through your specific requirements, and discuss which code, and printing solution, is best for your business.

Need more information?

Contact us about our innovative and award-winning printing and marking solutions. Get in touch

Featured Articles

news
casestudy
news