Contribution margin is revenue minus variable costs. It measures how much money remains from sales to pay fixed costs and, once those fixed costs are covered, generate profit.
For an ecommerce brand, contribution margin closes the gap between a top-line metric such as revenue or ROAS and the cash a sale actually contributes. It accounts for costs that rise as orders rise: product costs, fulfillment, payment fees, returns, discounts, and any marketing spend your company treats as variable.
Use the free contribution margin calculator to calculate your result now, or continue for the formulas, examples, and operating decisions behind it.
What is contribution margin?
Contribution margin is the amount of revenue left after variable costs. It can be calculated for a company, channel, product, order, or customer cohort as long as revenue and costs use the same scope and time period.
The word contribution describes what the remaining revenue does: it contributes toward fixed costs such as salaries, office rent, software retainers, and insurance. After fixed costs are covered, additional contribution becomes operating profit.
A positive contribution margin does not automatically mean the company is profitable. A store can generate $40,000 of monthly contribution margin and still lose money if fixed costs are $50,000. A negative contribution margin is more urgent: under the same economics, each incremental sale increases the loss before fixed costs.
Contribution margin formula
The period formula is:
Contribution margin = Revenue - Total variable costs
The percentage formula is:
Contribution margin ratio = Contribution margin / Revenue × 100
A per-unit or per-order version uses the same logic:
Contribution margin per unit = Selling price per unit - Variable cost per unit
Use net revenue consistently. If your revenue input already deducts returns or discounts, do not subtract those items again as variable costs.
Period example
Suppose a Shopify store reports the following monthly totals:
| Item | Amount |
|---|---|
| Net revenue | $100,000 |
| COGS | $30,000 |
| Shipping and fulfillment | $8,000 |
| Payment processing | $3,000 |
| Variable marketing spend | $20,000 |
| Returns and other variable costs | $4,000 |
| Total variable costs | $65,000 |
Contribution margin is $100,000 - $65,000 = $35,000.
Contribution margin ratio is $35,000 / $100,000 × 100 = 35%. For every dollar of revenue, $0.35 remains to cover fixed costs and profit.
Per-order example
An order has $120 of net revenue, $36 of product cost, $12 of fulfillment and shipping, $4 of payment fees, $24 of allocated variable acquisition cost, and $4 of expected returns cost.
Total variable cost is $80. Contribution margin per order is $120 - $80 = $40, and the contribution margin ratio is 33.3%.
Per-order analysis is useful for comparing products, offers, customer types, and acquisition channels. Period analysis is useful for budgeting and tracking the blended business.
Which costs are variable in ecommerce?
A variable cost changes with sales or order volume. A fixed cost remains broadly stable over the relevant range and period. Real businesses also have mixed costs with both fixed and variable components.
| Cost category | Typical treatment | Important qualification |
|---|---|---|
| Product and manufacturing costs | Variable | Include landed product costs consistently. |
| Packaging | Variable | Include per-order or per-unit packaging. |
| Pick-and-pack fees | Variable | Storage minimums may be fixed. |
| Outbound shipping | Often variable | Policy varies when customers pay shipping. |
| Payment processing | Variable | Fixed monthly gateway fees are not variable. |
| Returns and refunds | Variable | Do not double count amounts already netted from revenue. |
| Sales commissions | Variable | Include the portion tied to sales. |
| Performance marketing | Policy-dependent | Include when spend scales with acquisition; separate fixed brand spend or retainers. |
| Salaries, rent, insurance | Usually fixed | They belong below contribution margin. |
There is no single contribution-margin definition enforced across every company. Some finance teams calculate contribution margin before marketing; operators may use a second level after variable acquisition spend. Either can be useful. Name each level, document the cost policy, and keep it consistent so comparisons remain meaningful.
Contribution margin ratio
Contribution margin dollars answer, “How much is available to cover fixed costs?” The ratio answers, “How efficiently does revenue create that contribution?”
Ratios make different periods and products easier to compare. A $50,000 contribution margin on $200,000 of revenue is 25%; $40,000 on $100,000 is 40%. The first period creates more contribution dollars, but the second converts revenue into contribution more efficiently.
Use both views. A high ratio on a low-volume product may not cover enough fixed costs, while a lower ratio on a high-volume product may create more total contribution.
What is a good contribution margin for ecommerce?
A good contribution margin depends on category, average order value, repeat purchase behavior, growth stage, and the costs included in your definition. A replenishable product with strong repeat purchases can support different first-order economics from a one-time purchase business.
Use Amp’s ecommerce contribution margin benchmarks to compare against similar stores. Treat a benchmark as context, not permission to ignore your own fixed-cost base, cash constraints, or customer payback period.
The most useful signals are:
- Is contribution margin positive?
- Does total contribution cover fixed costs?
- Is the ratio improving on a consistent definition?
- Which products, channels, and cohorts create or destroy contribution?
- How quickly does customer contribution repay acquisition cost?
Contribution margin vs gross margin, net margin, and profit
Gross margin subtracts COGS from revenue. Contribution margin subtracts all costs classified as variable. Net margin subtracts variable and fixed operating costs, interest, and taxes according to the company’s reporting policy.
| Metric | Core calculation | Best used for |
|---|---|---|
| Gross margin | Revenue - COGS | Product pricing and sourcing |
| Contribution margin | Revenue - all defined variable costs | Acquisition, offers, channels, and break-even decisions |
| Net margin | Revenue - all expenses | Overall company profitability |
Read the full contribution margin vs gross margin comparison for cost-by-cost treatment and a worked ecommerce example. Use the profit margin calculator when you need gross, operating, and net margin views.
How to improve contribution margin
Improve price and product mix
Test price changes where customer value supports them. Promote products and bundles with stronger contribution dollars, not merely higher revenue or gross margin. Include discounts in scenario planning before launching an offer.
Reduce landed product cost
Negotiate supplier tiers, redesign packaging, reduce waste, and compare production or freight options. A dollar removed from variable cost adds a dollar to contribution margin when price and volume remain unchanged.
Reduce fulfillment and payment leakage
Review 3PL pick fees, packaging dimensions, carrier zones, payment methods, and cross-border charges. Separate fixed minimums from truly variable charges.
Manage returns by product and cohort
Blended return rates can hide products, sizes, or channels that destroy contribution. Improve product information, sizing, quality control, and return routing where the economics justify it.
Set acquisition limits from contribution, not revenue
ROAS ignores product and order costs. Before scaling a campaign, calculate how much contribution remains after acquisition and how long repeat-order contribution takes to repay CAC. This creates a defensible ceiling for bids and promotions.
Using contribution margin for CAC and break-even decisions
Contribution margin connects customer acquisition to break-even math. If a new customer’s first-order contribution before acquisition cost is $30 and CAC is $45, the first order leaves $15 of CAC unrecovered. That may still be rational if reliable repeat contribution repays the remaining $15 within an acceptable period. If your contribution-margin definition already includes acquisition spend, do not subtract CAC again.
For company break-even, divide fixed costs by contribution margin per unit or use a weighted margin across the expected product mix. The break-even calculator converts these inputs into required sales volume.
Track contribution by product, channel, first-time versus returning customer, and cohort. Lifetimely profit analytics brings Shopify revenue, COGS, shipping, transaction fees, marketing, and customer data together so teams can evaluate the unit economics without rebuilding a spreadsheet each month.
Contribution margin checklist
- Use the same period and scope for revenue and costs.
- Do not count refunds or discounts twice.
- Document whether shipping and marketing are variable.
- Separate fixed and variable portions of mixed costs.
- Review both contribution dollars and contribution margin ratio.
- Segment the result by product, channel, offer, and customer cohort.
- Reconcile the operating metric with your finance team’s reporting policy.
Start with the contribution margin calculator, then compare your result with the contribution margin benchmark.

AMP Team
AMP builds tools for Shopify brands to uncover profit opportunities and drive measurable growth.