FREE TOOL

Expiration date decoder

Type what's printed on the package, lot numbers and all. See which date is the expiry, what kind of date it is, how many days you have, and when you'd get a reminder.

One line per line on the label. Lot numbers, weights and packed-on dates are fine to include; the decoder sorts them out.

How the decoder reads a label

Packaging mixes the date with everything else: lot numbers, plant codes, packing times, weights. The decoder looks at every number that could be a date, then scores each one the way FreshScan does on your phone:

  • Words next to the date decide its type. BEST BY, BB and BEST BEFORE make a best-by date; USE BY a use-by date; SELL BY and DISPLAY UNTIL a sell-by date; EXP an expiration date. A keyword on the line just above or below counts too.
  • Packed-on and manufacturing dates lose. A date next to PACKED ON, PKD, MFG or PROD is scored down, so the expiry date wins. Numbers after LOT, UPC or NET WT are scored down so far that they drop out whenever the label has a real date.
  • Plausible food dates score higher. A date between today and about two years out is typical. Dates far in the past or many years ahead are doubted.
  • It asks when it sees two readings. Two different dates, or a full numeric date that reads two ways, are shown as choices. A short date with no year is read in the order you pick and marked “Year not printed”, so check it.

Formats it understands

BEST BY OCT 04 2026USE BY 04OCT26EXP 10/04/26BB 04.10.20262026-10-04BEST BEFORE END 10/2026
PrintedRead asNotes
OCT 04 2026October 4, 2026Month names and abbreviations, including SEPT and some European ones (OKT, DEZ, MAI)
04OCT26October 4, 2026Day first, no spaces, two-digit year
10/04/26October 4 or April 10Depends on the order you pick (MM/DD or DD/MM); both are shown if both are plausible
2026-10-04October 4, 2026Year-first dates are never ambiguous
10/2026October 31, 2026Month and year only: read as the end of the month
EXP 10 2026October 31, 2026Month and year with a space: only next to a date word like EXP, BB or BEST BEFORE
2026/10October 31, 2026Year first, with -, / or .
BB 10/26October 31, 2026Two numbers need a date word (BEST BEFORE 10 26 works too). USE BY or SELL BY 10/26 is also offered as October 26 when that's within 90 days
OCT 04Next October 4No year printed: the next sensible year, flagged

More on each format in how to read expiration dates, and on the 10/04 problem in month or day first?

What each kind of date means

Only infant formula is required by federal rules to carry a date. Everything else is dated voluntarily by the manufacturer, which is why the wording varies so much. USDA says best-by, sell-by and freeze-by dates are not safety dates. California's 2024 labeling law goes further and reserves “USE by” for dates about safety. The full comparison is in sell by vs use by vs best by.

What it can't do

It reads text you type; it can't see the package. Julian pack codes like the three-digit number on egg cartons aren't calendar dates, so they're left alone here: use the Julian date converter. And it can't tell you how long a food keeps once opened; for that, try the food expiration calculator.

Questions people ask

Is this the same logic the FreshScan app uses?

Yes. The decoder is a line-by-line port of the date parser inside FreshScan. It is tested against the app's own code on 6,000 label variations, and both must give the same date, date type, confidence and flags. The app adds the camera: it reads the text from the package with Apple's on-device text recognition, then runs the same rules.

Why does it ask me to choose between two dates?

Some labels print more than one date, such as a sell-by and a use-by date, or a date like 03/04/27 that means March 4 in the US and April 3 in most other countries. A short sell-by or use-by date like 10/26 can also mean October 26 or the end of October 2026. When both are plausible the decoder shows both and lets you pick, instead of guessing. The likeliest date is listed first; when two are equally likely, the use-by or expiration date comes first because it's usually the one to act on.

What does a two-number date like 10/26 mean?

On its own it could be October 26 or October 2026, so the decoder doesn't guess; it asks what's printed next to it. With BEST BY, BB or EXP it reads October 2026, the end of the month. With USE BY or SELL BY it also offers October 26 when that's within 90 days, and you pick. Spaced versions like BEST BEFORE 10 26 or EXP 04 2027 are read the same way, but only next to one of those words.

What if the label has no year?

Dates like SEP 17 are placed on the most recent SEP 17 if it was 45 days ago or less, otherwise on the next one. So DEC 20 typed in early January means the December just gone, and SEP 17 typed in December means next September. The result is marked 'Year not printed' so you can check it.

Does the decoder tell me whether food is safe to eat?

No. It reads the date the manufacturer printed and explains what that kind of date means. Whether food is still good also depends on how it was stored, whether it was opened, and how it looks and smells. See the shelf-life guides for storage times, and when in doubt, throw it out.

Is anything I type sent anywhere?

No. The decoder runs entirely in your browser; the text you type is not sent to a server or stored.

Sources

  1. Food Product Dating — USDA Food Safety and Inspection Service
  2. AB 660 (2024): Food labeling: quality dates and safety dates — California Legislative Information
FRESHSCAN FOR IPHONE

Same rules, no typing: point your camera at the date.

FreshScan reads the printed date with your iPhone camera, runs it through exactly these rules, and saves the item with a photo. Two days before the date, and again that morning, it reminds you at 9 AM.

  • Reads best by, use by, sell by and EXP dates, and skips packed-on dates
  • Reminders at 9:00 AM, 2 days before and on the day
  • Free for up to 10 items at a time
Download on theApp Store