Supported Formats

Barcode Format Reference Guide

Comprehensive documentation for all 12 barcode formats supported by our API. Learn about each format's capabilities, use cases, and technical specifications.

QR Code

2D Barcode

The most popular 2D barcode for mobile scanning

Specifications

Capacity Up to 7,089 numeric or 4,296 alphanumeric characters
Error Correction L (7%), M (15%), Q (25%), H (30%)
Module Size 21×21 to 177×177
Generate QR Code

QR Code (Quick Response Code) is a two-dimensional matrix barcode invented in 1994 by Denso Wave, a Japanese automotive company. Originally designed for tracking parts in vehicle manufacturing, it has become the most widely used 2D barcode format worldwide.

QR codes can store various types of data including URLs, text, contact information, WiFi credentials, and more. They can hold up to 7,089 numeric characters or 4,296 alphanumeric characters, making them incredibly versatile for many applications.

One of the key features of QR codes is their error correction capability. Even if part of the code is damaged or obscured, it can still be read. This makes them ideal for printed materials that may get worn or partially covered.

Common use cases include mobile payments, product packaging, event tickets, restaurant menus, marketing campaigns, and authentication systems.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/qrcode?data=EXAMPLE123"

Code 128

1D Barcode

High-density alphanumeric barcode for logistics

Specifications

Characters All 128 ASCII characters
Density High (11 modules per character)
Check Digit Modulo 103 (mandatory)
Generate Code 128

Code 128 is a high-density linear barcode symbology defined in ISO/IEC 15417:2007. It is used extensively in logistics and transportation industries for ordering, distribution, and supply chain management.

The symbology can encode all 128 ASCII characters, making it highly versatile. It uses three different character sets (A, B, and C) to optimize the barcode length depending on the data being encoded. Character set C is particularly efficient for encoding numeric data.

Code 128 includes a mandatory check digit for data integrity verification. The barcode automatically calculates this check digit, ensuring that scanning errors are detected. This makes it one of the most reliable 1D barcode formats available.

It is commonly used in shipping labels, inventory management, product identification, and anywhere alphanumeric data needs to be encoded in a compact format.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/code128?data=EXAMPLE123"

Code 39

1D Barcode

Self-checking barcode used in automotive and defense

Specifications

Characters A-Z, 0-9, -.$/+% and space
Density Low to medium
Check Digit Optional (Modulo 43)
Generate Code 39

Code 39, also known as Alpha39 or Code 3 of 9, is one of the oldest barcode symbologies still in widespread use. Developed in 1974, it was the first barcode to encode alphabetic characters along with numbers.

The symbology is self-checking, meaning a single printing defect will not cause a wrong character to be read. Each character is represented by 9 elements (5 bars and 4 spaces), where 3 of the 9 elements are wide, giving the code its name.

Code 39 can encode uppercase letters A-Z, digits 0-9, and special characters including space, minus, plus, period, dollar sign, slash, and percent. While it has lower data density than Code 128, its simplicity and reliability make it popular for many applications.

It is the standard barcode used by the United States Department of Defense (LOGMARS) and is widely used in automotive, healthcare, and manufacturing industries.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/code39?data=EXAMPLE123"

Codabar

1D Barcode

Legacy format for libraries and blood banks

Specifications

Characters 0-9, -$:/.+ and A-D (start/stop)
Density Low
Check Digit Optional
Generate Codabar

Codabar, also known as NW-7 or USD-4, was developed in 1972 by Pitney Bowes. It was one of the first barcode symbologies to be widely adopted and remains in use today in specific industries.

The symbology uses a simple encoding scheme with 4 different bar widths. It can encode digits 0-9 and six special characters (- $ : / . +). Four start/stop characters (A, B, C, D) are used to mark the beginning and end of the barcode.

While Codabar has been largely superseded by more modern barcodes in many applications, it remains the standard in certain fields due to legacy system requirements and the cost of transitioning to new formats.

Primary applications include blood banks, photo labs, FedEx airbills, and library systems. The American Blood Commission adopted Codabar as the standard for blood identification in 1977.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/codabar?data=EXAMPLE123"

EAN-13

1D Barcode

International product identification standard

Specifications

