If the can has a printed date after BEST BY or BEST IF USED BY, that's the one to go by. It's a quality date. The other string of letters and numbers is a packing code. USDA says cans must carry one so the manufacturer can track the product, that it “might refer to the date or time of manufacture,” and that it isn't meant to be read as a use-by date.
There's no universal decoder: each company writes its own. Many codes do contain a Julian day of the year, which you can convert, and a few manufacturers explain their codes online. Unopened, USDA gives high-acid canned foods 12–18 months and low-acid foods 2–5 years for best quality.
A date and a code
Look at both ends of the can and the label seam. You'll usually find one or both of these:
The first two are open dates, printed for you. The third is an illustrative packing code, printed for the manufacturer. FSIS describes codes as “a series of letters and/or numbers” that let companies rotate stock and find their products in a recall. Many cans carry both on the same end, one above the other.
Campbell's, for example, says its “Best Used By” date is printed on the end of cans. Where there is a readable date, the guide to date formats covers every way it can be printed, including the month-and-year-only dates common on canned goods.
Common patterns inside a code
Codes vary by company and even by plant, so treat these as patterns to test, not rules. The examples are illustrative, not any particular brand's format.
| Pattern | Example | Could mean | Watch out for |
|---|---|---|---|
| YDDD | 6263 | Year ending in 6, day 263: September 20, 2026 (or 2016) | One year digit repeats every 10 years |
| YYDDD | 26263 | 2026, day 263: September 20, 2026 | Easy to confuse with DDDYY; check which part looks like a recent year |
| DDDYY | 26326 | Day 263 of 2026 | Read as YYDDD it would be 2026, day 326 (November 22) |
| YYYYDDD | 2026263 | 2026, day 263 | Rare on cans, common on other packaging |
| Letters | L2, A, PL04 | Production line, shift or plant | Not part of the date |
| Time | 1432 | Packed at 2:32 PM | Four digits under 2400 are often a time |
Those Julian dates are almost always production dates. To estimate a best-by from one, you need to know the product's shelf life, which only the manufacturer can tell you for certain.
How to spot a Julian date in a code
- Look for a run of three digits between 001 and 365 (366 in a leap year). Anything over 366 can't be a day of the year.
- Check the digits right before or after it for a year: one digit (
6for 2026) or two (26). The year should be recent. A can on a store shelf wasn't packed in the future. - If the can also has a best-by date, the Julian date should fall before it, usually by many months or a few years. If it lands after the best-by date, you've picked the wrong digits.
- Convert the candidate with the Julian date converter, which handles YDDD, YYDDD, DDDYY and full-year codes, or look it up on the day-of-year calendar.
If none of that works, the code may not contain a date at all, or it may be encoded in a way only the company can read. Call the number on the label.
Manufacturers that explain their codes
Few companies publish their formats, and the ones that do describe only their own products. Two we checked in September 2026:
- The Neil Jones Food Company, which packs tomato products and Northwest fruit, explains that the last five digits of its eight-character can code are a three-digit Julian pack date followed by a two-digit year, and walks through adding the product's shelf life to get a best-by date.
- Campbell's FAQ says where its “Best Used By” date is printed on cans, bowls, jars and pouches.
For any other brand, the phone number or website on the label is the reliable route. Store brands are often packed by a contract packer, so the store's customer service line is where to start.
How long canned food keeps
| Type | Examples | Unopened, for best quality | Opened, in the fridge |
|---|---|---|---|
| High-acid | Tomatoes, fruit juices, pineapple, apples, peaches, pears, berries, pickles, sauerkraut | 12–18 months | 5–7 days |
| Low-acid | Canned meat and poultry, stews, soups (except tomato), pasta products, potatoes, corn, carrots, beans, peas | 2–5 years | 3–4 days |
These times assume cans in good condition, kept somewhere cool, clean and dry. FSIS warns against storing cans above or beside the stove, under the sink, in a damp garage or basement, or anywhere with temperature extremes. High-acid foods run shorter because acid slowly reacts with the can, which changes taste and texture over time. After opening, move leftovers to a covered glass or plastic container for best quality.
A pantry full of cans hides its oldest ones. Scan the best-by date as you shelve each can and FreshScan lists them soonest first, with a reminder before any date arrives.
Dented, bulging and rusted cans
The can itself tells you more about safety than the code does. USDA's guidance:
- Small dent, can otherwise fine: the food should be safe.
- Deep dent (one you can lay your finger into), sharp dent, or any dent on the top or side seam: throw it out. Seam damage can let bacteria in.
- Bulging, swollen or leaking: throw it out, including cans that froze and swelled.
- Heavy rust: throw it out; it can leave tiny holes. Surface rust that wipes off with your finger or a paper towel isn't serious.
- On opening: liquid that spurts out, a foul odor, or cloudy liquid that should be clear are warning signs of botulism.
Questions people ask
Is there a universal decoder for can codes?
No. Each manufacturer sets its own packing code format. USDA's Food Safety and Inspection Service says there is no book or website that translates the codes into dates, and suggests contacting the manufacturer. Some companies publish how to read their own codes.
Is canned food safe after the best-by date?
A best-by date on a can is a quality date. USDA says high-acid canned foods keep their best quality 12 to 18 months and low-acid canned foods 2 to 5 years, when the cans are in good condition and stored in a cool, clean, dry place. Don't use cans that are bulging, leaking, badly dented or heavily rusted, or food that spurts, foams or smells off when opened.
Does the code on the can tell me when it expires?
Usually not directly. A packing code, if it contains a date at all, usually marks when the can was produced. To estimate quality, add the typical shelf life for that kind of food, or look for a separate best-by date on the can or label.
Is it safe to eat from a dented can?
USDA says food from a can with a small dent that's otherwise in good shape should be safe. Throw away cans with deep dents (ones you can lay a finger into), sharp dents, or any dent on the top or side seam, and any can that is swollen or leaking.
Sources
- Shelf-Stable Food Safety — USDA Food Safety and Inspection Service. Packing codes, storage times, dented, rusted and swollen cans
- Food Product Dating — USDA Food Safety and Inspection Service
- Interpreting NJFC Can Codes for "Best-By" Dates — The Neil Jones Food Company
- FAQs (where the "Best Used By" date is printed) — Campbell's