Guides

Barcode Types Compared: UPC, EAN, Code 128 & QR

← Guides

UPC, EAN, Code 128 & QR: Which Barcode Type for What?

An overview of the most important barcode types: where they’re used, what data they hold and what to watch for when you scan them.

“Barcode” is an umbrella term for very different patterns that carry machine-readable data. Which format ends up on a product depends on what the code needs to do: identify an item uniquely, store more data or be especially rugged. Here are the barcode types you’ll run into most often.

UPC-A and UPC-E: the standard in US retail

UPC (Universal Product Code) is the barcode you’ll find on practically every packaged product in US and Canadian stores: grocery, drugstore, hardware, books and more. UPC-A has 12 digits: a company prefix assigned by GS1 US, an item reference and a check digit. UPC-E is the compressed 8-digit version for small packages such as soda cans or candy bars, where a full UPC-A won’t fit.

Officially, a UPC is a GTIN-12 (Global Trade Item Number). If you sell products in US retail or on marketplaces like Amazon, you’ll need UPCs, and GS1 US is the organization that issues the company prefixes.

Where you need it: Retail inventory counts, e-commerce receiving, and any kind of item identification on product packaging.

EAN-13 and EAN-8: the international counterpart

EAN (originally European Article Number, now officially GTIN-13) is the 13-digit standard used in most of the world outside North America. You’ll see it on imported goods. Technically, EAN-13 and UPC-A are closely related: every UPC-A code becomes an EAN-13 by adding a leading zero. The first digits identify the GS1 member organization that issued the prefix (000–139 for the US and Canada, 400–440 for Germany, for example). EAN-8 is the short version for very small packages.

Where you need it: When you sell or handle imported goods. Any good scanner app reads UPC and EAN equally well.

Code 128: the all-rounder for logistics and custom labels

Code 128 is a flexible format that can encode digits as well as letters and special characters. You’ll recognize it by its fairly dense, compact bar pattern. In logistics, Code 128 is used on shipping labels from UPS, FedEx and USPS. SSCC codes (Serial Shipping Container Codes) on pallets also commonly use this format, as GS1-128.

Where you need it: Warehouse receiving, shipping, and custom labels for internal SKUs. Amazon FBA FNSKU labels are based on Code 128, too.

Code 39: the classic for asset tags

Code 39 is older and less compact than Code 128, but very rugged and easy to print. It encodes digits, uppercase letters and a few special characters. Whenever you see asset tags on tools, laptops or office furniture, there’s a good chance they’re Code 39. It’s also still common in the automotive industry and in libraries.

Where you need it: IT asset inventory, tool tracking, library collections.

QR code and Data Matrix: when you need to store more data

Both are 2D codes that hold far more information than a classic linear barcode: full URLs, short texts, configuration data. QR codes are everywhere in marketing, on restaurant menus and in ticketing systems. Data Matrix looks more inconspicuous (often only a few millimeters across) and is used on electronic components, for drug serialization in pharma, and on surgical instruments.

Where you need it: Tickets, pharma track & trace, maintenance records for machinery, marketing campaigns.

PDF417 and Aztec: specialty formats

PDF417 looks like a long, stacked barcode. You’ll find it on boarding passes and on the back of US driver’s licenses and state IDs. Aztec codes are square and are used mainly on airline and rail tickets.

Which barcode is scanned in which industry?

  • Retail & grocery: UPC-A, UPC-E, EAN-13
  • Shipping & logistics: Code 128, SSCC (GS1-128)
  • Bookstores & libraries: EAN-13 (ISBN), Code 39
  • IT & asset inventory: Code 39, Code 128, QR
  • Events & tickets: QR, Aztec, PDF417
  • Pharma: Data Matrix
  • Rail & air travel: Aztec, PDF417 (boarding passes)

A good multi-format barcode scanner app like Scan2List: Inventory Scanner detects all of these codes automatically, without you having to pick the format first. So if you’re not sure which code you’re looking at, just take a photo and let the app figure it out.


Scan2List scans every format mentioned here from a photo, even several at once.

More on individual formats: EAN-13 explained · Code 128 explained · SSCC explained · FNSKU for Amazon FBA

Last updated:

Note: We put this guide together with care, but it is not legal or tax advice and is not legally binding. Deadlines, obligations, prices and calculation methods change. Please verify any information yourself or with your accountant before relying on it.

Free template

Set up the list on your computer, check it with your iPhone

Download a free CSV template, create labels in the generator for everything without a barcode and load the list into the app. Then you see right away what is missing when you take photos.

More guides

All guides ›