Retail product numbering

EAN-13 barcode generator

Create a scannable EAN-13 symbol from a legitimate product number. Enter 12 digits to calculate the final check digit, or validate an existing 13-digit value.

Loading EAN-13 encoder…

How the 12- and 13-digit modes work

EAN-13 uses twelve data digits followed by one mathematical check digit. If you enter 400638133393, this tool calculates 1 and encodes 4006381333931. If you supply all thirteen digits, generation stops when the checksum is wrong.

  • 12 digits: calculate and append the check digit
  • 13 digits: verify the supplied check digit
  • Anything else: show an error without generating a symbol

EAN-13 does not assign a product number

A valid checksum only proves that the digits are internally consistent. It does not register a brand, allocate a company prefix, or guarantee that the number belongs to your product. Use a number issued through the appropriate GS1 organization for retail distribution.

  • Keep the left and right quiet zones unobstructed.
  • Do not stretch or crop the bars after download.
  • Verify a proof with the scanner used at your point of sale.

EAN-13 barcode generator FAQ

How is the EAN-13 check digit calculated?

The first twelve digits are weighted alternately by 1 and 3. The check digit makes the total a multiple of ten.

Can I invent any 12-digit number?

The tool can encode it, but retail identifiers should be allocated to your organization and product through GS1. Checksum validity is not ownership.

Why does a 13-digit value fail?

Its last digit does not match the checksum calculated from the first twelve. The error message shows the expected final digit.

Should I include spaces or hyphens?

No. EAN-13 input is exactly 12 or 13 digits. Human-readable grouping is not part of the encoded product number.