An EAN-13 check digit
- Input
- 590123412345
- Output
- 5901234123457
The thirteenth digit is derived from the first twelve by a weighted sum. A wrong check digit means scanners either reject the code or read a different product.
This tool draws standard retail and logistics barcodes in your browser. Each symbology has its own rules about what it can encode and how long the input must be, and most have a check digit computed from the other digits — get that wrong and the barcode scans as a different product entirely. Those rules are enforced here rather than left for a scanner to discover.
Runs entirely in your browser — nothing you paste is uploaded.
Accepts: 12 digits (the 13th is calculated) or 13 to verify
Check digit 7 will be appended, making 5901234123457.
How to
EAN-13 for retail products outside North America, UPC-A within it, and Code 128 for internal or logistics use where you need letters as well as digits.
The required length and allowed characters are shown for the format you picked, and the input is checked as you type.
For EAN and UPC the final digit is derived from the others. Enter the shorter number and it is computed, or enter the full code and it is verified.
SVG for print, since a barcode must be crisp to scan. PNG for screens and documents.
Examples
The thirteenth digit is derived from the first twelve by a weighted sum. A wrong check digit means scanners either reject the code or read a different product.
Code 128 encodes the full ASCII set and has no fixed length, which is why it is the usual choice for internal part numbers and shipping labels.
Fixed-length symbologies cannot encode arbitrary input. Reporting this immediately is better than producing an image that no scanner will read.
Why use it
The digit is calculated from your data or verified against it, which removes the most common cause of a barcode that scans as the wrong product.
Length and character set are validated per symbology, so you find out about a problem here rather than after printing a thousand labels.
SVG keeps the bars perfectly crisp at any size, which matters because a slightly soft barcode is a barcode that fails to scan.
Product codes and shipping references are drawn locally and never uploaded.
Good to know
Summary
FAQ
Discover