Contribution margin: the formula that sets your ad budget

Updated · 8 min read

The short answer

Contribution margin is what's left of each sale after every cost that rises with it: product cost, shipping, fulfillment, payment fees, discounts and returns. The formula is (revenue − variable costs) ÷ revenue. A $60 order with $31.04 in variable costs has a 48% contribution margin, which means a break-even ROAS of 2.07 and a break-even CPA of $28.96.

Contribution margin is what's left of each sale after every cost that rises with that sale: product cost, shipping, fulfillment, payment fees and returns. The formula is (net revenue − variable costs) ÷ net revenue. On a $60 order with $31.04 in variable costs, contribution margin is $28.96, or 48%. Measured before ad spend, that number sets your break-even ROAS and CPA.

What is contribution margin?

Contribution margin is the share of revenue that's left to pay for marketing, fixed costs and profit once the costs of making and delivering each order are covered. Fixed costs like salaries, rent and most software don't count, because they don't change when you sell one more unit. If a contract has a per-order charge, that part is variable. For an ecommerce brand, it's the most useful single number for deciding how much you can pay to get an order.

You can state it two ways: as dollars per order (contribution per order) or as a percentage of revenue (contribution margin ratio). You'll need both. The dollar figure sets your break-even CPA. The percentage sets your break-even ROAS.

What is the contribution margin formula?

The contribution margin formula is:

  • Contribution per unit or per order = net revenue − variable costs
  • Contribution margin (%) = (net revenue − variable costs) ÷ net revenue

Net revenue is the product price after discount codes, before refunds. Discounts reduce revenue here, so they don't appear again as a cost. Variable costs are every cost that scales with orders: cost of goods, packaging, shipping you pay, pick-and-pack fees, payment processing, and an allowance for refunds and returns. Leave ad spend out for now. The result is contribution margin before marketing, the version that sets ad targets.

How do you calculate contribution margin for a DTC order?

List every cost one order triggers, then subtract them from what the customer paid. Here's an illustrative order for a brand that offers free shipping and uses a third-party warehouse:

Line item Per order Note
List price $64.00 Before discounts
Discount code −$4.00 Welcome offer
Net revenue $60.00 What the customer paid for product
Cost of goods −$15.00 Product plus packaging
Shipping −$7.00 Free shipping, so the brand pays
Fulfillment −$4.00 Pick, pack and warehouse fees
Payment fees −$2.04 2.9% + 30¢ on $60
Refunds and returns −$3.00 5% allowance for refunds and unrecovered return costs
Contribution before marketing $28.96 48.3% of net revenue

The payment fee uses the 2.9% + 30¢ US standard online card rate on Shopify's Basic plan; the Grow and Advanced plans list 2.7% + 30¢ and 2.5% + 30¢. Premium and international cards cost more. The returns line is the one most brands guess at. Use your own refund data, net of any returned stock you can resell. For context, the National Retail Federation and Happy Returns estimated that 19.3% of US online sales would be returned in 2025, across all of retail. That's the share of sales sent back, not the cost to you: resold stock brings part of it back.

What is contribution margin before and after marketing?

Contribution margin before marketing excludes ad spend, and contribution margin after marketing subtracts it. The first tells you how much you can afford to spend to win an order. The second tells you how much you actually kept.

Take the order above at 1,000 orders a month and a $20 cost per acquisition:

Monthly, 1,000 orders Amount Per order
Net revenue $60,000 $60.00
Variable costs −$31,040 −$31.04
Contribution before marketing $28,960 $28.96 (48.3%)
Ad spend −$20,000 −$20.00
Contribution after marketing $8,960 $8.96 (14.9%)

Salaries, rent, software and agency fees still come out of that $8,960. If they total more, the brand loses money even though every order "made money" before ads. Track contribution after marketing monthly. It's the cleanest view of whether growth is paying for itself.

How does contribution margin set break-even ROAS and CPA?

Break-even ROAS is 1 divided by contribution margin before marketing, and break-even CPA is average order value times that margin. Both are first-order break-even points, before fixed costs, and assume each new customer places one order. Both come straight from the table above:

  • Break-even ROAS = 1 ÷ 0.483 = 2.07. Each $1 in ads needs $2.07 in sales to cover its own cost on the first order.
  • Break-even CPA = $60 × 0.483 = $28.96. Pay more than that to win a new customer's first order and you lose money on it.

The $20 CPA in the example works out to a 3.0 ROAS ($60,000 ÷ $20,000), comfortably above 2.07. If the CPA rose to $30, ROAS would fall to 2.0 and every first order would lose about $1. You can run your own numbers in the break-even CPA calculator, and see how break-even changes across margins in what a good ROAS is.

