The number your accountant asks for and your pricing depends on: what the stock you sold actually cost.
Enter a number to see the result.
Closing stock is subtracted because you did not sell it. Freight in is added because it is part of what the goods cost you.
Cost of goods sold is opening stock, plus everything you bought in during the period, plus the freight and duty it took to get it there, minus closing stock. The subtraction is the part people forget: stock you still have was not sold, so its cost is not a cost of this period's sales. If you skip it, a big buying month looks like a disastrous trading month.
Freight in belongs in COGS because it is part of what the goods cost you to acquire. Freight out — postage to customers — does not; that is a selling cost and sits below the gross profit line. Keeping the two apart is what makes the gross margin figure on the panel mean something.
The COGS per unit is the number to price from, not the invoice cost of the last delivery. If a period's COGS is $7,640 over 640 units, the average unit cost was $11.94 including freight — and any product priced on a $9.50 invoice cost was sold at a loss once freight was counted.
Inbound freight, duty and handling are: they are costs of acquiring the goods. Outbound postage to customers is a selling expense and belongs below gross profit.
For a reseller, no. For a maker, the labour in the product is usually treated as a cost of production and included; use the labour cost per item calculator to get the figure before you add it here.
Because closing stock fell. Selling down stock you bought in an earlier period raises this period's COGS without any purchase appearing in it — which is exactly what the opening and closing lines are there to capture.