Digits 13 (including check digit)
Structure Country + Manufacturer + Product + Check
Check Digit Modulo 10 (mandatory)
Generate EAN-13

EAN-13 (European Article Number) is the international standard for product identification barcodes used in retail worldwide. Developed in 1976 as an extension of the American UPC-A format, it is now administered by GS1.

The barcode consists of 13 digits: a country code (2-3 digits), manufacturer code (4-5 digits), product code (4-5 digits), and a check digit. This structure allows for over one trillion unique product identifiers.

EAN-13 is the most widely used barcode format in global retail. Every product sold in supermarkets and retail stores outside North America uses this format. It is compatible with UPC-A, as UPC codes can be expressed as EAN-13 with a leading zero.

Applications include retail point-of-sale, inventory management, supply chain tracking, and price lookup systems. Publishers use a variant called ISBN-13 for book identification.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/ean13?data=EXAMPLE123"

EAN-8

1D Barcode

Compact version for small products

Specifications

Digits 8 (including check digit)
Structure Country + Product + Check
Check Digit Modulo 10 (mandatory)
Generate EAN-8

EAN-8 is a shortened version of the EAN-13 barcode, designed for use on small products where a full EAN-13 barcode would be too large. It was introduced alongside EAN-13 as part of the European Article Numbering system.

The barcode contains only 8 digits: a 2-3 digit country code, a 4-5 digit product code, and a single check digit. Due to the limited number space, EAN-8 codes are assigned by national GS1 organizations and are typically restricted to very small products.

Despite its compact size, EAN-8 maintains the same level of reliability as EAN-13. The check digit calculation is identical, ensuring data integrity at the point of sale.

Common applications include small confectionery items, cosmetics, cigarettes, and other products where space is at a premium. Manufacturers must apply for EAN-8 allocation and demonstrate that EAN-13 is not practical for their product.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/ean8?data=EXAMPLE123"

UPC-A

1D Barcode

North American retail standard

Specifications

Digits 12 (including check digit)
Structure System + Manufacturer + Product + Check
Check Digit Modulo 10 (mandatory)
Generate UPC-A

UPC-A (Universal Product Code) is the standard barcode format used for retail products in the United States and Canada. Introduced in 1974, it was the first barcode format to be widely adopted in retail.

The barcode consists of 12 digits: a single digit number system, a 5-digit manufacturer code, a 5-digit product code, and a check digit. The number system digit indicates the type of product (0 for regular items, 2 for weighted items, etc.).

UPC-A revolutionized retail by enabling automated checkout and inventory management. The first product scanned with a UPC barcode was a pack of Wrigley's gum at a Marsh supermarket in Ohio on June 26, 1974.

While primarily used in North America, UPC-A is compatible with the global EAN-13 system. Any UPC-A code can be converted to EAN-13 by adding a leading zero, enabling international trade.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/upca?data=EXAMPLE123"

UPC-E

1D Barcode

Zero-suppressed UPC for small packages

Specifications

Digits 8 (6 + implicit check)
Compression Zero suppression algorithm
Check Digit Modulo 10 (encoded in parity)
Generate UPC-E

UPC-E is a compressed version of UPC-A, designed for small packages where space is limited. It uses "zero suppression" to encode a 12-digit UPC-A code in just 6 visible digits plus a check digit.

The compression works by removing zeros from specific positions in the UPC-A code. Only UPC-A codes with zeros in certain positions can be converted to UPC-E format. The scanner automatically expands UPC-E back to UPC-A for processing.

Despite its compact size, UPC-E maintains full compatibility with UPC-A systems. The same product information is encoded, just in a smaller space. This makes it ideal for small items that need to be tracked through the same supply chain as larger products.

Common applications include small health and beauty products, candy bars, single-serve beverages, and any product where a standard UPC-A barcode would dominate the package design.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/upce?data=EXAMPLE123"

ITF-14

1D Barcode

Shipping container barcode standard

Specifications

Digits 14 (GTIN-14 format)
Structure Indicator + GTIN-13 + Check
Bearer Bars Recommended for corrugated printing
Generate ITF-14

ITF-14 (Interleaved Two of Five) is a GS1 standard barcode used primarily for marking shipping containers and cartons. The "14" refers to the 14 digits it encodes, which represent a Global Trade Item Number (GTIN-14).

