Home · Small Business & Pricing · Cost Estimates · Cost of Goods Sold Calculator
Cost of Goods Sold Calculator
Computes cost of goods sold for a period from opening inventory, purchases and closing inventory.
What this calculator does
Computes cost of goods sold for a period from opening inventory, purchases and closing inventory. Every figure on this page is computed from the formula or definition stated below, with no hidden rounding steps, and the method notes name the exact convention where more than one exists.
The formula and method
Purchases should include freight-in and be net of returns and discounts. The formula is the standard periodic-inventory identity used in accounting.
COGS covers only the cost of goods actually sold in the period — unsold stock stays in ending inventory, not in COGS.
Worked example
With the example inputs this page opens with (beginning inventory 20000, purchases during the period 80000, ending inventory 25000), the result is 75,000.00 — cost of goods sold. Change any figure and the result updates with the same formula.
Quick reference
| Beginning inventory | Cost of goods sold |
|---|---|
| 10000 | 65,000.00 |
| 16000 | 71,000.00 |
| 20000 | 75,000.00 |
| 25000 | 80,000.00 |
| 30000 | 85,000.00 |
| 40000 | 95,000.00 |
Computed with the same formulas as the calculator above — enter any values there for figures beyond this table.
Common questions
How does the Cost of Goods Sold Calculator work?
Computes cost of goods sold for a period from opening inventory, purchases and closing inventory. Beginning inventory · Purchases · Ending inventory → Cost of goods sold. The result updates as you type, and the formula and method on this page state the exact definitions used, so you can reproduce the calculation by hand.
What inputs does the Cost of Goods Sold Calculator need?
Beginning inventory · Purchases · Ending inventory → Cost of goods sold. Invalid entries — such as a zero denominator, an out-of-range value or a malformed list — produce a plain-language message instead of a misleading number.
Is the Cost of Goods Sold Calculator free to use?
Yes. It runs entirely in your browser with no sign-up, and the same calculator is available as an embeddable widget via the Embed button, so it can be placed on another site with its calculation intact.