Shopify app for food, cosmetics and supplement makers · Pro plan
Batch and lot tracking with expiry dates for Shopify
Costory keeps every delivery of an ingredient as its own lot with an expiry date. Shopify orders are deducted from the lot that expires first (FEFO), lots about to expire are flagged a few days ahead, and expired stock is written off in one click.
Free for up to 10 products · 14-day trial on paid plans
Updated
-
Received Nov 2 2.4 kg left of 5 kg · $9.00 / kgNov 22 Expires in 2 days
-
Received Nov 16 6 kg left of 6 kg · $9.60 / kgNov 29 Within expiry
-
Received Nov 9 10 kg left of 10 kg · $9.20 / kgDec 8 Within expiry
Costory adds lot tracking to Shopify for the ingredients and semi-finished goods you make products from. Every purchase receipt, and every production run of a semi-finished good, becomes a lot with its own quantity, cost and expiry date. Orders, production and write-offs take stock first expired, first out (FEFO), and lots that expire within 3 days (you choose 0 to 60) show up on the Overview and in the daily digest. Lots and expiry dates are part of the Pro plan, $99 a month with a 14-day trial.
What is lot tracking, and where do lots come from?
Lot tracking, also called batch tracking, means keeping every delivery of an ingredient as a separate lot with its own quantity, unit cost and expiry date, instead of one running total per ingredient.
In Costory there is no separate lot screen to fill in: a lot appears whenever stock arrives. Receiving a purchase line of 6 kg of butter with the expiry date November 29 creates one 6 kg lot at the price you paid, with delivery and other purchase costs already split across the lines (see landed cost). Supplier packs are converted to your unit, so 2 sacks of 25 kg flour become one 50 kg lot.
Costory rejects an expiry date earlier than the receiving date, so a mistyped year does not slip through. The ingredient card lists every lot in FEFO order with where it came from, what is left of it and its status, plus the last five lots that were used up.
| Stock arrives by | What Costory records | Expiry date |
|---|---|---|
| Receiving a purchase | One lot per received line, at the landed unit cost | Entered per line; leave it empty if the item does not expire |
| A production run of a semi-finished good (a dough, a syrup, a base) | One lot for the output, with an optional batch code | Entered on the production run |
| Stock already on hand when you turn lots on | One “Opening stock” lot per ingredient and location | None, so it is used after dated lots |
| A stock count surplus or a manual adjustment | A new lot | None |
| A transfer between locations | A lot at the destination for each lot the stock left | The same date and batch code as the lot it came from |
| Stock that goes back after a cancelled or refunded order (per your cancellation and refund settings) | Back into the lots that order line was deducted from | Kept |
How does FEFO deduct Shopify orders? A worked example
FEFO (first expired, first out) means every deduction takes stock from the lot with the nearest expiry date first, whatever order the lots arrived in.
Costory sorts lots by expiry date, then by the date received, and puts lots without an expiry date last. The same order applies to everything that takes stock: order deductions, production runs, write-offs, stock counts that come up short and transfers. One deduction can be split across several lots.
Take a bakery on November 20 with three lots of butter and 30 Brownie boxes to deduct, each with 150 g of butter in its recipe.
30 Brownie boxes × 150 g = 4,500 g = 4.5 kg of butter → 2.4 kg from the Nov 2 lot + 2.1 kg from the Nov 16 lot
| Lot | Expires | Unit cost | Left before | Taken for 30 boxes | Left after |
|---|---|---|---|---|---|
| Received Nov 2 | Nov 22 | $9.00 / kg | 2.4 kg | −2.4 kg | 0 kg |
| Received Nov 16 | Nov 29 | $9.60 / kg | 6.0 kg | −2.1 kg | 3.9 kg |
| Received Nov 9 | Dec 8 | $9.20 / kg | 10.0 kg | 0 kg | 10.0 kg |
| Total | 18.4 kg | −4.5 kg | 13.9 kg |
Why not FIFO?
FIFO (first in, first out) would take the remaining 2.1 kg from the Nov 9 lot, which keeps until December 8, and leave all 6 kg of the Nov 16 lot untouched, although it expires nine days earlier. FEFO leaves 3.9 kg in that lot instead of 6 kg.
Each lot keeps its own cost
With the “By batch, FIFO” price method, which needs lots turned on, the 4.5 kg is valued at its own lots: 2.4 kg × $9.00 + 2.1 kg × $9.60 = $21.60 + $20.16 = $41.76, or $9.28 per kg. The 13.9 kg left is worth 10 kg × $9.20 + 3.9 kg × $9.60 = $92.00 + $37.44 = $129.44 on Stock levels. The deduction itself still follows FEFO; the method only sets the cost of each part.
If the lots run short, the order is still deducted: stock goes below zero, shown in red, and the next receipt covers that shortage before it opens a new lot. Lot tracking does not block a sale.
How does Costory warn before a lot expires?
Costory flags every lot that expires within 3 days by default, and you can set the warning window to any number from 0 to 60 days in its stock settings.
- Overview. A row under “To do” names the ingredients, such as “Expiring: Butter — 1 batch in 2 days”, and opens the stock list filtered to them.
- Stock levels. The nearest expiry date of each ingredient, and an “Expiring” filter.
- Ingredient card. Every lot with its status: “Expires in 2 days”, “Expires today”, “Past expiry”, “Within expiry” or “No expiry date”.
- Daily digest. Expiring and expired lots in the morning digest by email, and in Slack or Telegram if you connect them.
Days are counted on your store’s calendar, in its time zone, and the expiry date is the last usable day. A lot dated November 22 reads “Expires in 2 days” on November 20, “Expires today” on November 22 and “Past expiry” on November 23.
A lot entered without an expiry date gets no warning at all, which suits jars, labels and boxes. A lot that is used up drops off the list.
How do I write off expired stock?
One button, “Write off expired”, writes off everything left in every expired lot, as one write-off per lot with the reason “Wilted or spoiled”.
Say 1.5 l of cream is left in a lot that expired on November 22. On November 23 the Overview offers “Write off expired”; after you confirm, Costory writes off the 1.5 l from that very lot with the comment “Expired batch, best before 2026-11-22”. At $4.20 a litre, that is 1.5 l × $4.20 = $6.30 under “Wilted or spoiled” in the write-offs report.
The confirmation comes with Undo, which puts the stock back into the same lots. Pressing the button twice does not write anything off twice. With several locations, the button on Stock levels writes off only the location shown there; the one on the Overview covers every location.
For a single damaged jar or an opened sack, the quick write-off screen lets you pick the lot: the quantity comes out of that lot first, and anything beyond it by FEFO. Without a choice, a write-off follows FEFO like an order.
The write-offs report groups losses by reason, so you see what expired stock costs you each month, next to breakage, tasting and samples. Write-offs, purchases and stock counts are described on inventory and purchasing.
Lot tracking vs batch production: what is the difference?
Batch production records making goods in advance; lot tracking records which delivery or production run each unit of stock came from and when it expires.
| Batch production | Lot tracking | |
|---|---|---|
| Answers | What did this production run use, and what did it cost? | Which stock expires first, and what is it worth? |
| Records | A production run: ingredients used, quantity made, cost of the run | Lots of each ingredient and semi-finished good: quantity left, unit cost, expiry date |
| Changes stock | Deducts the ingredients and adds the finished products to Shopify inventory at the chosen location | Decides which lot every deduction comes from |
| Plan | Growth ($39 a month) and Pro | Pro ($99 a month) |
On Pro the two work together. A production run of caramel sauce, kept in stock as a semi-finished good, takes its cream and sugar from their lots by FEFO and becomes a new lot of sauce with its own expiry date and batch code. The products that use the sauce then draw from that lot when they sell.
Who is it for, and what does it not do?
Lot and expiry tracking suits Shopify brands that buy perishable ingredients and make products from them: food and drink, cosmetics and skincare, supplements.
Typical lots
- Food: butter, cream, chocolate, nuts and fruit for a bakery or a confectioner (food and beverage).
- Cosmetics: carrier oils, butters, extracts and preservatives with a shelf life (beauty and cosmetics).
- Supplements: powders and capsules bought in bulk and packed in-house.
Lots and expiry dates are part of the Pro plan ($99 a month, billed by Shopify, 14-day trial) and build on ingredient stock tracking. Compare the plans on pricing.
Limits to know
- Lots cover the ingredients and semi-finished goods in Costory’s own stock. Finished products made in batches or bought for resale keep their inventory in Shopify, without lots in Costory.
- The receiving form takes an expiry date for each line but no supplier lot code; a batch code is entered on production runs.
- Stock already on the shelf when you turn lots on becomes one “Opening stock” lot without an expiry date, which FEFO uses after the dated lots.
- It is not a recall system: lot codes do not appear on orders or packing slips, and Costory does not read customer names, emails or addresses.
Install free on Shopify Start on Free, then try Pro with a 14-day trial.
Questions about lot and expiry tracking
What is the difference between FIFO and FEFO?
FIFO (first in, first out) uses the stock received earliest; FEFO (first expired, first out) uses the stock that expires soonest. They differ when a later delivery has a shorter shelf life. Costory deducts by FEFO: nearest expiry date first, then the earliest received, and lots without an expiry date last.
Which Costory plan includes lot and expiry tracking?
Lots with expiry dates and FEFO are part of the Pro plan, $99 a month, billed by Shopify in USD with a 14-day trial. They build on ingredient stock tracking, which starts on Growth ($39 a month) together with batch production, purchases and write-offs.
How many days before expiry does Costory warn me?
Three days by default. You can change it in Costory’s stock settings to any number from 0 to 60 days. Lots inside that window appear under “To do” on the Overview, in the “Expiring” filter on Stock levels and in the daily digest.
Can Costory track lots of finished products?
Not of finished products whose stock Shopify keeps. Lots cover the ingredients and semi-finished goods in Costory’s own stock, such as butter, essential oils, a dough or a syrup. Products made in batches or bought for resale keep their inventory in Shopify, without lots in Costory.
What happens when a lot runs out in the middle of an order?
The rest comes from the next lot in FEFO order, so one deduction can be split across several lots. If all lots run short, the order is still deducted and stock goes below zero. The next receipt covers that shortage before it opens a new lot.
Do I have to enter an expiry date for every delivery?
No. The expiry date on the receiving form is optional: leave it empty for jars, labels or anything else that does not expire. Lots without a date are used after all dated lots and get no expiry warnings.
Do lots and expiry dates follow stock between locations?
Yes. A transfer takes stock from the source location’s lots by FEFO and creates a matching lot at the destination for each one, with the same expiry date and batch code, so warnings and FEFO keep working there. Multiple locations and transfers are part of the Pro plan as well.
Related
Food and beverage
Recipe costs, margin-based prices and ingredient stock for bakeries, chocolatiers, coffee roasters and other food brands.
Learn more →Beauty and cosmetics
Formula costing for skincare, soap and candle brands: grams at per-kg prices, jars and labels, batches, sizes, expiry dates and margin-based prices.
Learn more →Inventory & purchasing
Ingredient stock deducted by Shopify orders, purchase orders with landed cost, stock counts, write-offs and a reorder list.
Learn more →Use the stock that expires first, automatically.
Free for up to 10 products. Paid plans start with a 14-day trial.
Install free on Shopify