Contribution Margin Calculator

Work out what each order leaves after products, shipping, fulfilment, payment fees, tax and ad spend.

Your numbers per order

Use averages for a typical order. Leave a field blank if it does not apply.

What the customer pays for the products in one order, after discounts.

Leave blank if you offer free shipping.

The VAT or sales tax rate included in the order value and shipping charged. Leave blank if your prices exclude tax, as US prices usually do.

What you pay suppliers for the products in the order, without any VAT you can reclaim.

Postage paid to the carrier for the order.

Pick-and-pack, 3PL and packaging costs per order.

The percentage your payment provider charges: 2.9 for a 2.9% + 30¢ card rate.

The fixed part of the payment fee: 0.30 for a 2.9% + 30¢ card rate.

Your average cost to win an order (CPA). Leave blank to see your margin before marketing.

Your contribution margin

Enter your order value to see your contribution margin.

What is contribution margin?

Contribution margin is the money an order leaves once every cost that comes with it is paid: the product, shipping, fulfilment, payment fees and tax, and the ad spend it took to win the order. What is left contributes to your fixed costs, such as salaries, rent and software, and then to profit.

E-commerce teams often split it into levels. Contribution margin before marketing (sometimes called CM2) covers the costs of making and delivering the order. Contribution margin after marketing (CM3) also takes off ad spend. This calculator shows both.

How contribution margin is calculated

The calculator adds up what the customer pays (the order value and any shipping charged) and removes the tax included in it, by dividing by 1 plus the tax rate. It works out the payment fee on the full amount the customer pays, because that is what your payment provider charges on.

Contribution margin = revenue before tax − product cost − shipping cost − fulfilment − payment fees − ad spend

Dividing the result by revenue before tax gives your contribution margin as a percentage. Leave ad spend blank to see your contribution margin before marketing.

How to use your contribution margin

  • Check that it covers your fixed costs. Multiply your contribution margin per order by your orders in a month and compare the result with your monthly fixed costs.
  • Use your margin before ad spend to set your ad budget. It is the most you can pay to win an order before that order loses money, your breakeven CPA.
  • Compare products and channels. A best-selling product with a thin margin can earn less than a smaller one with a healthy margin.
  • Recalculate when costs change: supplier prices, carrier rates, payment fees and discounts all move it.

Worked example

Revenue before tax (order value and shipping charged)$65.00
Payment fees$1.60
Costs per order (product, shipping, fulfilment, fees)$32.60
Contribution margin before ads$32.40
Ad spend per order$12.00
Contribution margin after ads$20.40 (31.4%)

A customer pays $60 for the products and $5 for shipping, with no tax included. The products cost $22, postage $6 and fulfilment $3. The payment fee is 2% of $65 plus $0.30, which is $1.60, so the order costs $32.60 before ads.

Contribution margin before ads = 65 − 32.60 = $32.40. The store spent $12 on ads to win the order, so its contribution margin after ads is $20.40, 31.4% of revenue.

Frequently asked questions

What is the difference between contribution margin and gross margin?

Gross margin usually takes off only the cost of the products. Contribution margin also takes off the other costs every order brings, such as shipping, fulfilment, payment fees and, after marketing, ad spend, so it shows what an order really leaves.

Should I include ad spend?

Include it to see your contribution margin after marketing, the figure that has to cover your fixed costs. Leave it blank to see your margin before marketing, which is the most you can spend on ads to win an order and still break even on it.

How do I handle VAT or sales tax?

Tax collected from the customer goes to the government, so it is not revenue. If your prices include VAT, enter the rate and the calculator removes it. US prices usually exclude sales tax, so leave the rate blank. Enter costs without any VAT you can reclaim.

What is a good contribution margin for e-commerce?

There is no single figure: it depends on your prices, product costs and ad spend. What matters is that your contribution margin per order, multiplied by your orders, covers your fixed costs and leaves a profit.

Why is my contribution margin negative?

The order costs more than it brings in. Common causes are ad spend per order above the margin before ads, free shipping on low-value orders and heavy discounts. Check which cost is largest and start there.

Free playbook

The Q4 Profit Playbook

The 5 analyses to run 60 days before Black Friday, in a 36-page guide.

Customer value, creative, promotions, product and Q5, each step by step, with a Q4 planning worksheet.

Get the free playbook

See the real ROAS of every campaign.

StoreHero tracks contribution margin and blended ROAS across Meta, Google and TikTok every day, so you see which campaigns make money.