COGS
How Marginful chooses the unit cost of each product sold, and how cost history works.
On this page
COGS (cost of goods sold) is what the products you sold cost you. For each order line, Marginful finds the unit cost that applied on the order date and multiplies it by the units that were not returned to stock.
Line COGS = Unit cost × (Units sold − Units restocked)
Where the unit cost comes from
Marginful checks these sources in order and uses the first one it finds:
- The variant's own cost in your cost history.
- Its bundle components: the sum of each component's cost × quantity. A bundle's own cost always wins over its components.
- The Shopify unit cost ("Cost per item" in Shopify).
- Nothing: the line is marked missing cost.
When a print-on-demand or dropshipping provider reports the exact product cost it billed for an order, that amount replaces the total, spread across the order's lines.
When several cost rows match
A product can have more than one cost row. The most specific one wins:
- A row for the exact variant beats a row matched by SKU.
- A row for the order's destination country beats a row with no country.
- The highest quantity break the line qualifies for wins.
- The most recent Effective from date wins.
Cost history is never overwritten
When you add a new cost, the previous one closes on the day before. Past orders keep the cost that applied when they were placed.
If you backdate a cost, every order since that date is recalculated with it. Marginful asks you to confirm before it does this. The superseded row is kept, never deleted.
Landed cost
If you import goods, the Logistics page lets you add a shipment's freight, insurance, customs duty, broker and port fees. Marginful spreads them over the units in the shipment and adds them to the unit cost. Import VAT is left out because it is recoverable. These costs reach COGS only when the units sell.
A missing cost overstates profit
A line without a cost adds nothing to COGS, so profit looks higher than it is. Marginful only flags a line as missing when the product's price is above zero. See Product costs.
Was this page helpful?