Lot Tracking for Food Brands: How to Set It Up and Pass a Mock Recall
How small food brands set up lot tracking: what one lot is, how to build a lot code, where to record supplier and input lots, and how to run a mock recall.

Article written by
Peasy

Lot tracking is the record that ties every batch you make to the ingredients that went into it and the customers who got it. Most brands we talk to set it up the week someone asks for it.
It's usually a grocer's new-vendor form, a distributor's onboarding packet, an organic certifier, a co-packer that wants to see your records before the first run, or a supplier emailing about a bad lot of an ingredient you used last month.
We'll go through what to track, how to build a lot code, where the records live, how to run a mock recall, and when FSMA 204 applies.
We make Peasy, free inventory ops for small CPG brands. At the end we'll walk through how it handles lots.
What lot tracking is
A lot (or batch) is one production run of one product. The lot code is the name you give it. It's not the same thing as the best-by date.
The best-by date is for the shopper. The lot code is for you, your buyers, and an inspector. Two lots can share a best-by date and still be different lots.
Every lot has two halves:
Inputs: the supplier lots of each ingredient and packaging component that went into the batch.
Output: the finished lot, and the orders it shipped on.
A backward trace starts at a finished lot and runs back to its inputs and their suppliers. A forward trace starts at one ingredient lot and runs to every batch that used it and every customer who got those batches.
Both run on one record. It's the batch record, the one that lists the input lots next to the output lot.
A lot of brands tell us they track lots, and what they have is the finished code printed on the case with nothing tying it back to the inputs. That's half a system.
Lot number vs batch number vs serial number
In practice, lot number and batch number mean the same thing. Both name one production run, and so do lot code and batch code. GS1 barcodes label the field "batch/lot."
A serial number names a single unit. Food brands track lots, because a recall pulls a run, not a jar.
Do you need lot codes at your size?
Not until something forces you. Then you need them right away.
Nobody comes after a farmers market brand for lot codes. And if your co-packer sources the ingredients and stamps a batch code on the case, they already hold the ingredient-level trace.
Here's what forces it, roughly in the order it shows up:
A retailer's supplier form. Natural grocers in particular ask whether you can pass a traceability check.
A distributor jump. Once you go from a few dozen stores to a distributor with hundreds, you can't recall by phone.
Certification. An organic certifier wants inbound-to-outbound trace on every lot. SQF and other GFSI audits include a mock recall.
A new co-packer. The first thing a good one asks is "tell us about your tracking."
Producing in house. Once you buy the flour, you're the only one who knows which bag went into which batch.
A supplier recall notice. It names their lot code. If you didn't write that code down at receiving, the notice tells you nothing.
Lot tracking for batch cost
There's a second reason, and it has nothing to do with safety. Two deliveries of the same ingredient rarely cost the same.
When the batch record names the lot you used, the batch costs what those lots cost. So if a hundred of the six hundred tubes you bought came in at a higher price, you can see why margin moved.
Brands with no food safety requirement at all track lots for this reason alone.
What FDA already requires
The legal baseline is lower than you'd think.
You already have to keep records of where your food came from and who it went to, including lot numbers where they exist. And you have to produce them within 24 hours of a request.
So the question isn't whether to keep records. It's how fine-grained they need to be.
How to set up lot tracking in five steps
1. Decide what one lot is
The convention is one lot per product per production day.
A co-packer that runs 32 batches of one SKU in a day will usually issue one code for the day. If you make by hand and you're generating twenty lot codes per pallet, you're making work for yourself.
What you're trading is recall size against daily admin. So match it to the ingredient's risk.
Sugar, flour, and a dry snack are rarely recalled. Day-level lots are fine there.
Raw dairy, fresh produce, eggs, and anything with a top allergen deserve batch-level lots, kept separate. If a run draws on two lots of carrots, both lots are in the recall.
If you hold an intermediate for more than a day (a base, bulk chocolate aging before it's barred, frozen product waiting to be dried), give it its own lot. Then record it as an input to the finished batch.
If it's made and used up in the same run, skip that step. The test is whether inventory sits in that stage.
2. Build the code
There's no FDA format to copy. Start with a product code plus a date, and add a run number only if you need one.
Format | Example | Works when |
|---|---|---|
Date only |
| One product, one batch a day. It repeats the moment two products run on the same day. |
Product + date |
| Several products, one batch each per day. The default most brands land on. |
Product + date + run |
| Several batches of one product in a day |
Best-by date |
| The date is already stamped on the can, so one product per day costs nothing extra |
Co-packer's batch code | whatever they print | They make it. Use their code as your finished lot so the case matches your records. |
Whichever you pick, four rules:
Never reuse a code.
Keep it to 20 characters or fewer, which is the batch/lot limit in a GS1-128 case barcode.
Write a one-page key so anyone on your team can read it.
If someone types the code into a bottling or stamping machine by hand, keep it short and pull the detail from your records when you need it.
3. Record supplier lots at receiving
When a supplier calls about a bad lot, they'll quote their number, not yours. So record their code exactly as it's printed.
At receiving, capture the item, the quantity, the supplier's lot code, your own code for the delivery, the date, and the certificate of analysis if the ingredient comes with one.
One delivery often carries several supplier lots. List them all on one receipt, or write one receipt per lot if you'll need to know which bag went into which batch.
If an ingredient ships straight from the supplier to your co-packer, it never passes through your hands. Your trace starts at the co-packer's batch code, and that's normal.
Say you keep a bag of peanut flour for the gluten-free line and another for the regular line. Tag the lot code at receiving, so the right bag is the only one you can pick later.
4. Record input lots on every batch
Write the batch record when the batch is made, not on Friday from memory. For each input, note the lot you used. Oldest-first is the right default.
When a run spans two bags, split it: 15 pounds from one lot and 5 from the next.
When your baker opens a new bag mid-run, that's the moment to note it. If your kitchen runs on paper, key it in the same day.
Then give the finished batch its code, the one you print on the case. If a co-packer runs it, the record is the batch sheet they send back, and the finished code is theirs.
5. Record the finished lot on what ships
Wholesale and distributor orders get a lot per line. That's easy when the lot code is on a label stuck to the pallet. Transfers to a 3PL or a second warehouse get the lot too, and samples count as shipments.
Direct web orders are the exception. Nobody lots each web order, and no inspector expects you to.
Assume oldest-first and keep the date range each finished lot was shipping. That way a recall notice can go to every web customer in the window.
Worked example: tracing one flour lot forward
Say a supplier flags one lot of flour. Here's the forward trace for a granola brand, built from the three records above.
Record | What it shows |
|---|---|
Receiving, Oct 2 | Flour, supplier lot FLR-2291, 10 bags, COA attached |
Batch records | FLR-2291 was an input to GR-261006-1 (granola), GR-261008-1 (granola), and BAR-261007-1 (bars) |
Shipping records | GR-261006-1: 40 cases to one distributor DC, 12 cases to six stores. GR-261008-1: web orders Oct 9 to 14. BAR-261007-1: 18 cases to four stores, 2 cases as samples |
On hand | 11 cases of GR-261008-1 on the shelf, 6 cases of BAR-261007-1 at the 3PL |
Then reconcile each finished lot: made = shipped + on hand + samples + waste. If 95% of a lot is accounted for, 5% of it is somewhere you can't call.
How to run a mock recall
A mock recall is that same trace, against a clock, done before anyone makes you.
The people who make you are the retailer, a city or county inspector who turns up once or twice a year, and your certifier, whose auditor picks a lot and watches.
One brand we talked with spent an audit pulling lot-code paperwork out of a storage unit against a thirty-minute clock.
GFSI schemes expect a full mock recall at least once a year. Once a year is the right cadence whether anyone requires it or not.
Pick the lot. Have someone else choose, either a supplier lot you received or a finished lot you shipped. Start a timer.
Go backward. From the finished lot, list every input lot and its supplier with a contact name.
Go wide. For the suspect input, list every other finished lot that used it. One bag feeds several batches, so this is where paper breaks.
Go forward. For each affected finished lot, list every order it shipped on: customer, quantity, date. Include distributors, stores, the web-order date range, and samples.
Count what's left. Shelf, 3PL, co-packer.
Reconcile and write it up. Made = shipped + on hand + samples + waste. Note the time, the first record you couldn't find, and the one fix you'll make. Aim for under an hour.
When FSMA 204 applies
FSMA 204, the Food Traceability Rule, only covers foods on FDA's Food Traceability List. That's fresh-cut produce, leafy greens, fresh herbs, tomatoes, peppers, melons, cucumbers, soft cheeses, shell eggs, nut butters, finfish, shellfish, and ready-to-eat deli salads.
It also covers foods that contain one of them in its listed form. So a granola, a hot sauce, or a bar made with roasted nuts is outside it. A fresh salsa or a nut butter is inside it.
If it applies, the rule adds a traceability lot code, assigned when you transform the food.
It also adds what FDA calls key data elements, recorded at critical tracking events such as receiving, transformation, and shipping. And it adds a sortable electronic spreadsheet of that data for FDA within 24 hours during an outbreak.
The FSMA 204 compliance date
The original compliance date was January 20, 2026. FDA has proposed July 20, 2028, and Congress has directed FDA not to enforce before then.
FDA's rule page has the list and an exemption tool. Checked October 2026.
Common lot tracking mistakes
A finished code with nothing behind it. The case says L-261013 and no record says which flour went in. Your backward trace fails on the first question.
Date-only codes. Two products run on a Tuesday and share a lot code. Put the product in front of the date.
Lots that don't match the shelf. Every deduction made without a lot (a count correction, a sale logged in a hurry) pulls the lot totals away from the real on-hand count. Tag every movement with a lot, and reconcile lots after each physical count.
Over-granular lots on low-risk ingredients. Five pallets of sugar with thirty supplier lots is thirty entries a delivery, for a recall that has never happened. Use the range.
Only the co-packer has the records. If they close, change systems, or drop you, your trace goes with them. Keep the batch sheet and the batch-to-customer record on your side.
No outbound record. Without the lot on each wholesale order, you can't tell an auditor which store got which batch.
How Peasy handles lot tracking
Every receipt creates a lot. The Lot ID fills itself in from the SKU and the receive date and can be changed to anything. The Supplier Lot ID sits next to it. Upload the COA on the receipt and it shows on that lot.
Input lots are recorded when the batch is done. At Mark as Done on a Work Order, each ingredient takes a lot. Tick Suggested to apply the oldest lot to every input at once, or add a second lot row to split an ingredient across two bags. The finished batch gets its own lot number. For a co-packer run, Receive & mark done records the ingredient lots and the finished lot in one step.
Outbound lots live on the order. The Lot cell on each sales order line records which lot that customer got. Shopify orders can take the oldest lot automatically with Auto-assign lot IDs to Shopify orders.
The trace is one click. Open any lot and the Lot Tracking panel shows the work order that made it, every batch it went into, and every sales order and customer that received it.
Drift is visible. The lot browser shows how much of an item's stock is Not lot-assigned, and Inventory > History has Edit lots to fix lots on past rows in bulk.
One limit: lots don't carry expiry dates. Put the date in the Supplier Lot ID or a custom field.
Peasy is free, with no cap on items, users, or orders. The lot tracking guide has the steps.

Article written by
Peasy



