Why there are so many formats
A linear code stores data in the width of its bars: the more characters, the longer the code. So each format has its own alphabet and its own job: a thirteen-digit product number is one thing, a serial number with letters and dashes another.
Formats differ in three ways: the character set (digits only or full ASCII), how errors are caught (a mandatory check digit or none) and density. The denser the code, the thinner the bars and the higher the demands on printing.
Retail codes: EAN-13, EAN-8, UPC-A
EAN-13 is the retail standard almost everywhere except the US and Canada, where UPC-A rules. Its thirteen digits split into a prefix for country or registration, a manufacturer number and an item number, and the last digit is a check digit computed from the first twelve.
EAN-8 exists where packaging has no room: small boxes, sticks, cosmetics. UPC-A is the same idea with twelve digits for the American market; modern scanners read both, but a US till expects UPC.
Important: the barcode does not contain a price. It encodes only an identifier, and the till looks the price up in its own database. You cannot "change the price in the barcode" — and you do not need to.
Warehouse and logistics: Code 128, Code 39, ITF-14
Code 128 is the most compact of the common formats: it encodes all of ASCII, including lowercase and control characters, which makes it the choice for serial numbers, addresses and internal SKUs. It has a mandatory checksum and variable length.
Code 39 is old and very forgiving of print quality: uppercase letters, digits and a few symbols only, but it reads even from a cheap printer and is easy to check by eye. You often see it on inventory labels.
ITF-14 is the carton code: fourteen digits, wide bars, built for reading at a distance and in dirty conditions. It is never used at the point of sale — it lives at the packaging and warehouse level.
Special formats
Codabar shows up in libraries, blood banks and older record systems: digits and a few symbols, a very simple structure. Code 93 is a denser relative of Code 39, found in industry.
MSI serves warehouses and inventory in some sectors, digits only. Pharmacode is for pharmacy packaging: a small numeric code read not by tills but by pharmaceutical lines.
The short rule: retail goods get EAN-13 or UPC depending on the country. Internal tracking gets Code 128 or Code 39. Cartons on a pallet get ITF-14. Everything else exists because a specific system demands it.












