Inventory & Cost of Goods Sold

cost of goods sold formula

Suppose you run a market stall. You started the month with some boxes left over from before, you bought more boxes during the month, and at month-end some boxes are still unsold. To know what the goods you actually sold cost you, you take what you started with, add what you bought, and subtract what is left. That tidy bit of bookkeeping is the cost of goods sold formula.

Written out, the formula is: beginning inventory + purchases − ending inventory = cost of goods sold. The first two terms together (beginning inventory + purchases) are called cost of goods available for sale; subtracting the ending inventory leaves the cost of the goods that left your hands. For example, start with 5,000, buy 20,000, and count 6,000 left: cost of goods sold = 5,000 + 20,000 − 6,000 = 19,000. Note that 'purchases' includes freight-in (shipping to get goods to you) and is reduced by purchase returns and purchase discounts.

It matters because cost of goods sold is usually the single biggest expense for a retailer or manufacturer, and it sits right under revenue on the income statement: revenue − cost of goods sold = gross profit. Get this number wrong and both your profit and your inventory are wrong. The formula also reveals a quiet truth — ending inventory and cost of goods sold are two sides of the same coin: every dollar you do not count as 'still on the shelf' is automatically treated as 'sold', so an error in counting inventory mis-states profit by the same amount.

A clothing shop begins the year with 5,000 of inventory, buys 20,000 of clothes during the year (including freight-in, net of discounts), and counts 6,000 still unsold at year-end. Cost of goods sold = 5,000 + 20,000 − 6,000 = 19,000.

Beginning + purchases − ending = cost of goods sold; inventory and COGS are two sides of one coin.

Because the formula is just rearranged, overstating ending inventory understates cost of goods sold and overstates profit by the very same amount — and the error reverses next period when that inventory becomes the beginning balance.

Also called
COGS formulacost of sales销货成本公式銷貨成本公式