COGS Calculator
Work out cost of goods sold from inventory and purchases, plus gross margin and inventory turnover.
About the COGS Calculator
Enter opening inventory, purchases, freight-in and other direct costs, closing inventory and, optionally, revenue. The calculator gives cost of goods sold (COGS), and with revenue the gross profit, gross margin and inventory turnover.
COGS is the direct cost of what you sold in a period: what you had at the start, plus what you bought, minus what's left. It excludes overheads such as rent and marketing.
The formula
COGS = opening inventory + purchases + direct costs − closing inventory
Worked example
Opening stock 20,000; purchases 50,000; freight 2,000; closing stock 18,000; revenue 100,000
- COGS = 20,000 + 50,000 + 2,000 − 18,000 = 54,000
- Gross profit 46,000: a 46% margin
- Inventory turned 2.84 times, about every 128 days
Questions people ask
Does COGS include wages?
Direct labour to make products, yes; office and sales wages, no.
What's inventory turnover?
COGS ÷ average inventory: how many times stock sells through in the period.
Why does closing stock matter so much?
Overcounting it lowers COGS and overstates profit, so count carefully at period end.