GS1 symbols encode Application Identifiers (AI)
that are commonly encoded in GS1-128
, GS1 DataMatrix
, and GS1 QR Code barcodes.
In 2012, GS1 QR-Code became a ratified standard for use within the GS1 System, primarily for sharing extended packaging information associated with a product GTIN
. GS1 also supports the encoding of multiple AIs within QR-Code symbols as the FNC1 character. For consumer goods, GS1 recommends using either GS1-DataMatrix or GS1 QR-Code when brand owners want to encode a link to a website. When either barcode is scanned by a consumer, the same information should be transmitted regardless of the symbology used.
All IDAutomation QR-Code products are QR Code symbol compliant. However, only IDAutomation QR-Code products released or updated after April 2016 support GS1 QR-Code, which include the following:
If the desired product does not yet support GS1 QR-Code, GS1 DataMatrix
may be another option since either GS1-DataMatrix or GS1 QR-Code may be used according to GS1 documentation.
Generating and Encoding the FNC1
GS1 specifications call for the FNC1 character to be used as a data field separator at the end of a variable-length data field. In IDAutomation GS1 QR-Code symbols the first FNC1 is included with the ~1 character and additional FNC1 characters may be encoded with ~1 in any mode. In addition, to comply with GS1 QR specifications, the character <GS> (encoded as ~d029) in
byte mode or the % character in alphanumeric mode may also be used. In all cases, the scanner should decode additional FNC1 characters as ASCII 29 which is character <GS>.
When GS1 QR-Code is used for sharing extended packaging information, as in Fig. 2
below, Application Identifiers AI (01) and AI (8200) are mandatory and other GS1 AIs are optional.
There are two methods of encoding FNC1 characters within QR-Codes and these are referred to as first position (GS1) and second position (AIM):
- FNC1 mode in the first position refers to a GS1 symbol and it is encoded with the ~1 character. IDAutomation refers to this as GS1 QR-Code.
- FNC1 mode in the second position is encoded with the ~2 character and identifies symbols formatted in accordance with specific industry or application specifications provided by AIM International. IDAutomation will refer to this as AIM QR-Code. The first AI is required directly after the ~2 in parentheses in all AIM QR-Code symbols.
Examples Generating GS1 QR-Code Fig. 1: GS1 QR-Code Symbol Encoding (01)04912345123459(15)970331(30)128(10)ABC123 in alphanumeric mode, which includes the GTIN, best before date, quantity, and batch number. Parentheses should not be part of the data encoded in GS1 QR-Code symbols.
|DataToEncode using ~1||~101049123451234591597033130128~110ABC123|
|DataToEncode using ~1 and %||~101049123451234591597033130128%10ABC123|
|Data Returned from scanner||]Q301049123451234591597033130128<GS>10ABC123|
GS1 QR-Code symbol encoding (01)04912345123459(8200)https://www.idautomation.com
in byte mode, which encodes the GTIN and a URL for product information.
|DataToEncode using ~1||~101049123451234598200https://www.idautomation.com|
|Data Returned from scanner||]Q301049123451234598200https://www.idautomation.com|
Example Generating AIM QR-Code with FNC1 in Second Position
When generating AIM QR-Code symbols, the first AI is required directly after the ~2 in parentheses. The parentheses will not be encoded and are only used to encode the first AI within the symbol. If additional FNC1s need to be encoded, they should be encoded as ~2 in any mode. In addition, to comply with AIM QR specifications, the character GS (encoded as ~d029) in byte mode or the % character in alphanumeric mode may also be used. Fig. 3: AIM QR-Code symbol encoding (37)AA1234BBB112(8200)https://www.idautomation.com in byte mode. Parentheses are required directly after the ~2 to encode the first AI in AIM QR-Code symbols.
|DataToEncode using ~2||~2(37)AA1234BBB112~28200https://www.idautomation.com|
|DataToEncode using ~2 and GS||~2(37)AA1234BBB112~d0298200https://www.idautomation.com|
|Data Returned from scanner||]Q537AA1234BBB112<GS>8200https://www.idautomation.com |
GS1 and AIM QR-Code Summary Chart
| Barcode Type||Encoded First AI||Encoded Second AI||Decoded First FNC1||Decoded Second FNC1|
(Byte Mode)||~1||~1 or ~d029||]Q3||<GS>|
(Alphanumeric Mode)||~1||~1 or %||]Q3||<GS>|
(Byte Mode)||~2||~2 or ~d029||]Q5||<GS>|
(Alphanumeric Mode)||~2||~2 or %||]Q5||<GS>|
Decoding GS1 QR-Code
According to GS1 specifications, when GS1 emulation is enabled, the first FNC1 character should be decoded as “]Q3” when it is a GS1 symbol or “]Q5” when it is an AIM symbol and any additional FNC1 characters should be decoded as <GS> (ASCII 29). The first 3 characters of this decoded symbol are referred to as the AIM symbology identifier. Not all scanners properly decode symbology identifiers or FNC1 characters. The <GS> character is not visible when scanned unless used with an advanced verifier or the IDAutomation Scanner ASCII String Decoder
. The screenshot below is the decoded symbol of Fig. 1 above, scanned with the IDAutomation 2D USB Scanner
QR-Code barcode symbols may be easily verified with the Barcode Data Decoder Verifier App, which may be used to verify encoded data and parse out the GS1 Application Identifiers. The screenshot below is the result from scanning Fig 1 above.