"Barcode" is not a single thing. It's an umbrella term for dozens of different symbologies—each with its own rules about what characters it can encode, how long it can be, and where it's meant to be scanned. Pick the wrong one and your codes may be rejected by a retailer, fail to scan at a warehouse, or simply not fit on the label.
This guide walks through the barcode types you'll actually encounter, grouped by where they're used, so you can confidently answer the only question that matters: which barcode should I use? When you've decided, you can create any of them in seconds with our free barcode generator.
1D vs 2D Barcodes (and where we focus)
Barcodes fall into two broad families:
- 1D (linear) barcodes — the familiar pattern of parallel black bars and white spaces. UPC, EAN, Code 128, and Code 39 are all 1D. They encode data along a single horizontal axis.
- 2D barcodes — patterns like QR codes and Data Matrix that store data in two dimensions, packing far more information into a small area.
The vast majority of retail, publishing, and logistics work runs on 1D barcodes, and that's what this guide—and our generator—focuses on. Below, the types are grouped by the job they do.
Retail & Consumer Product Barcodes
If your product sells in a store or on a marketplace, it needs a GTIN (Global Trade Item Number) encoded in one of these retail symbologies. These are the most regulated barcode types because they have to scan reliably at any checkout in the world.
UPC-A
The classic 12-digit barcode used across North America. If you've scanned groceries in the US or Canada, you've used UPC-A. It encodes a number-system digit, a manufacturer code, a product code, and a check digit.
012345678905EAN-13
The international equivalent of UPC-A, using 13 digits. The leading digits identify the country/numbering authority. A UPC-A code is actually just an EAN-13 with a leading zero—which is why a 12-digit UPC and its 13-digit EAN form are interchangeable in most databases. We break this relationship down in detail in UPC vs EAN Barcodes: Understanding the Difference.
5901234123457UPC-E
A compressed, 8-digit version of UPC-A that suppresses zeros to fit on small packages like gum, cosmetics, or single-serve items. It expands back to a full UPC-A when scanned.
01234565EAN-8
The short-form EAN, also 8 digits, used for small products where a full EAN-13 won't fit.
96385074EAN-2 & EAN-5 (supplements)
These short add-on codes never appear alone—they sit beside a main EAN-13. EAN-2 indicates an issue number for magazines and periodicals; EAN-5 usually encodes a suggested retail price (common on books, where it carries the price next to the ISBN).
EAN-2 —
05EAN-5 —
52495Already have a retail code? You can look up any UPC or EAN instantly to confirm what product it's registered to before you print or list it. For browsing by manufacturer, see our UPC prefix directory and EAN prefix directory.
Book & Publishing Barcodes
ISBN (Bookland EAN-13)
Books use a specialized EAN-13 that begins with the "978" or "979" Bookland prefix and encodes the ISBN (International Standard Book Number). In retail, the ISBN barcode is frequently printed alongside an EAN-5 price supplement, giving you the familiar two-part barcode on the back of a paperback.
978-0-14-044913-6If you work with books at any volume, our ISBN database lookup guide covers how to retrieve titles, authors, page counts, and publish dates from ISBNs at scale.
Logistics & Shipping Barcodes
These symbologies identify cases, cartons, and pallets rather than individual retail units. They're built for tough warehouse environments and high-speed scanning.
ITF-14
The standard for shipping cartons and cases. ITF-14 encodes a 14-digit GTIN and is printed with a heavy "bearer bar" frame that protects scan accuracy on corrugated cardboard. If you ship cases of product to a distributor or retailer's warehouse, this is usually the code on the outer box.
15400141288763Interleaved 2 of 5 (ITF)
A compact, numeric-only symbology that encodes pairs of digits efficiently. ITF-14 is a constrained version of it. Used widely in warehousing and distribution where only numbers need to be encoded.
1234567890Code 25 (Standard 2 of 5)
An older, lower-density numeric symbology still found in industrial settings, airline ticketing, and some inventory systems. Largely superseded by Interleaved 2 of 5 and Code 128 for new applications.
1234567890Industrial & General-Purpose Barcodes
When you're encoding internal data—asset tags, work orders, batch numbers, internal SKUs—you're not bound by retail rules and can choose a flexible symbology.
Code 128
The workhorse of non-retail barcoding. Code 128 is high-density and can encode the full ASCII character set—letters, numbers, and symbols—in a compact space. It's the default choice for shipping labels (including the GS1-128 variant), inventory, and asset tracking. If you need to encode a mix of letters and numbers and want the smallest possible barcode, choose Code 128.
ABC-12345Code 39
An older alphanumeric symbology (uppercase letters, digits, and a few symbols). It's less dense than Code 128 but extremely well supported by legacy scanners and is still common in automotive, defense, and government applications. Choose Code 39 only when a system specifically requires it; otherwise Code 128 is more efficient.
HELLO2025Codabar
A self-checking numeric symbology with a long history in libraries, blood banks, and FedEx airbills. It can be printed by simple equipment, which is why it persisted in older industries.
A31117013206375BPostal Barcodes
POSTNET & PLANET
These US Postal Service symbologies encode delivery-point and tracking information using tall and short bars rather than the bar-width pattern of other codes. POSTNET encodes ZIP routing data, while PLANET was used for mail tracking. They're niche, but if you're preparing bulk mail you may need them.
POSTNET —
012345678PLANET —
01234567890Quick Comparison: Which Barcode Encodes What?
| Barcode Type | Encodes | Length | Best For |
|---|---|---|---|
| UPC-A | Digits only | 12 (fixed) | Retail products (North America) |
| EAN-13 | Digits only | 13 (fixed) | Retail products (international) |
| UPC-E / EAN-8 | Digits only | 8 (fixed) | Small retail packages |
| ISBN (Bookland) | Digits only | 13 (+5 price) | Books & publications |
| ITF-14 | Digits only | 14 (fixed) | Shipping cases & cartons |
| Code 128 | Full ASCII | Variable | Logistics, inventory, asset tags |
| Code 39 | A–Z, 0–9, symbols | Variable | Legacy/industrial systems |
| Codabar | Digits + a few symbols | Variable | Libraries, blood banks |
| POSTNET / PLANET | Digits only | Fixed | US postal routing |
Which Barcode Type Should You Use?
Cut through the options with these rules of thumb:
- Selling a product in stores or on Amazon, Walmart, or eBay? You need a retail GTIN as UPC-A (North America) or EAN-13 (elsewhere). Source the number from GS1, then render the barcode.
- Publishing a book? Use an ISBN barcode, optionally with an EAN-5 price add-on.
- Shipping cases or pallets? Use ITF-14 on the carton.
- Tracking internal inventory, assets, or work orders? Use Code 128—it's compact and handles letters and numbers. Fall back to Code 39 only if a downstream system demands it.
- Working with a legacy system? Match whatever symbology it already expects (often Code 39 or Codabar).
Once you know the type you need, our free barcode generator creates all of the symbologies above—UPC-A, EAN-13, EAN-8, UPC-E, ISBN (with EAN-5 price supplement), Code 128, Code 39, ITF-14, Interleaved 2 of 5, Codabar, EAN-2, EAN-5, POSTNET, and PLANET—and lets you download them as PNG, JPEG, SVG, PDF, or EPS ready for print or web.
Generating vs. Buying a Barcode Number
One common point of confusion: there's a difference between the barcode image and the number inside it.
- For retail GTINs (UPC/EAN/ISBN), the number must be a legitimate, unique identifier—typically licensed from GS1—so retailers can trace it to you as the brand owner. Our generator turns that number into a scannable barcode image; it doesn't issue the GTIN itself.
- For internal-use barcodes (Code 128, Code 39, Codabar), you can make up the encoded value yourself—there's no central registry, so generate away.
Verify Before You Print
Before committing a retail barcode to thousands of labels, confirm it's valid and unclaimed:
- Look up the UPC or EAN on our homepage to see whether it's already registered to a product.
- Have a long list to check? Our bulk barcode lookup processes spreadsheets of codes at once.
- Building software? Pull product data programmatically with the Barcode API (see the API documentation for endpoints and examples).
- Have product data we're missing? You can submit a barcode to add it to our database.
Frequently Asked Questions
What's the difference between UPC and EAN?
UPC-A is a 12-digit code used mainly in North America; EAN-13 is its 13-digit international superset. A UPC is simply an EAN-13 with a leading zero, so the two are interchangeable in most lookup systems. Full breakdown in our UPC vs EAN guide.
Is Code 128 better than Code 39?
For most new applications, yes. Code 128 is denser (smaller barcode for the same data) and encodes the full ASCII set. Code 39 is older and bulkier but is still required by some legacy and government systems, so use it when a specific workflow calls for it.
Which barcode does Amazon require?
Amazon listings use a GTIN—usually a UPC or EAN—and require GS1-issued codes for new listings. For FBA, units are additionally labeled with Amazon's own FNSKU barcode. The underlying retail symbology is still UPC-A or EAN-13.
Do I need to pay for a barcode?
You pay to license the GTIN number for retail products (from GS1), not to generate the image. Generating the barcode picture from a number you already own is free with our barcode generator. Internal-use symbologies like Code 128 require no license at all.
Can one product have both a UPC and an EAN barcode?
Effectively yes—because a UPC-A is the same number as its EAN-13 form with a leading zero. You typically print one or the other depending on your market, but lookups resolve to the same product either way.
Put It Into Practice
Knowing the symbologies is half the battle; the other half is execution. Decide which type fits your use case using the rules above, verify any existing code against our database, and then generate a print-ready barcode in the format you need. For deeper dives, browse the rest of our barcode guides—including the Ultimate Guide to UPC Lookup and our e-commerce barcode playbook.