Skip to main content
Check Digit Calculator
GS1

GTIN-12 / UPC-A Calculator

Calculate the twelfth digit of a GTIN-12 or UPC-A barcode. See the odd-position weighting and the sum needed for a complete code.

Last updated:

GS1 & Retail Barcodes

Complete twelve-digit product identifiers.

Length: 11 chars
Calculated Check Character / Checksum
--Ready
Complete Validated Sequence:
--
Arithmetic Steps & Mathematical Specification

Initialising algorithm engine for GTIN-12 / UPC-A Calculator...

How GTIN-12 / UPC-A Calculator Works?

The GTIN-12 / UPC-A Calculator works by multiplying the 6 odd-position digits by 3, adding the 5 even-position digits, and appending the digit that brings the total to a multiple of 10.

  1. 1Enter the 11-digit payload (number system digit, company prefix, and item reference).
  2. 2Add the digits in positions 1, 3, 5, 7, 9, and 11 and multiply the result by 3.
  3. 3Add the digits in positions 2, 4, 6, 8, and 10.
  4. 4Add both results to get S.
  5. 5Compute the 12th digit as (10 − (S mod 10)) mod 10.

GTIN-12 / UPC-A Calculator Formula

The UPC-A formula is d₁₂ = (10 − ((3 × odd-position sum + even-position sum) mod 10)) mod 10.

S = 3 × (d₁ + d₃ + d₅ + d₇ + d₉ + d₁₁) + (d₂ + d₄ + d₆ + d₈ + d₁₀)
d₁₂ = (10 − (S mod 10)) mod 10
  • d₁…d₁₁ are the payload digits from the left.
  • d₁₂ is the UPC-A check digit.
Worked example: 03600029145
Payload:  03600029145
Weights:  31313131313
S = 58
Check digit = (10 − (58 mod 10)) mod 10 = 2
UPC-A = 036000291452

GTIN-12 / UPC-A Calculator Conversion Table

The GTIN-12 conversion table maps 11-digit payloads to complete UPC-A codes and their EAN-13 equivalents.

Payload (11 digits)Check digitUPC-AEAN-13 equivalentGTIN-14 format
036000291452036000291452003600029145200036000291452
012345678905012345678905001234567890500012345678905
042100005264042100005264004210000526400042100005264
074470111412074470111412007447011141200074470111412
885432045023885432045023088543204502300885432045023
192027020014192027020014019202702001400192027020014

What is GTIN-12 / UPC-A Calculator?

A GTIN-12 / UPC-A Calculator is a tool that computes the 12th digit of a Universal Product Code (UPC-A). UPC-A is the standard retail barcode in the United States and Canada.

A UPC-A becomes a valid EAN-13 by adding a leading zero, and the check digit stays the same. The first digit of a UPC-A is the number system digit: 0, 1, 6, 7, 8 for regular items, 2 for variable-weight items, 3 for drugs, and 5 for coupons.

What are the uses of GTIN-12 / UPC-A Calculator?

There are 4 main uses of the GTIN-12 / UPC-A Calculator, including US retail packaging, EAN conversion, and point-of-sale testing.

  • US and Canadian retail packaging: Manufacturers complete UPC-A codes before printing labels.
  • EAN-13 conversion: Exporters prefix a 0 to sell UPC-labelled goods in EAN markets.
  • Point-of-sale testing: Retail IT teams create valid test UPCs for scanner trials.
  • Catalogue validation: Distributors flag invalid UPCs in product feeds.