Informative section. This reference illustrates how common GS1 identifiers and their combinations are represented as GS1 Digital Link URIs, alongside their equivalent GS1 element strings.
Table of Contents
1. GTIN
Canonical URI
https://id.gs1.org/01/09520123456788
Equivalent GS1 element string
(01)09520123456788
Valid non-canonical URIs (custom domain)
https://brand.example.com/01/09520123456788
https://brand.example.com/some-extra/pathinfo/01/09520123456788
2. GTIN + Consumer Product Variant (CPV)
Canonical URI
https://id.gs1.org/01/09520123456788/22/2A
Equivalent GS1 element string
(01)09520123456788(22)2A
Valid non-canonical URIs
https://brand.example.com/01/09520123456788/22/2A
https://retailer.example.com/01/09520123456788/22/2A
3. GTIN + Batch/Lot
Canonical URI
https://id.gs1.org/01/09520123456788/10/ABC123
Equivalent GS1 element string
(01)09520123456788(10)ABC123
Valid non-canonical URIs
https://brand.example.com/01/09520123456788/10/ABC123
https://retailer.example.com/01/09520123456788/10/ABC123
4. GTIN + Serial Number
Canonical URI
https://id.gs1.org/01/09520123456788/21/12345
Equivalent GS1 element string
(01)09520123456788(21)12345
Valid non-canonical URIs
https://brand.example.com/01/09520123456788/21/12345
https://retailer.example.com/01/09520123456788/21/12345
5. GTIN + Batch/Lot + Serial Number + Expiry Date
Canonical URI (expiry: 26 April 2018)
https://id.gs1.org/01/09520123456788/10/ABC1/21/12345?17=180426
Equivalent GS1 element string
(01)09520123456788(17)180426(10)ABC1(21)12345
Valid non-canonical URI
https://example.com/01/09520123456788/10/ABC1/21/12345?17=180426
Note: Batch/Lot (
10) and Serial Number (21) appear in the path as key qualifiers, forming a compound identifier. Expiry Date (17) appears in the query string as a data attribute.
6. GTIN + Net Weight
Canonical URI (net weight: 0.195 kg)
https://id.gs1.org/01/09520123456788?3103=000195
Equivalent GS1 element string
(01)09520123456788(3103)000195
Valid non-canonical URI
https://example.com/01/09520123456788?3103=000195
Note: AI
3103encodes net weight in kilograms with 3 decimal places. The value000195represents0.195 kg.
7. GTIN + Net Weight + Amount Payable + Expiration Date
Non-canonical URI (query parameters in arbitrary order)
https://example.com/01/09520123456788?3103=000195&3922=0299&17=201225
Equivalent GS1 element string
(01)09520123456788(3103)000195(3922)0299(17)201225
Canonical vs. non-canonical comparison
Non-canonical (unsorted): https://id.gs1.org/01/09520123456788?3103=000195&3922=0299&17=201225
Canonical (lexical order): https://id.gs1.org/01/09520123456788?17=201225&3103=000195&3922=0299
Rule: In a canonical URI, query string parameters must be sorted in lexical order of the AI key (
17<3103<3922), not numeric order.
8. SSCC
Canonical URI
https://id.gs1.org/00/195201234567891232
Equivalent GS1 element string
(00)195201234567891232
Valid non-canonical URI
https://example.com/00/195201234567891232
9. SSCC + Content + Count + Batch/Lot
Canonical URI (25 units of content GTIN 09520123456788, batch ABC123)
https://id.gs1.org/00/195201234567891232?02=09520123456788&37=25&10=ABC123
Equivalent GS1 element string
(00)195201234567891232(02)09520123456788(37)25(10)ABC123
Valid non-canonical URI
https://example.com/00/195201234567891232?02=09520123456788&37=25&10=ABC123
Note: SSCC (
00) is the primary key in the path. Content (02), Count (37), and Batch/Lot (10) are data attributes in the query string.
10. GLN and GLN + GLN Extension
10.1 GLN Only
Canonical URI
https://id.gs1.org/414/9520123456788
Equivalent GS1 element string
(414)9520123456788
Valid non-canonical URI
https://example.com/414/9520123456788
10.2 GLN + GLN Extension
Canonical URI
https://id.gs1.org/414/9520123456788/254/32a%2Fb
Equivalent GS1 element string
(414)9520123456788(254)32a/b
Valid non-canonical URI
https://example.com/414/9520123456788/254/32a%2Fb
Important: The forward slash
/has special meaning in Web URIs as a path separator. When it appears as a literal character within a data value (such as the GLN extension32a/b), it must be percent-encoded as%2F.
11. GIAI + GTIN: Semantic Differences
Both URIs below express the same combination of GS1 Application Identifiers, but they are not equivalent. The choice of which identifier goes in the path changes the meaning.
Option A — GIAI as Primary Key
https://example.com/8004/9520614141234567?01=09520123456788
Meaning: “This thing is an asset identified by this GIAI — and it is/was also a product identified by this GTIN.”
Authority: The issuer of the GIAI (the asset owner).
Option B — GTIN as Primary Key
https://example.com/01/09520123456788?8004=9520614141234567
Meaning: “This is a product, and it also carries this asset identifier.”
Authority: The licensee of the GTIN (typically the brand owner or manufacturer).
Equivalent GS1 element string (same for both)
(01)09520123456788(8004)9520614141234567
Practical Guidance
| Scenario | Recommended Primary Key | Reason |
|---|---|---|
| Asset owner manages the item after purchase | GIAI (8004) in path | The owner creates and controls the URI |
| Manufacturer produces bespoke items for a known customer | GTIN (01) in path | Rare; most mass-produced goods are made to stock |
Key takeaway: When multiple GS1 identifiers appear in one URI, only one can be the primary identification key (in the path). There is no universal rule — the decision is driven by context and who the authority for the URI is. This semantic distinction is explored further in the GS1 Digital Link Standard.
12. Quick Reference: AI Positioning Rules
| Element Type | URI Position | Example AIs | Characteristic |
|---|---|---|---|
| Primary Key | First path segment | 01 (GTIN), 00 (SSCC), 414 (GLN), 8004 (GIAI) | Core identifier; determines authority |
| Key Qualifier | Subsequent path segments | 22 (CPV), 10 (Batch), 21 (Serial), 254 (GLN ext.) | Forms compound identifier; hierarchical order matters |
| Data Attribute | Query string (?key=value) | 17 (Expiry), 3103 (Weight), 3922 (Amount), 02 (Content), 37 (Count) | No intrinsic hierarchy; order arbitrary (lexical for canonical) |
Canonical URI Checklist
- Scheme:
https:// - Domain:
id.gs1.org - No deprecated convenience strings for AIs
- GTIN-8/12/13 padded to 14 digits
- Query string contains only GS1 AI keys (no
linkType,context, etc.) - Query parameters sorted in lexical order of the key
- No trailing slash
Reference examples based on the GS1 Digital Link URI Syntax standard. For normative definitions, refer to the official GS1 specifications.
