UPC Codes: What They Are and How They Work

Curious about How UPCs Work? Get the Answers Here

Close up of bar codes, studio shot
••• Tetra Images / Getty Images

What Is the Definition of a UPC Barcode?

A UPC code is a barcode symbol that manufacturers in the United States and many other countries use to identify their products electronically so that they can be digitally scanned and tracked. UPC means "Universal Product Code." Each UPC consists of a series of digitally-readable bars plus numbers that people can verify.

UPC codes make it easy to ring up products at a grocery store, track inventory, reorder stock that is running low, print receipts that show the products a customer has purchased, make coupons scannable by computers, and so on.

Although there are other barcode systems, UPCs are the most commonly-used tracking system in United States, Canada, and many other countries.

Technically, the term "UPC code" is incorrect, since you are saying "universal product code code," but many people use it anyway. If you want to be proper, you can simply call it a UPC.

How UPC Codes Work

A UPC code is a 12 digit code displayed in two different ways.

The first is a barcode, which is designed to be easily read by computer scanners. It consists of alternating white and black bars of various widths. Each numeral from zero to nine corresponds to a specific pattern of bars.

For example, a one would be written as three bars each two lengths wide followed by a bar one length wide. Remember that you need to consider both the white and black bars when deciphering the code.

The barcode starts and ends with a black bar, a white bar, and a black bar, each one unit in width. These are called the start code and the end code. Between the start and end codes, you'll find the bars indicating the numbers in the code.

The second part of a UPC code is a plain-text version of the number, which is printed near the barcode so that humans can read it easily. This is useful, for example, when a scanner isn't working properly and a cashier needs to enter the code by hand. The plain-text number is much faster for the cashier to type than trying to decipher the code would be, and having it there reduces the chance of making a mistake when keying in the product information by hand.

Why Do UPC Codes Have 12 Numbers?

The 12-digit UPC code is actually three groups of numbers with different purposes. In a product UPC, the first six numbers indicate the manufacturer, the next five digits are an item number, and the final number is the check digit.

The manufacturer's section of the UPC is technically called the UPC Company Prefix. It is assigned to the manufacturer when they apply for a UPC barcode. The UPC code for every item that the manufacturer sells will start with this number.

The item number is assigned to each individual product by the manufacturer. For example, the item numbers for a 6-pack of strawberry yogurt, a single container of strawberry yogurt, and a single blueberry yogurt from the same manufacturer would all be different from one another.

The check digit is there to help ensure that the right number has been scanned or hand-entered. To check whether the correct numbers are in the code, add up all of the odd digits in the code and multiply the result by three. Then add up all of the even digits and add them to the result. The amount you would need to add to that amount to reach a multiple of ten should match the check digit. If not, something has gone wrong.

If that seems complicated, you can also use a check sum calculator to verify your UPC without having to do a lot of math.

Coupons also have UPC codes which can be scanned to check whether the coupon is being used with the right product, to track when and where coupons are being used, and to verify that the coupon is still valid. Coupon UPCs generally start with the digit 5. Read more from TheBalance's Couponing Expert: How to Read Coupon UPCs.

Why Are UPCs Sometimes Shorter Than 12 Digits?

In order to be able to print UPC barcodes on smaller packages, there is a way of compressing the zeros in a UPC to save space, which results in barcodes with less than 12 digits. You can read more about zero-compressed numbers from How Things Work.

What Is Not Included in UPC Codes

A UPC Code does not carry any price information. When the code is scanned, a store's computer will check that product against the current price stored in its database to determine the cost of the product. Otherwise, a new UPC code would have to be printed every time a price was changed and the manufacturer would also have to know the price the stores wanted to set. That would be a nightmare to track!

UPC codes also don't carry information about where a product was manufactured, despite various viral emails and social media posts claiming otherwise. You can't look at certain numbers of a UPC code and determine that the product was made in China or other countries. EIN numbers commonly used in Europe may contain this information.

UPC Codes and Sweepstakes

Companies sometimes require a UPC Code from one of their products in order to enter sweepstakes. However, this does not mean you have to buy the product to enter. Remember that it's not generally legal to require a purchase to enter randomly-drawn sweepstakes, and here's why

There are several ways to enter these sweepstakes without having to buy anything. See How to Find Free UPC Codes for more information about entering these kinds of sweepstakes without purchase.