The formula
The accounting formula is brutally simple:
COGS = Beginning inventory + Purchases during the period − Ending inventory
For a baker: the flour and sugar you started the month with, plus what you bought, minus what's still on the shelf at month-end. The difference is what got baked into product that left the door.
For a per-unit calculation (which most small sellers actually want):
Per-unit COGS = ingredient/material cost + packaging + direct labor (allocated to the unit)
What counts as COGS — and what doesn't
The boundary between COGS and operating expenses is where most small businesses lose track.
- In COGS (direct costs).
- Ingredients and raw materials
- Packaging that ships with the product (boxes, labels, tissue)
- Direct labor: the hours actually spent making the unit
- Freight in (the cost to receive materials)
- Production supplies that are consumed per unit
- Not in COGS (operating expenses).
- Marketing and ads
- Etsy / Shopify / Square platform fees (often booked separately)
- Rent and utilities (unless directly tied to production)
- Software subscriptions
- Accountant, lawyer, and other professional services
- Owner's draw / non-production labor
The platform-fee question is a real edge case for online sellers. Some treat Etsy transaction fees as a direct cost of the sale; others book them as a separate "selling expenses" line. Pick a treatment and be consistent. The total is what matters for your real margin.
Why COGS matters more than total expenses
Two numbers come out of getting COGS right:
- Gross profit = Revenue − COGS. The cash left from a sale after the cost of producing it. The number that tells you if the underlying product is viable.
- Gross margin = Gross profit ÷ Revenue. Expressed as a percentage. A direct comparison of profitability across products regardless of price point.
A $40 cake with $18 in COGS has a 55% gross margin. A $40 cake with $32 in COGS has a 20% margin — and after Etsy fees, marketing, and your time, that's a loss with extra steps. Same revenue, very different business.
How to calculate per-unit COGS for a handmade product
- Price ingredients in standard units. Flour per gram, eggs per egg, frosting per ounce. The conversion from purchase pack to recipe unit is where most spreadsheets break.
- Cost the recipe. Sum the ingredient costs at the quantities the recipe calls for.
- Divide by yield. A batch that produces 24 cookies has its COGS per cookie = recipe COGS ÷ 24.
- Add packaging. The box, label, ribbon, tissue — everything that ships with the product.
- Add direct labor. The minutes you spent actively producing × your hourly rate. Yes, including your own time. The number is wrong without it.
- That's your per-unit COGS. The price must clear it with margin to spare.
Common mistakes
- Ignoring labor. The single biggest reason home bakers and craft sellers undercharge. If your labor isn't in COGS, you're paying customers to take your time.
- Forgetting packaging. A $3 box on a $20 product is a 15% hit. Multiply by every shipment.
- Confusing margin with markup. Markup is profit ÷ cost. Margin is profit ÷ price. They are not the same number; a 50% markup is a 33% margin.
- Letting waste hide. Frosting you threw out, dough that overproofed, fabric you mis-cut — all real costs. Track them.
- Annual instead of per-unit. Annual COGS divided by annual units is an average. It hides which products are profitable and which aren't. Cost per recipe / per SKU.
Related templates and concepts
COGS is the input to profit margin and the focus of recipe costing for food sellers specifically. See the templates for home bakers, templates for craft sellers, and templates for Etsy sellers hubs for the full small-business toolset.