Inventory & margins
Inventory, cost of goods sold and product margins
Connect landed costs, inventory movements, returns and valuation to cost of goods sold so changes in product margins have a clear explanation.
Author credentials and experiencePublished on Beamarc: September 30, 2026.
Your product costs $12 to land. You sell it for $30. That's 60% gross margin, right?
Maybe. But your P&L shows 48%. Or 67%. Or it swings every month even though nothing operational changed.
Differences can arise from pricing, discounts, channel mix, landed costs, inventory valuation, returns or shrinkage. Start by checking the definition of margin and then trace the underlying records.
For ecommerce businesses, inventory records connect purchasing, fulfillment and the income statement. A monthly reconciliation makes those connections easier to explain.
Before you touch COGS: define “margin”
An apparent margin difference can come from using different definitions.
- Gross profit is revenue less cost of sales. Gross margin percentage is gross profit divided by revenue. For financial reporting, apply the relevant accounting framework and cost-of-sales presentation.
- Contribution margin means sales less all variable costs. State the cost basis and use it consistently across products and channels. A measure deducting only selected costs needs a narrower label; inventory cost can include fixed production overhead and is not automatically variable cost.
“Direct” and “variable” describe different things. Direct costs can be traced to a product or job; variable costs change with activity. A production employee’s salary can be a direct cost even when total pay stays the same as output changes. Overhead can have both fixed and variable parts.
Contribution margin includes variable selling and fulfillment costs as well as variable product costs. Dashboard measures and financial statements may use different definitions, so check which costs each measure includes before comparing them.
The inventory accounting chain: where margin actually comes from
Gross margin is a simple equation with an unforgiving dependency chain.
The COGS chain
For purchased goods: net purchase price + qualifying inbound costs = inventory cost.
Deduct applicable supplier discounts and credits; exclude recoverable taxes. Manufacturers must also consider direct labor and properly allocated production overhead. Fixed production overhead allocation reflects normal capacity; abnormal waste and overhead unallocated because of abnormally low production are period costs. The purchased-goods illustration below is not a complete manufacturing-cost model.
Inventory cost sits on the balance sheet
When sold, cost flows to COGS (income statement)
Revenue − COGS = gross profit
Incomplete landed costs, unreconciled inventory, missed returns and unrecorded shrinkage can all distort the reported margin.
Landed cost: the number everyone under-builds
Landed cost is the set of costs required to bring inventory to its present location and condition for sale. In practice for ecommerce merchants, that often means:
- Product cost (supplier invoice)
- Inbound freight / transportation-in (ocean/air/ground into your receiving location)
- Import duties and nonrecoverable import taxes/fees (when applicable)
- Brokerage / customs clearance (when applicable)
- Other directly attributable acquisition costs (facts-based; document your policy)
What’s usually not inventory cost for most DTC merchants (but don’t treat this as a universal rule):
- Ongoing warehousing/storage after goods are in sellable condition (rent, most 3PL monthly storage)
- Outbound fulfillment to customers (pick/pack, postage): usually fulfillment/selling costs (your presentation policy matters)
- General admin overhead
Illustrative landed cost
Capturing only the supplier invoice can omit qualifying inbound costs. Check freight, duty, brokerage and related invoices before finalizing inventory cost.
- Product cost (supplier invoice). Per unit: $8.50; % of landed: 68.0%
- Inbound freight (allocated). Per unit: $1.80; % of landed: 14.4%
- Import duty / fees. Per unit: $0.77; % of landed: 6.2%
- Brokerage / clearance (allocated). Per unit: $0.35; % of landed: 2.8%
- Transit insurance. Per unit: $0.18; % of landed: 1.4%
- Inland freight (port to warehouse). Per unit: $0.90; % of landed: 7.2%
- Total landed cost. Per unit: $12.50; % of landed: 100.0%
Shipping terms, freight arrangements, duties and other acquisition costs affect landed cost. Using only the supplier invoice can overstate product margin.
Using only the $8.50 supplier cost gives a gross margin of 71.7% on a $30 sale. At the illustrated $12.50 landed cost, the margin is 58.3%, a difference of 13.3 percentage points calculated before rounding. This product-margin illustration assumes no other cost of sales; it is not contribution margin or a full company income statement.
Beamarc sample: trace inventory into cost of goods sold
This illustrative close extends the $12.50 landed-cost example above. It is not a client result or a complete set of financial statements.
Assume one purchased product, 200 units at the start of the month, 800 units received and owned during the month, and 600 units sold at $30 each. Every unit has the same supported $12.50 cost. All 600 sales qualify for recognition in the month. There are no returns, discounts, sales taxes, goods in transit, shrinkage or valuation adjustments in this sample. There are no other costs of sales in the gross-profit calculation.
1. Reconcile the units and their cost
| Inventory movement | Units | Cost |
|---|---|---|
| Opening inventory | 200 | $2,500 |
| Add receipts | 800 | $10,000 |
| Available for sale | 1,000 | $12,500 |
| Less units sold | (600) | ($7,500) |
| Ending inventory | 400 | $5,000 |
The two checks agree: 200 + 800 − 600 = 400 units, and $2,500 + $10,000 − $7,500 = $5,000. The $7,500 moves to cost of goods sold; the $5,000 remains in inventory. Paying the supplier does not determine which units enter cost of goods sold.
2. Connect the schedule to the report
- Sales: 600 × $30 = $18,000.
- Cost of goods sold: 600 × $12.50 = $7,500.
- Gross profit: $18,000 − $7,500 = $10,500.
- Gross margin: $10,500 ÷ $18,000 = 58.3%, rounded.
Gross profit does not tell you the cash collected or the business's net income. Customer payment timing, supplier bills, selling costs and other expenses still need their own schedules. For a separate cash example, see the multi-channel reconciliation. Its figures describe a different illustration and should not be combined with this sample.
3. Find the support behind each number
- Opening 200 units and $2,500: the prior close's inventory valuation and general ledger balance.
- Receipts of 800 units and $10,000: receiving records, supplier bills, shipping terms and the allocation of qualifying inbound costs.
- 600 units sold and $18,000 of sales: order and fulfillment records, with revenue cutoff checked separately from payment dates.
- Ending 400 units and $5,000: inventory movement and valuation reports, count evidence and the general ledger. Investigate differences; a matching total alone does not prove the records are complete.
4. Record the exception before calling the close complete
If the inventory report shows $5,000 but the ledger shows $4,800, the $200 difference remains unresolved. Check the cost allocation, posting dates, missing receipts and duplicate entries. Record the evidence needed, the person responsible and the next review date. Do not post an unexplained $200 adjustment just to make the totals match.
The owner's question is practical: Can we trace this month's inventory and gross profit back to quantities, costs and sales records? A supported answer is more useful than a margin percentage on its own.
Cutoff matters: goods in transit and unallocated freight
Month-end inventory isn’t just “what’s on the shelf.” Two common cutoff failures:
- Goods in transit: assess ownership under the contract and shipping terms. Goods may belong in inventory before physical receipt, while a supplier deposit may remain a prepayment.
- Freight/duty paid but not allocated. Qualifying costs remain in an expense or suspense account rather than being allocated between inventory and goods sold. This can misstate inventory and the timing or presentation of expenses.
Fix: treat inbound costs like a close item, not a bookkeeping afterthought.
Inventory valuation: FIFO vs average vs LIFO (and what changes in write-downs)
Once you have landed cost, you still need a cost flow assumption to determine what hits COGS when you sell.
FIFO (First-In, First-Out)
Older costs flow to COGS first. Ending inventory reflects newer costs. Often aligns with physical flow. Can lag current costs when prices rise.
Weighted / moving average
Costs are pooled and blended. Smoother COGS, fewer big swings. Many ecommerce/ERP stacks default here.
LIFO (Last-In, First-Out)
Allowed under U.S. GAAP and U.S. tax, but adds complexity, specific disclosure requirements, and tax conformity considerations. Prohibited under IFRS. Many modern ecommerce stacks avoid it.
Why valuation method changes your “margin”
If costs are rising, FIFO often shows lower COGS (higher margin) because older, cheaper costs flow first. Average cost smooths. LIFO often pushes newer, higher costs into COGS sooner.
None of these are “the” right answer. What matters:
- Align the subledger’s cost method with the financial-reporting policy, or maintain a supported reconciliation between them.
- Apply consistently. Changes create non-comparable periods and can be an accounting change requiring support and disclosures.
- Know what write-down rule applies. For most inventory measured using FIFO/average, measurement is lower of cost and net realizable value. For LIFO and the retail inventory method, the measurement model differs.
For detailed setup and controls, see Inventory Accounting for ecommerce.
Returns: the COGS reversal that often never happens
When returns are material, two layers exist:
- For U.S. GAAP sales with a right of return, assess expected refunds and the right to recover returned goods at each reporting date. Keep the refund liability and return-recovery asset distinct and avoid recording an adjustment twice.
- Actual returns (operational execution). When goods come back, your systems must receive them and restore inventory (if resellable), or write them off / write them down if not.
Missing return receipts can leave inventory understated and cost of goods sold overstated, unless the expected recovery has already been recognized. Reconcile actual returns to the existing recovery balance.
Operational return flow (simplified)
- Return received, product resellable. Inventory impact: Recognize recovered inventory at the supported amount; settle any existing return-recovery asset; COGS impact: Reverse cost only if not already reflected in a return-recovery asset; avoid double counting
- Return received, product damaged/unsellable. Inventory impact: Recognize any supported remaining value and settle an existing return-recovery asset; COGS impact: Recognize required adjustments or losses without repeating a recovery already recorded
- Refund issued, product not returned (keep it). Inventory impact: No goods recovered; remove any return-recovery asset that is no longer supported; COGS impact: Original cost remains expensed, with an adjustment if recovery was previously recognized (treat the refund as a revenue/returns issue)
This table is the operational layer. For U.S. GAAP reporting, expected returns may require accrual estimates and a return-asset model. Your policy should match your facts and materiality.
Shrinkage, damage, and write-downs: adjustments that affect margin
Inventory isn’t static:
- Shrinkage: theft, loss, miscounts, receiving errors
- Damage: goods not sellable at full value
- Obsolescence: expired/outdated/no-demand inventory
Unrecorded shrinkage, damage or impairment can overstate inventory and distort cost of goods sold. Assess known issues promptly and retain the supporting calculation.
How to record adjustments (typical pattern)
- Debit: Inventory Shrinkage / Inventory Write-Down / COGS (policy + materiality)
- Credit: Inventory
Apply the relevant inventory measurement rule and consider any remaining salvage or recovery value. Write the amount down or off as supported by the facts.
The monthly inventory close process
This is the checklist that stops inventory from becoming a quarterly surprise.
Inventory month-end close checklist
- Check 1 Reconcile inventory subledger to GL. Tie the inventory valuation report (inventory system/ERP/3PL reports/FBA inventory if applicable) to the GL Inventory account. Investigate and document variances.
- Check 2 Confirm purchase/receiving cutoff. Make sure receipts, bills, and goods-in-transit are treated consistently based on your policy and shipping terms. Don’t let “timing” become a permanent recon item.
- Check 3 Allocate inbound costs (landed cost completeness). Identify inbound freight/duty/brokerage costs and confirm they are allocated into inventory cost (or accrued and allocated) rather than stranded in expense or suspense.
- Check 4 Sanity-check implied unit cost. Compare implied unit cost (COGS ÷ units sold) to expected landed cost ranges. Big deviations usually mean missing landed costs, wrong valuation settings, or return/shrink issues.
- Check 5 Process returns operationally. Confirm return receipts are recorded and resellable inventory is restored. Unsellable returns are written down or written off.
- Check 6 Record shrink/damage/write-downs. Book known shrinkage and review slow-moving/obsolete SKUs for write-down needs under the applicable measurement model.
- Check 7 Trend margin with reasons. Margin moved? Name the driver (mix shift, landed cost update, returns/shrink, valuation timing, promo/discounts). If you can’t explain it, you aren’t closed.
SKU-level margin: how deep to go (without unnecessary ledger detail)
Your GL should not have 500 SKU accounts. Your inventory system should have SKU-level cost and movement data.
Track at SKU level (in inventory/ERP)
- Landed cost per SKU (with a consistent allocation method)
- Units on hand, units sold
- Returns rate, damage/write-down history
- Days on hand / sell-through
Report at category level (in financials)
- Gross margin by category/product line
- COGS breakdown (product vs inbound freight/duties if material)
- Inventory by category for balance sheet analysis
Inventory reconciliation supports reliable margin analysis and helps identify where further records are needed.
Common inventory accounting failures
Failure 1: Inbound costs expensed instead of allocated
Inbound costs expensed instead of allocated to inventory can distort both the timing and presentation of margin. Review material costs at each close and make supported allocations.
Fix: Treat inbound costs as a close item: accrue/allocate into inventory cost consistently.
Failure 2: Inventory system not reconciling to the GL
The inventory tool shows one valuation; the GL shows another. Nobody reconciles; the gap grows until it’s material.
Fix: Monthly subledger-to-GL reconciliation. Investigate and document differences. Variances get explained or corrected.
Failure 3: COGS driven by cash timing
COGS recorded when you pay suppliers instead of when goods are sold. Margin then reflects payment timing, not sales performance.
Fix: COGS follows the sale via inventory accounting (perpetual or periodic), not the bill payment date.
Failure 4: No count discipline
Without cycle counts / physical counts, shrink and receiving errors accumulate until they explode.
Set a documented count program based on risk, systems and reporting needs. This may combine a physical count with regular cycle counts.
If landed costs, quantities or valuation methods lack support, reconstruct the affected periods before relying on new close procedures.
Completion checks
Landed
All material inbound costs allocated into inventory cost consistently
Reconciled
Inventory subledger ties to GL every month-end
Adjusted
Returns, shrink, and write-downs recorded timely and documented
Explainable
Margin movements have named drivers, not mystery variance
Supported inventory and cost schedules make margin a more useful management measure.
FAQ
What's the difference between FIFO and weighted average cost for ecommerce?
FIFO assumes older inventory costs flow to COGS first; weighted average blends costs across inventory. FIFO can lag current costs when costs are rising; average cost smooths swings. Both can be acceptable under U.S. GAAP if applied consistently and supported by your systems.
What costs should be included in landed cost?
Landed cost generally includes purchase price plus costs to bring inventory to its present location and condition for sale, commonly inbound freight/transportation-in, certain handling, nonrecoverable import duties/taxes and directly attributable acquisition costs, net of applicable discounts and credits. Costs incurred after inventory is in sellable condition (e.g., most storage/warehousing) are typically period expenses, depending on facts and policy.
Why doesn't my gross margin match what I expect from product pricing?
Common causes: missing landed costs, valuation method timing differences, returns not restoring inventory/COGS, shrink/damage not recorded, mix shifts, discounts, or comparing two different definitions (GAAP gross margin vs contribution-style margin that includes fulfillment/fees/shipping).
How do I handle inventory shrinkage and damage?
Record it when identified: debit an appropriate expense (shrink/write-down/COGS per policy/materiality) and credit Inventory. If goods are sellable at reduced value, write down using the applicable measurement model; write off the full amount only when no supported recoverable value remains.
Should I track margin by SKU or by category?
SKU-level for product decisions; category-level for financial reporting and management views. The GL summarizes; your inventory/ERP should hold SKU-level landed cost and movements.
How often should I reconcile inventory to the GL?
Monthly at minimum. Tie inventory valuation reports to the GL and explain variances. Add interim controls (weekly) if volume/value is high.
How Beamarc can help
Beamarc provides bookkeeping, monthly close, financial reporting and accounting advisory. We can discuss the records available, the questions you need answered and the support that fits your business. Scope, responsibilities, timing and fees are agreed before work begins.
Related reading
- Returns, refunds and chargebacks: getting cutoff right
- Amazon FBA accounting: settlements, fees and inventory
- Production orders: how much cash can you commit?
Authoritative guidance
General information only. Accounting and tax treatment depend on your facts and reporting framework. This article does not provide assurance or establish a client relationship.