How to Calculate Contribution Margin (Formula + Ecommerce Examples)
Learn how to calculate contribution margin with a simple formula and real ecommerce examples โ and why it's the metric that tells you if a product actually makes money.
How to Calculate Contribution Margin (Formula + Ecommerce Examples)
If you only track one profit metric, make it contribution margin. It tells you how much each sale contributes toward covering your fixed costs and generating profit โ which makes it the clearest signal of whether a product is actually worth selling. This guide covers the contribution margin formula, how to calculate it, and real ecommerce examples.
Quick answer: Contribution margin = Sales revenue โ Variable costs. Per unit, it's the selling price minus the variable cost of that unit (product cost, shipping, transaction fees, etc.). Whatever's left "contributes" to covering fixed costs and profit.
What is contribution margin?
Contribution margin is the money left from a sale after variable costs, available to cover your fixed costs (rent, software, salaries) and then become profit.
- Variable costs change with each sale: product/COGS, shipping, payment/transaction fees, pick-and-pack, per-order app fees.
- Fixed costs stay roughly the same regardless of sales: your Shopify plan, subscriptions, rent, salaries.
Contribution margin isolates the per-sale economics so you can see which products pull their weight.
The contribution margin formula
Total contribution margin:
Contribution Margin = Total Sales Revenue โ Total Variable Costs
Per unit:
Contribution Margin per Unit = Selling Price โ Variable Cost per Unit
As a ratio (percentage):
Contribution Margin Ratio = (Contribution Margin รท Sales Revenue) ร 100
How to calculate contribution margin (step by step)
- Take your selling price (per unit).
- Add up all variable costs for that unit โ product cost, shipping, transaction fees, and any per-order costs.
- Subtract variable costs from the price โ that's your contribution margin per unit.
- Divide by the selling price โ that's your contribution margin ratio.
Ecommerce example
Say you sell a product for $40:
| Item | Amount |
|---|---|
| Selling price | $40.00 |
| Product cost (COGS) | โ$14.00 |
| Shipping | โ$6.00 |
| Transaction fee (~3%) | โ$1.20 |
| Pick & pack | โ$1.00 |
| Variable costs total | โ$22.20 |
| Contribution margin | $17.80 |
| Contribution margin ratio | 44.5% |
So every unit contributes $17.80 toward fixed costs and profit. If your fixed costs are $1,780/month, you need to sell 100 units to break even โ then every unit after that is profit.
Why contribution margin matters more than gross profit
Gross profit only subtracts COGS. Contribution margin subtracts all variable costs โ shipping, fees, and fulfillment included โ so it reflects what a sale really leaves you. A product can look healthy on gross margin and still have a weak contribution margin once shipping and fees are counted.
Use contribution margin to:
- Identify your most profitable products (highest contribution, not highest revenue).
- Set prices and discount floors that still contribute.
- Find your break-even point (fixed costs รท contribution margin per unit).
- Decide which products to scale or cut.
Contribution margin vs other metrics
| Metric | Subtracts | Tells you |
|---|---|---|
| Gross profit | COGS only | Basic product profitability |
| Contribution margin | All variable costs | True per-sale contribution |
| Net profit | All costs (variable + fixed) | Bottom-line profit |
Track contribution margin automatically
Calculating contribution margin by hand for one product is easy โ doing it across your whole catalog, every day, as costs and fees change, is not. That's where most sellers lose track and keep scaling products that barely contribute.
Syncost automatically calculates contribution margin and true net profit for every product and order โ pulling in COGS, shipping, fees, and ad spend โ so you always know which products are actually carrying your store.
Try Syncost free and see your real contribution margin per product.
FAQ
What is the contribution margin formula? Contribution Margin = Sales Revenue โ Variable Costs. Per unit, it's Selling Price โ Variable Cost per Unit.
What's the difference between contribution margin and gross profit? Gross profit subtracts only COGS. Contribution margin subtracts all variable costs (COGS plus shipping, fees, fulfillment), so it's a truer measure of what each sale contributes.
What is a good contribution margin? It varies by business, but a higher ratio is better. Many ecommerce sellers aim for a contribution margin ratio that comfortably covers fixed costs with room for profit โ often 30%+ depending on the model.
How do I use contribution margin to find break-even? Divide your total fixed costs by your contribution margin per unit. That's how many units you must sell to cover fixed costs; every unit after that is profit.