Contribution margin: formula, meaning and a worked example
How to calculate contribution margin per unit and in total, with VAT, shipping and payment fees worked through on one webshop product.
Contribution margin is the amount left of the selling price once the variable costs of the sale have been deducted. In Danish it is called dækningsbidrag, often shortened to DB. It is the money that has to cover rent, salaries, marketing and other fixed costs, and whatever remains after that becomes profit. This guide explains what contribution margin means, how the formula works per unit and in total, and how to calculate it correctly in a Danish webshop where prices are shown including VAT.
What contribution margin means and how the formula works
The formula is short:
Contribution margin = revenue − variable costs
Variable costs are the costs that rise and fall with the number of items sold. In a webshop they are typically:
- the cost price of the product
- shipping that you pay yourself
- payment fees to the card acquirer or payment provider
- packaging
- commission to a marketplace or affiliate partner, if any
Rent, salaries, subscriptions and advertising budgets are fixed costs in this context, because they do not change when you sell one more item.
You can calculate the contribution margin at two levels. Contribution margin per unit is the selling price excluding VAT minus the variable costs of one item. Total contribution margin is the per-unit figure multiplied by the number of units sold, or the total revenue excluding VAT minus the total variable costs for a period.
How to handle VAT when you calculate contribution margin
VAT is not your revenue. It is an amount you collect on behalf of the state, so contribution margin must always be calculated on prices excluding VAT. Danish webshops show prices including 25 % VAT, which means the selling price has to be divided by 1.25 before you deduct any costs.
Example. The numbers below are made up to show the method.
An electric kettle sells for DKK 499 including VAT. The cost price is DKK 240 excluding VAT. You pay the DKK 39 shipping yourself, packaging costs DKK 5, and the payment fee is about DKK 7 per order.
| Item | Amount excl. VAT |
|---|---|
| Selling price (499 ÷ 1.25) | DKK 399.20 |
| Cost price | −DKK 240.00 |
| Shipping | −DKK 39.00 |
| Payment fee | −DKK 7.00 |
| Packaging | −DKK 5.00 |
| Contribution margin per unit | DKK 108.20 |
If you sell 120 kettles a month, the total contribution margin is 120 × 108.20 = DKK 12,984.
Had you used the price including VAT, the contribution margin would appear to be DKK 208 per unit. The difference of DKK 99.80 is exactly the VAT, and that mistake makes a product look almost twice as profitable as it is.
Shipping and fees matter as well. If you only deduct the cost price, you get DKK 159.20, which is sometimes called the gross profit on the product. Once shipping, fees and packaging are included, the amount drops to DKK 108.20, and that is the figure that actually pays for your fixed costs.
Use the calculator on this page to enter your own figures for price, cost price and variable costs.
How contribution margin relates to the margin percentage
Contribution margin is an amount in kroner. The contribution margin ratio, called dækningsgrad in Danish, is the same amount expressed as a percentage of revenue excluding VAT:
Margin % = contribution margin ÷ revenue × 100
For the kettle the ratio is 108.20 ÷ 399.20 × 100 = 27.1 %. The percentage is useful when you compare products at different price levels, while the amount in kroner shows how much each product actually contributes. The guide to gross margin covers the percentage in more detail, and the guide to markup explains how it differs from a markup on the cost price.
Use contribution margin before you lower a price
A price cut hits the contribution margin harder than most people expect, because the variable costs stay the same whatever you charge for the product.
If the kettle is reduced from DKK 499 to DKK 449 including VAT, the price excluding VAT becomes DKK 359.20. The variable costs are still DKK 291, so the contribution margin per unit falls from DKK 108.20 to DKK 68.20. The price has fallen by 10 %, while the contribution margin has fallen by 37 %.
To earn the same DKK 12,984 a month, you now need to sell 12,984 ÷ 68.20 = 190.4 units, which means 191 kettles instead of 120. That is a 59 % increase in sales. Before you lower a price to follow a competitor, it is worth asking whether the lower price can realistically bring in that much extra volume.
The same calculation shows where your floor is. At a price of DKK 291 excluding VAT, or DKK 363.75 including VAT, the contribution margin is zero and each sale contributes nothing to fixed costs. A sensible minimum price sits some way above that point, and the guide on setting a minimum price from your cost price shows how to work it out.
Common mistakes in contribution margin calculations
- The selling price is used including VAT, so the contribution margin is overstated by the full VAT amount.
- Shipping and payment fees are left out, even though they come with every order.
- The cost price is out of date and does not reflect the latest purchase price.
- Free shipping above a threshold is ignored, even though you pay the shipping on those orders.
- Discount codes and campaign prices are forgotten when the contribution margin for a period is calculated from the regular price.
When competitors put pressure on your price
Contribution margin is the figure that should decide how far down you are willing to go. Corprice checks competitors’ prices daily from PriceRunner, Prisjagt and webshops and suggests minimum and maximum prices from your cost prices, so pricing rules stay within limits you have approved. Read more on the repricing page.
Contribution margin calculator
Change the numbers and the result updates. Nothing is sent anywhere.
- Sales price excl. VAT
- –
- Contribution margin per unit
- –
- Gross margin (DB / price)
- –