EAN-13 Check Digit Calculation


Symbol above depicts EAN-13 bar code. Last 13-th digit in this barcode is the check digit (the "5").

As you see in EAN-13 the check digit, a single checksum digit. The check digit is computed modulo 10, where the weights in the checksum calculation alternate 1 and 3. In particular, since the weights are relatively prime to 10 the EAN system will detect all single digit errors. But since the difference of consecutive weights is even, the EAN system does not detect all adjacent transposition errors.

How-to calculate EAN-13 Check Digit