Guide · Jul 10, 2026 · Updated Sep 28, 2026

UPC vs EAN vs Code128: Which Barcode Format Do You Actually Need?

Dozens of barcode formats exist for specialized industries, but the overwhelming majority of everyday needs — retail products, internal inventory, asset tags, shipping labels — are covered by three: UPC-A, EAN-13, and Code128. They're not interchangeable, and picking the wrong one is a common source of "why won't this scan at checkout" problems.

UPC-A: the 12-digit US retail standard

UPC-A is a fixed 12-digit format, and it's what you'll find on the overwhelming majority of retail products sold in the US and Canada. The first several digits identify the manufacturer (assigned by GS1, the organization that administers barcode number ranges), the next few identify the specific product, and the final digit is a checksum calculated from the others — it exists specifically to catch a mistyped or misread digit, not to encode any additional information.

EAN-13: the international equivalent

EAN-13 is UPC-A's international counterpart — 13 digits instead of 12, used across most of the world outside North America. The extra digit at the front is typically a country or region prefix. In practice, a UPC-A code can be represented as EAN-13 by adding a leading zero, which is why most point-of-sale systems and barcode scanners handle both formats interchangeably without any special configuration.

The part that actually matters: these numbers have to be registered

This is the detail that trips people up most: generating a syntactically valid UPC-A or EAN-13 barcode is trivial — any barcode generator can produce one from 12 or 13 digits. But the number itself is supposed to be assigned to you specifically through GS1, so that it doesn't collide with another company's product using the same digits. If you're planning to sell a physical product through a retailer or major marketplace, you generally need a real, registered GS1 prefix — a barcode generator handles turning that number into a scannable image, but it doesn't grant or verify ownership of the underlying number.

Code128: for everything that isn't a retail product number

Code128 works completely differently — instead of a fixed digit count tied to a registration scheme, it can encode any alphanumeric string of essentially any reasonable length. There's no GS1 registration involved, no fixed format, and no assumption that the code represents a retail product at all. This makes it the right default for internal use: warehouse bin locations, asset tags, employee badges, internal SKUs, ticket numbers — anything you're generating and consuming entirely within your own systems, where there's no external registry to coordinate with.

How to tell a UPC-A from a Code128 just by looking

You can usually tell them apart at a glance, before any scanner is involved. Four things give it away:

When the printed text is missing or you need to be certain, let a scanner tell you. Most phone barcode apps show the symbology name next to the decoded value. Many handheld scanners can also be set to prefix each scan with an AIM symbology identifier: ]E0 for EAN/UPC, ]C0 for Code128, and ]C1 for GS1-128.

"EAN-128" isn't a kind of EAN — it's GS1-128

The name causes a lot of confusion. EAN-128 (also called UCC-128 or UCC/EAN-128) is the old name for what is now GS1-128. It has nothing to do with EAN-13's structure. It is Code128 with two extra rules: the barcode starts with a special FNC1 character right after the start pattern, and the data is written as Application Identifiers (AIs). Each AI is a short numeric prefix that says what the next field means:

The parentheses are only printed for humans; they are never encoded in the bars. Printed, a GS1-128 is indistinguishable from any other Code128, and only the FNC1 at the front tells a scanner it's structured GS1 data.

So "EAN-128 or UPC?" isn't a choice between two equivalent options. They go on different things. UPC-A or EAN-13 goes on the item that crosses the checkout counter. GS1-128 goes on the carton or pallet that item ships in, and it usually contains the product's GTIN inside its (01) field, alongside the lot and expiry data a warehouse needs. A retailer that asks for "UCC-128 labels" is talking about your shipping cartons, not your product packaging.

Which formats are similar to Code128?

If you're searching for alternatives, they fall into two families. The first family is the variable-length "internal" symbologies, which Code128 belongs to:

Code128 is usually the best of the first family because it has three internal character sets. Set C packs two digits into each symbol, so a long all-numeric code comes out far more compact than it would in Code 39.

The second family is UPC-A's own siblings, not Code128's. UPC-E is a zero-suppressed 8-digit form for small packages, and EAN-8 is the short international equivalent. Both are fixed-length retail formats that stay inside the GS1 numbering system.

UPC or Code128 for a small shop's inventory?

This is where most small retailers get stuck, and the answer depends on where each item came from:

One practical check before printing a few hundred Code128 labels for the sales floor: most POS scanners can read Code128, but the POS software also has to accept that value as an item lookup, and some setups only match UPC/EAN-length numbers. Print one label, scan it at the register, and confirm it pulls up the item. If anything will leave your store — wholesale, Amazon, another retailer — it needs a real GS1-assigned number, not an in-store one.

A quick way to decide

If the code is a real retail product number assigned through GS1, use UPC-A (US/Canada) or EAN-13 (elsewhere) to match the number's actual format. If you're numbering something internal — inventory, assets, tickets — and there's no registration authority involved, Code128 is almost always the simpler, more flexible choice, since it isn't constrained to digits-only or a fixed length.

Generate them

FreeToolDev's bulk barcode generator makes up to 100 UPC-A, EAN-13, or Code128 barcodes at a time from a pasted list, and downloads them as a ZIP. UPC-A and EAN-13 codes are validated against their check digit before rendering, so a mistyped digit gets flagged — with the digit it should have been — rather than silently producing a barcode that fails to scan. If your list is missing check digits (12-digit EANs straight out of a spreadsheet), switch the check-digit option to calculate them. It doesn't produce GS1-128. Its Code128 output has no FNC1, so use GS1-aware label software for carton labels.