Break-even is the floor, not the target. Set your target ROAS above it, with room for fixed costs, profit and measurement error. If customers reorder, you can pay above break-even on the first purchase and earn it back later, as long as you know how fast they come back and can fund the gap.

What is the difference between contribution margin and gross margin?

Gross margin subtracts cost of goods sold, while contribution margin subtracts every variable cost. What counts as cost of goods depends on your accounting setup, but shipping, fulfillment and payment fees usually sit outside it. Shopify's gross profit reports, for example, calculate net sales minus recorded product cost, which makes each order look healthier than it is.

Gross margin Contribution margin
Subtracts Cost of goods sold Cost of goods, shipping, fulfillment, payment fees, returns
Example order ($60) $45.00 (75%) $28.96 (48.3%)
Implied break-even ROAS 1.33 2.07
Implied break-even CPA $45.00 $28.96
Best used for Pricing and supplier talks Ad budgets and bid targets

The gap is where brands get hurt. Judged against the 75% gross margin, a campaign at 1.5 ROAS looks profitable. On $1,000 in spend it brings $1,500 in sales and $724 in contribution, a $276 loss before fixed costs. Gross margin alone can't tell you whether ads pay. Set ROAS and CPA targets from contribution margin, never gross margin.

How do you check contribution margin against MER?

Compare your blended MER, total revenue divided by total marketing spend, with your break-even ROAS. Count the same costs on both sides: if MER includes agency fees, creative and tools, it's a stricter test than media-only ROAS. At a 48.3% contribution margin, an MER of 2.07 means marketing is eating all contribution. Anything above it leaves money for fixed costs and profit. MER also includes repeat and organic sales, so a healthy MER can hide new-customer ads that lose money. Check new-customer CPA too. Platform ROAS can double-count sales across Meta, Google and TikTok, so MER, pulled from your store and your invoices, is the safer number to hold against contribution margin. The full comparison is in MER vs ROAS.

How do you raise contribution margin?

  • Raise average order value. Shipping, fulfillment and the 30¢ payment fee are mostly per order, so bundles and free-shipping thresholds spread them across more revenue.
  • Cut discount depth. A $4 code on a $64 order removes $4 of contribution, about 14% of the $28.96.
  • Renegotiate shipping and 3PL rates once volume grows. A $1 saving per order lifts margin by 1.7 points on a $60 order.
  • Reduce returns with better sizing guides, product photos and clear descriptions.
  • Review cost of goods with suppliers at each reorder.

Every point of contribution margin lowers break-even ROAS, which gives the ads more room to scale.

Final thoughts

Work out contribution margin per order before you set any ad budget, then turn it into a break-even ROAS and CPA. To see where those targets fit in a 90-day plan, read our guide to startup marketing strategy. If you want a team that sets targets from your real margins and manages every channel to one MER number, see Wadabu's paid ads service.

Frequently asked questions

What is the contribution margin formula?

The contribution margin formula is (net revenue − variable costs) ÷ net revenue. Net revenue is after discounts. Variable costs include cost of goods, shipping, fulfillment, payment fees and returns. A $60 order with $31.04 in variable costs has a contribution of $28.96, which is a contribution margin of about 48%.

What is a good contribution margin for ecommerce?

A good contribution margin for ecommerce is one high enough to pay for customer acquisition and fixed costs. At 50%, break-even ROAS is 2.0; at 30%, it's 3.33. Lower margins need either cheaper customers or strong repeat purchases, so judge contribution margin against real acquisition costs.

Is contribution margin the same as gross margin?

Contribution margin is not the same as gross margin. Gross margin subtracts cost of goods sold. Contribution margin also subtracts shipping, fulfillment, payment fees and returns. A $60 order can show a 75% gross margin and a 48% contribution margin, which changes break-even ROAS from 1.33 to 2.07.

Does contribution margin include customer acquisition cost?

Contribution margin before marketing does not include customer acquisition cost. That version sets break-even ROAS and CPA. Contribution margin after marketing subtracts ad spend, and shows what is left for fixed costs and profit. On a $60 order with $28.96 of contribution, a $20 CPA leaves $8.96.

Payment fees: Shopify pricing page (online card rates, accessed October 2026). Returns: National Retail Federation and Happy Returns 2025 returns report (published October 15, 2025). Shopify gross profit reports: Shopify Help Center.

Written by Andrew Zam, Founder of Wadabu, a growth marketing agency for consumer-brand startups.

Want a plan for your brand?

Tell us where you are and where you want to be. We'll set up a quick call and map out your next moves.