Specifications | Ean 13 symbology specification
Sunday February 26 2017
Google

EAN 13 BARCODE

Format of the EAN 13

Length Type checksum
13 digits numeric yes

The EAN 13 is composed by 12 data digits + 1 checksum digit.


Calculating the EAN 13 checksum

Calculating the EAN 13 checksum digit is very simple :

EAN 13 checksum formula :

( 10 - [ (3 * Odd + Even) modulo 10 ] ) modulo 10

Thus, the example :

So the checksum of 210987654321 is 0

EAN 13 checksum generator :

EAN 13 message : Checksum :

Binary sequence of EAN 13 barcode

Start

A start sequence starts the barcode : 101

The 13 digits will be separated into 2 parts, namely the left part from the 1st au 7th digit and the right part from the 8th au 13th digit

Part #1

The first part is encoded according to the following table :

digitsequence
0000000
1001011
2001101
3001110
4010011
5011001
6011100
7010101
8010110
9011010

Thus for each bit of the first digit, a sequence of 6 "0" or "1" will be used to encode the 6 next digits according to the following tables :

digittable 0table 1
000011010100111
100110010110011
200100110011011
301111010100001
401000110011101
501100010111001
601011110000101
701110110010001
801101110001001
900010110010111

For example, the first digit is 2, the tables used for the digit 2 to 7 will be defined by the sequence 001101:

Part #1 will be0011001 0001101 0010111 0001001 0111011 0000101

Intermediate

An intermediate sequence separate the 2 parts : 01010

Part #2

The second part is encoded according to the following table :

digittable 2
01110010
11100110
21101100
31000010
41011100
51001110
61010000
71000100
81001000
91110100

Part #2 will be 1001110 1011100 1000010 1101100 1100110 1110010

Stop

A stop sequence ends the barcode : 101

Summary of the sequence of the EAN 13

Graphical representation of the EAN 13 barcode

Each element of the binary sequence is represented by a space of equal width, it is a "1" or "0". The "1" are represented by spaces filled and "0" with empty spaces.

Online EAN 13 barcode generator

Please fill in the code :