> ## Documentation Index
> Fetch the complete documentation index at: https://docs.closient.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Human-Readable Interpretation (HRI)

> What the text printed next to your barcode is, why GS1 specifies it, and how to choose its placement, layout and notation in the Closient code generator.

The text printed next to a barcode is called its **Human-Readable Interpretation (HRI)**. It is the same data the symbol encodes, written out so a person can use it when a scan fails. GS1 defines the term and the rules for it in the [GS1 General Specifications](https://ref.gs1.org/standards/genspecs/) (Release 26.0), section 4.14. Everything below cites that section unless it says otherwise.

HRI exists for one moment: the code will not scan, and a cashier, a warehouse worker or a customer has to key in the number. If the text is missing, wrong, or in an order that does not match the symbol, that moment becomes a support call.

## HRI is not the same as other text on the pack

GS1 separates two kinds of text on an object:

* **HRI** is the data that is encoded in the barcode, written out.
* **Non-HRI text** is everything else printed nearby. It may or may not also be encoded.

The distinction matters because the rules below apply to HRI only. A product name, a marketing line, or a friendly "Best before" label is non-HRI text, and GS1 treats it differently.

## The rules that shape the generator

### 1. The text follows the encoding order

HRI placed together next to the barcode "SHALL always follow the sequence of the encoded data in the barcode" (4.14, general rule 1c).

The order is not alphabetical, not numeric, and not the order that looks nicest. It is the order of the data inside the symbol. For a GS1 Digital Link QR code, that is the order of the elements in the web address: the GTIN first, then any key qualifiers (lot, serial) in their required path order, then the query-string attributes.

Closient reads the HRI from the exact payload that is encoded in the symbol and never re-sorts it. That is why the line order in the generator is not something you can drag around.

### 2. Brackets are in the text, never in the symbol

Application Identifiers (AIs) are shown in parentheses in HRI, as in `(01)` for a GTIN. The parentheses are a display convention only: "although parentheses are not encoded in the barcode, parentheses SHALL surround AIs in HRI" (4.14, general rule 2c).

Nothing in the QR code contains a bracket. A scanner never sees one. They exist so a person can tell where the AI stops and the data starts.

### 3. One element string, one line

An element string, meaning an AI and its data, "SHALL NOT be broken into multiple lines of HRI" (4.14, general rule 1e). A serial number appears on a single line, as in `(21) ABCDEF12345`. You can put different elements on different lines. You cannot split one in half.

### 4. Placement: adjacent, below by preference

HRI "SHOULD be placed adjacent to the barcode" and grouped together wherever physically possible, while keeping the text legible and leaving the symbol's minimum height and quiet zones intact (rule 1a). When packaging forces it above or beside the barcode, it should still sit close enough that it is obviously associated with the symbol (rule 1b).

Closient defaults to **below** the symbol. The generator disables placements that the symbol type does not permit. For a QR code carrying a Digital Link, those are below, above, and to the right.

### 5. Font and size

A clearly legible font is required, and OCR-B is the example GS1 names. Avoid bold, italic, light and narrow versions. The text SHOULD be at least 2 mm (0.08 in) high, and at least 3 mm (0.1181 in) on a GS1 Logistics Label (rule 2a and rule 5c). Spaces are fine in the HRI itself and are never encoded in the barcode.

The generator warns you when your size and font settings would print below the floor, instead of letting the error reach the press.

## Worked example: from Digital Link to HRI

Take a product with a GTIN, a lot, a serial number and a best before date. As a GS1 Digital Link URI:

```
https://id.example.com/01/09506000134352/10/LOT42/21/ABC12345?15=271031
```

The URI keeps the AIs as path segments and query keys: `01` is the GTIN, `10` the lot, `21` the serial, `15` the best before date. The same data as a GS1 element string, which is how a GS1-128 or GS1 DataMatrix symbol would carry it, is:

```
(01)09506000134352(10)LOT42(21)ABC12345(15)271031
```

The Closient generator walks the URI left to right, so the HRI is:

```
(01)09506000134352
(10)LOT42
(21)ABC12345
(15)271031
```

Three things to notice:

* The lines are in URI order. The date is last because it is in the query string, after the path.
* The brackets appear only in the printed text. The URI has none.
* The element string uses brackets too, but only as a way of writing the data down. In a real GS1-128 or DataMatrix symbol the AIs are bare digits, and a separator character follows a variable-length value that is not last.

<Note>
  The GS1 General Specifications are the authority for HRI even when the payload is a Digital Link URI. The GS1 Digital Link URI syntax standard does not define its own HRI rules.
</Note>

## Placement and layout gallery

Every image below is rendered by the Closient code generator's own composition code, from the same payload as the worked example. Only the option being shown changes. The symbol is a QR code with the same data in each one.

### Placement

<CardGroup cols={3}>
  <Card title="Below (default)">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/placement-below.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=458afd6ce968a4070568094557c448dc" alt="QR code with four lines of HRI text stacked below the symbol" width="492" height="613" data-path="images/hri/placement-below.svg" />
  </Card>

  <Card title="Above">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/placement-above.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=3622dd825cbfb9fe0a48e34fd42cf244" alt="QR code with four lines of HRI text stacked above the symbol" width="492" height="613" data-path="images/hri/placement-above.svg" />
  </Card>

  <Card title="Right">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/placement-right.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=592d3f2820d12f8868b58912b5a622e7" alt="QR code with four lines of HRI text stacked to the right of the symbol" width="757" height="492" data-path="images/hri/placement-right.svg" />
  </Card>
</CardGroup>

Use below unless the pack forces another choice. The generator does not offer left for QR codes.

### Layout

<CardGroup cols={3}>
  <Card title="Stacked">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/layout-stacked.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=b0df9efe6aef180e1215f978e5f288a5" alt="QR code with HRI elements on one line each" width="492" height="613" data-path="images/hri/layout-stacked.svg" />
  </Card>

  <Card title="Single line">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/layout-single-line.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=6f7bc0a7a6f95d037c5bb3829b94905c" alt="QR code with all HRI elements on one wrapped line" width="749" height="527" data-path="images/hri/layout-single-line.svg" />
  </Card>

  <Card title="Two column">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/layout-two-column.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=5ff1a987c4be5a8976ca9c73a009cf6f" alt="QR code with data titles aligned in a column and values beside them" width="619" height="613" data-path="images/hri/layout-two-column.svg" />
  </Card>
</CardGroup>

* **Single line** keeps everything grouped together, which is the spec's stated preference, and it is the default. It works best when the symbol is wide enough to carry the text.
* **Stacked** puts one element on each line. It reads easily and suits a narrow symbol.
* **Two column** aligns data titles on the left with values on the right. It only makes sense with a notation that prints a title.

All three keep every element string whole and in encoding order.

## Bracketed notation and data titles

<CardGroup cols={3}>
  <Card title="Bracketed AI (default)">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/notation-bracketed.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=641a5bd91d2e808f1d1c4261ac7ad923" alt="HRI shown as AI numbers in parentheses followed by the value" width="492" height="613" data-path="images/hri/notation-bracketed.svg" />
  </Card>

  <Card title="Data title">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/notation-data-title.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=6f321456f415ab00f5e2e5f870c75735" alt="HRI shown as plain-language titles such as GTIN and SERIAL followed by the value" width="492" height="613" data-path="images/hri/notation-data-title.svg" />
  </Card>

  <Card title="Both">
    <img src="https://mintcdn.com/closientsearchinc/eq66AJHoknccUjyb/images/hri/notation-both.svg?fit=max&auto=format&n=eq66AJHoknccUjyb&q=85&s=b5a73aafd2ca2e06bfbbe707f5499a56" alt="HRI shown as AI numbers in parentheses, then the data title, then the value" width="547" height="613" data-path="images/hri/notation-both.svg" />
  </Card>
</CardGroup>

A **data title** is GS1's short plain-language name for an AI, such as GTIN, LOT or SERIAL. GS1 lists one for each AI in section 3.

Here is the part brands should decide on purpose. GS1 describes data titles as a **non-HRI text option**: "the data title may be associated with the data instead of using the AI numbers" (4.14, general rule 4). The bracketed AI form is the HRI form. So:

* Pick **bracketed AI** when you want the text to be the standard HRI. It is the default for that reason.
* Pick **data title** when the audience is a person who will never see a GS1 AI number. The text is easier to read, but GS1 classifies it as non-HRI, and for some uses such as healthcare, GS1 has its own rules about when titles may replace AIs (4.14.1).
* Pick **both** when you want the AI and the plain-language name together. It is the safest choice for a mixed audience.

The data-title forms can also present a value more readably than the encoded one. In the gallery, the date appears as `2027-10-31` where the bracketed form prints the encoded `271031`.

## Point-of-sale codes need the 14-digit GTIN

If your code has to work at a checkout, GS1 asks for more than the general rules:

* Barcodes for point of sale "SHALL have GTIN in HRI adjacent to the barcode" (4.14.2).
* GS1 DataBar Retail POS family, GS1 DataMatrix, Data Matrix (Digital Link) and QR Code (Digital Link) "SHALL display (01) followed by the encoded GTIN in a 14-digit format" (4.14.2). A 12-digit UPC-A or 13-digit EAN GTIN is shown padded with leading zeros to 14 digits, so the 13-digit EAN `9506000134352` prints as `(01)09506000134352`.
* The 14-digit HRI is not required for a 2D barcode that sits next to a linear barcode which has its own HRI, or for a 2D code meant for consumer engagement. When a 2D code is the **only** barcode carrying the GTIN, it must show the 14-digit form.

A consumer-engagement QR code, one that sends shoppers to a product page rather than a register, leaves its HRI to the brand owner's discretion (4.14.2).

## Where this fits with sizing

HRI text takes space. The symbol has a minimum size and quiet zone that do not move, and text must stay legible next to it. [QR code sizing](/user-guides/qr-code-sizing) explains how data length decides symbol size, so every element you add to the HRI also has to be encoded, which makes the symbol bigger. [Choosing Application Identifiers](/user-guides/choosing-application-identifiers) covers what is worth encoding in the first place. Fewer elements means a smaller symbol and fewer lines of HRI.

For printing at the right scale, see [Printing labels](/user-guides/printing-labels).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.