How to calculate COGS
Roll opening stock through purchases to closing stock.
Enter opening inventory
Use the closing balance from the previous period.
Add purchases
Include freight-in and duty that are part of inventory cost.
Subtract closing inventory
Use a consistent cost valuation for the closing count.
What does this tool do?
Cost of goods sold is the cost of the inventory that was sold during a period. The periodic method adds purchases to opening stock and subtracts closing stock, which ties the balance sheet to the income statement.
The Formula
COGS = Opening inventory + Purchases − Closing inventoryFrequently Asked Questions
What should be included in purchases?
Include goods bought for resale plus freight-in, duty and non-recoverable purchase taxes. Exclude operating costs such as marketing, rent and admin.
Why can closing inventory not exceed goods available?
Goods available is everything that could be sold. A higher closing balance would imply negative COGS, which usually signals a data or valuation error.