The barcode uses the Interleaved 2 of 5 symbology, where digits are encoded in pairs—one in the bars and one in the spaces between them. This interleaving technique creates a compact and efficient barcode.

ITF-14 is designed to be printed directly on corrugated cardboard, which is why it often includes bearer bars (thick bars framing the code). These bearer bars ensure consistent print quality and protect against edge damage.

The primary application is logistics and supply chain management. ITF-14 identifies the packaging level of a product—whether it's a case, pallet, or other shipping unit containing multiple retail items, each with their own EAN/UPC codes.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/itf14?data=EXAMPLE123"

Data Matrix

2D Barcode

High-density code for industrial marking

Specifications

Capacity Up to 2,335 alphanumeric characters
Error Correction Reed-Solomon (up to 30%)
Size 10×10 to 144×144 modules
Generate Data Matrix

Data Matrix is a two-dimensional barcode consisting of black and white cells arranged in a square or rectangular pattern. Developed in 1989, it is widely used for marking small items and in industrial settings.

The code can store up to 2,335 alphanumeric characters or 3,116 numeric digits. It uses Reed-Solomon error correction, allowing up to 30% of the code to be damaged while still being readable.

Data Matrix is particularly popular for direct part marking (DPM)—permanently marking components with laser etching, dot peen, or chemical etching. The electronics, automotive, and aerospace industries use it extensively for component traceability.

The United States Electronic Industries Alliance (EIA) recommends Data Matrix for marking small electronic components. It is also used for postal marking, document management, and pharmaceutical packaging (often with GS1 identifiers).

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/datamatrix?data=EXAMPLE123"

PDF417

2D Barcode

Stacked barcode for ID cards and transport

Specifications

Capacity Up to 1,850 alphanumeric characters
Error Correction Reed-Solomon (levels 0-8)
Structure Stacked linear (3-90 rows)
Generate PDF417

PDF417 is a stacked linear barcode format invented by Ynjiun Wang at Symbol Technologies in 1991. The name comes from "Portable Data File" and the fact that each pattern in the code consists of 4 bars and spaces, with each pattern being 17 units long.

Unlike true 2D barcodes, PDF417 is actually a stacked set of linear barcodes. This design allows it to be read by simpler linear scanners, while still providing high data capacity—up to 1,850 alphanumeric characters or 2,710 numeric digits.

PDF417 includes robust error correction using Reed-Solomon codes. The error correction level can be adjusted from 0 to 8, with higher levels providing more redundancy at the cost of barcode size.

Primary applications include government-issued IDs (US driver's licenses, military IDs), airline boarding passes, shipping labels, and inventory management. The International Air Transport Association (IATA) adopted PDF417 for boarding passes in 2005.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/pdf417?data=EXAMPLE123"

Aztec Code

2D Barcode

Space-efficient code for transport tickets

Specifications

Capacity Up to 3,832 numeric or 3,067 alphabetic
Error Correction Reed-Solomon (5-95%)
Quiet Zone Not required
Generate Aztec Code

Aztec Code is a two-dimensional barcode invented by Andrew Longacre Jr. and Robert Hussey at Welch Allyn in 1995. Named for its central finder pattern that resembles an Aztec pyramid from above, it was designed for easy printing and decoding.

Unlike QR codes, Aztec codes don't require a quiet zone (white border) around them. This makes them more space-efficient when printed in tight spaces. They can encode up to 3,832 numeric digits or 3,067 alphabetic characters.

The code uses Reed-Solomon error correction, with configurable redundancy from 5% to 95%. The central bullseye pattern makes it easy for scanners to locate and orient the code, even when printed at small sizes or at angles.

Aztec Code is the standard barcode for electronic ticketing in transportation. Deutsche Bahn (German Railways), Eurostar, and many other rail operators use it for mobile tickets. It is also used in healthcare for patient identification and specimen tracking.

Example API Request
curl -H "X-API-Key: your-key" \
  "https://api.bargen.pro/v1/barcode/aztec?data=EXAMPLE123"

Ready to Start Generating?

Create a free account and start generating barcodes in minutes. No credit card required.