Code 39 Check Digit Calculator with detailed example

How to calculate Code 39 barcode check digit character?



Code 39 Barcode Introduction

What is Code 39 barcode?

Barcode Code 39 is a barcode symbology that can encode uppercase letters (A through Z), digits (0 through 9) and a handful of special characters like the $ sign. You could view the detailed Code 39 barcode introduction at What is Code 39? Code 39 barcode in detail.

Code 39 Check Digit Calculator with example



Code 39 does not include a checksum or check digit by default. For applications requiring enhanced data security, the modulo 43 (MOD43) check character may be used as a check digit.

When a checksum or check digit is included in the Code 39 barcode, the following check character algorithm (MOD43) should be used.

How to calculate Code 39 check digit?

  1. Each data character is assigned a numerical value as shown in Table-1 below
  2. Calculate the sum of the numerical values for all the data characters of a symbol
  3. Divide this sum by 43.
  4. The character whose value (from Table-1) is the remainder from the division in step 3) is used as the check character.

For example, calculate the check character for Code 39 data "CODE 39"

  1. All 7 chars character values are 12, 24, 13, 14, 38, 3 and 9
  2. Sum of the values is 113
  3. Divid by 43: 113/43= 2 with remainder 27
  4. Character value 27 is "R"
  5. The calculated check digit is "R"
  6. The complete Code 39 data with checksum is "CODE 39R"



Table-1: Code 39 numerical character values for modulo 43 check

Character Value Character Value Character Value
0 0 F 15 U 30
1 1 G 16 V 31
2 2 H 17 W 32
3 3 I 18 X 33
4 4 J 19 Y 34
5 5 K 20 Z 35
6 6 L 21 - 36
7 7 M 22 . 37
8 8 N 23 SPACE 38
9 9 O 24 $ 39
A 10 P 25 / 40
B 11 Q 26 + 41
C 12 R 27 % 42
D 13 S 28    
E 14 T 29    










Terms of Use | Privacy Policy
Copyright © OnBarcode.com . All rights reserved.