MyDeko sold its bestseller, a soap rose in a paper cone, for 119 CZK. After goods, materials and ads there was nothing left on it, and in March 2026 the whole store’s margin after advertising was −25%. The campaigns weren’t broken. At that price, ads simply couldn’t pay for themselves.
Most stores know their margin as a single number from the books or from supplier prices. For advertising that number is almost always higher than the truth. This article shows how to calculate margin step by step, why gross and true margin differ by tens of percent, and how to derive from the true one the line below which ads lose money.
Terms in this article
Six terms this article works with. Each is in the glossary with a formula and an example.
- Margin
How much of the selling price is left after the cost of goods.↗ - Markup
The same amount added on top of cost. Always higher from the same numbers.↗ - Break-even ROAS
The return at which ads exactly pay for themselves from margin.↗ - ACoS
Ad cost as a share of revenue. The maximum equals your margin.↗ - CPA
Cost of one order from ads.↗ - POAS
Profit from ads divided by ad cost. Measures margin, not revenue.↗
How to calculate margin: formula and a worked example
Margin % = (selling price − cost price) ÷ selling price × 100. Use both prices without VAT. Sell an item for 1,000 CZK excluding VAT that cost you 600 CZK, and the margin is 400 CZK, or 40%.
That’s gross margin. It tells you how much of the price is left once the goods are paid for. It’s enough for accounting and for comparing products. It isn’t enough to decide how much you can spend on ads — because between “goods paid” and “money for ads” there’s still VAT, shipping, the payment gateway, packaging, returns and discounts.
So we calculate two margins:
- Gross margin = (price excl. VAT − cost price) ÷ price excl. VAT.
- True margin = profit per order before ads ÷ price excl. VAT. Profit before ads is gross margin in money minus everything each order costs: shipping and packaging the customer doesn’t pay for, the payment fee, and the margin lost on returns.
We divide true margin by the same revenue excl. VAT that the ad platform sees. That way the ad limits fall straight out of it: maximum ACoS equals true margin, and break-even ROAS is its inverse.
Eleven percentage points looks harmless. In advertising it means break-even ROAS isn’t 250% but 345%. A campaign running at 300% ROAS that looks profitable on gross margin actually loses money on every order.
How to turn margin into a maximum cost per order and a target cost per conversion is covered in Maximum cost per order.
Calculator: true margin per order
Enter your average order. The calculator works out gross and true margin and the ad limits that follow. It assumes you send conversion values to Google Ads excluding VAT and that the ad platform doesn’t know about returns — it credits itself with the full order.
If you aren’t VAT-registered, set the rate to zero and enter cost of goods including the VAT you can’t reclaim. The calculator assumes returned goods go back into stock and sell again. If they come back damaged, your true margin is lower still.
Margin vs. markup: two numbers from the same prices
The most common mistake in calculating margin isn’t the maths, it’s the term. Markup is divided by cost price, margin by selling price. From the same numbers, markup always comes out higher. An item bought for 600 and sold for 1,000 excluding VAT has a 67% markup and a 40% margin.
When a supplier says “you make 50% on it”, they almost always mean markup. Your margin is then 33%, not 50%. And the break-even line for ads is calculated from margin.
| Markup | Margin | Break-even ROAS | Max ACoS |
|---|---|---|---|
| 25% | 20% | 500% | 20% |
| 33% | 25% | 400% | 25% |
| 43% | 30% | 333% | 30% |
| 67% | 40% | 250% | 40% |
| 100% | 50% | 200% | 50% |
Conversion: margin = markup ÷ (100 + markup) × 100. Markup = margin ÷ (100 − margin) × 100. The table uses gross margin. With true margin, break-even ROAS moves higher.
Why gross margin lies: VAT, shipping, payments, returns, discounts
Each of these items is small. Together they routinely take a tenth of the price or more off your margin. Go through them on your own average order.
Margin from VAT-inclusive prices: the most common mistake
A VAT-registered business passes VAT on to the state, so it doesn’t count towards margin. Calculate margin from the VAT-inclusive price and you overstate it. An item at 1,210 incl. VAT that cost 600 excl. VAT has a 40% margin, not 50%. Czechia has had two VAT rates since 2024, 21% and 12%; other countries differ, the principle doesn’t.
The same goes for ads. If your store sends order values to Google Ads including VAT, ROAS and ACoS look a fifth better than they are. You then need to multiply break-even ROAS by 1.21. The calculator above spells this out when you set VAT.
Free shipping and packaging
Free shipping isn’t free — the store pays for it out of margin. Count only the difference between what the carrier charges you and what the customer pays. Add the box, filler and packing time. On cheap items this is the most expensive line of the whole order.
Payments
Payment gateways take a percentage of the full amount including VAT; cash on delivery a fixed fee. The percentage looks negligible until you compare it with margin: a 1.5% fee on the VAT-inclusive price is almost a tenth of the whole margin on an item with 20% margin.
Returns and cancellations
A returned order stays in Google Ads as a conversion with its full value. You lose the margin on it, and you paid for outbound shipping anyway. At Klenoty Mahdal we therefore count ACoS including cancellations and returns — see the case study, where it fell from 70% to 14%.
Discounts and promo codes
A discount comes off the price, but cost price stays put. So it takes far more out of margin than its percentage suggests. How much, the second calculator below shows.
Profit margin formula: the margin you pay for ads from
Here’s the process for an average order. Take the numbers from your store admin for the last 90 days, not one month.
- Average order value excl. VAT. Revenue excl. VAT ÷ number of orders.
- Average cost of goods per order. If you don’t have it per order, use cost of goods sold ÷ number of orders.
- Gross margin in money = step 1 − step 2.
- Loss on returns = gross margin × share of returned orders.
- Per-order costs = shipping and packaging beyond what the customer pays + payment fee.
- Profit before ads = step 3 − step 4 − step 5.
- True margin = step 6 ÷ step 1 × 100.
In the chart example: 1,000 − 600 = 400 gross margin, returns at 8% = 32, shipping and packaging 60, payment 1.5% of 1,210 = 18. Profit before ads is 290, true margin 29%.
Calculate per order, not per product. Shipping and payment are paid once per basket, so an order with two items has a higher true margin than an order with one. That’s why basket add-ons help: MyDeko has five of them (19–591 CZK), and its average order in September was 59% higher than in March.
You don’t pay for ads from the margin in your price list. You pay from what’s left after the last box, fee and returned parcel.
The rule we set campaign targets by
From true margin to break-even ROAS, max ACoS and max CPA
Once you know true margin, the ad limits are three simple calculations:
- Break-even ROAS = 100 ÷ true margin × 100. At 29% that’s 345%.
- Max ACoS = true margin. Ads may cost at most 29% of the revenue they bring in.
- Max CPA = profit before ads in money. You can pay at most 290 CZK per order.
All three are zero-profit lines, not targets. You set target ROAS higher so something is left after ads. If you want to keep 10% of revenue, subtract it from true margin: 29 − 10 = 19%, target ROAS 526%.
If you want to measure profit directly rather than revenue, the next step is POAS: profit from orders divided by ad cost. Google Ads can report gross profit from ads when you send it cart data and have cost of goods on products in Merchant Center (the cost_of_goods_sold attribute). It doesn’t know about shipping, payments or returns, though — you have to account for those yourself. Why higher ROAS doesn’t have to mean higher profit, we cover in When 400% ROAS beats 500% ROAS.
Discounts and sales: how much more you need to sell
A 15% discount doesn’t shrink your margin by 15% of itself. It takes 15 percentage points off the price while cost price stays the same. On an item with a 30% true margin, only half the profit per unit is left after the discount, so you have to sell twice as many units to earn the same. And the campaign’s break-even ROAS jumps during the sale.
The calculator assumes the discount applies to the full price and that cost of goods, shipping and packaging stay the same. If a sale also lowers your free-shipping threshold, the real impact is worse. You could see it in Vše pro pejska’s winter season: orders grew while margin as a percentage fell — more on that in the mistakes section.
What to charge: price from a target margin
The reverse calculation is just as simple. For a 35% true margin, price excl. VAT = (cost price + per-order costs) ÷ (1 − 0.35). Payment fees and returns, which grow with price, belong in the target margin.
Example: cost 600 CZK, shipping and packaging 60 CZK. (600 + 60) ÷ 0.65 = 1,015 CZK excl. VAT, or 1,229 CZK at 21% VAT. Round to a price customers will accept and check the result in the calculator above.
Price is the strongest lever on margin and the least used one in e-commerce. At MyDeko we raised the bestseller from 119 to 219 CZK in seven steps (119, 139, 149, 159, 179, 197, 219) and the conversion rate held. Without that, ads wouldn’t have paid for themselves — no campaign setting would have changed it.
Margin in Google Ads and PMax: labels in the feed
Your store’s average margin is a good start. But ads sell specific products, and those have different margins. Performance Max with one target ROAS optimizes for revenue, not margin: a thousand from a 45%-margin product is the same to it as a thousand from a 15%-margin product.
The fix is to put margin into the product feed. Merchant Center has five custom labels (custom_label_0 to custom_label_4); shoppers don’t see them, and Performance Max and Shopping campaigns can group products by them. We use one label for true-margin bands, for example “margin-under-20”, “margin-20-35”, “margin-over-35”.
- Download the template on the left (CSV) and fill in products or categories: price, VAT rate, cost price, per-order costs, payment fee and return rate.
- The template calculates gross and true margin, break-even ROAS and max CPA for each row.
- Assign a band to custom_label_0 by true margin and send it to the feed.
- In the Google Ads products report, check how much spend goes to the lowest-margin band.
- When bands differ by 10 or more percentage points and have enough conversions, give them their own campaign with its own target ROAS.
When and how to split a campaign by margin, we cover in Why one PMax for the whole store can hold growth back. Elektro Sláma now runs every category PMax with its own target ROAS between 4.2 and 4.9.
Data from our accounts
Four accounts where the decisions were about margin, not campaigns. Month-by-month detail is in the case studies.
| Account | What we saw | What we did | Result |
|---|---|---|---|
| MyDeko soap flower bouquets | Margin after ads in March 2026: −25%, ads 97% of revenue | Bestseller price 119 → 219 CZK, basket add-ons, consolidated campaigns, website changes | Margin after ads in September +37%, ads 42% of revenue, orders 32 → 94 a month |
| Vše pro pejska dog clothing | Winter 2025/26: store orders +25%, revenue +11% | Category PMax campaigns, ACoS 22.7 → 17.5% | Gross margin as % of revenue 49.9 → 44.8%, average order −11% |
| Klenoty Mahdal jewellery and watches | ACoS 70% incl. cancellations and returns (2023) | Target ACoS as the frame, category campaigns with target return | ACoS 14% (2025), online revenue 1.2 → 6.5m CZK, average order 1,800 → 2,600 CZK |
| Papírnictví VojTech school supplies | Back to School 2026: orders +19% YoY, revenue +1% | Seasonal PMax, total ACoS under the 12% target | Average order −15% YoY, cost per order +74% |
Three of those four rows share one thing: revenue or orders grew faster than margin. Without calculating margin per order, it wouldn’t have shown up in the ad report.
What we got wrong
The rules in this article weren’t made up at a desk. Three situations where we watched margin too late, or went to test it.
ACoS improved, margin didn’t
At Vše pro pejska, winter ACoS fell from 22.7% to 17.5% and store orders grew 25%. Gross margin as a share of revenue, however, fell from 49.9% to 44.8%, and the average order by 11%. The season was carried by discounts and cheaper items. Growth brought more customers, not more profit. That’s why, next to ACoS, we keep one monthly table: revenue, ad cost and margin after ads from the store admin.
We overspent in August
At MyDeko, in August 2026 we tested how much budget the store could carry. Ads took 96% of revenue and margin after ads fell to −16%. In September we cut Meta spend by 64% and margin came back to +37%. We found the limit, but it cost us a month.
A season strong on orders, not on revenue
At Papírnictví VojTech, Back to School 2026 brought 19% more orders than last year, but revenue only +1%. The average order fell 15% and cost per order rose 74%. Total ACoS stayed under the 12% target, so by the target everything was fine. By margin per order, less so.
And one fair note: at MyDeko we changed price, website and ads at the same time. How much of the improvement belongs to which lever can’t be separated. And the approach of raising prices plus Meta ads won’t work for goods with margins under 30%.
Key takeaways
Download the catalog template and the list of ten per-order costs on the left — no email, no form.
Key takeaways
- Calculate margin from prices excluding VAT. From VAT-inclusive prices you overstate it.
- For ads, true margin is what counts: after shipping, payments, returns and discounts. It tends to be tens of percent below gross margin.
- Everything else follows from true margin: max ACoS = margin, break-even ROAS = 100 ÷ margin × 100, max CPA = profit before ads in money.
- A discount takes more out of margin than its percentage. At 30% margin and a 15% discount you need to sell twice as much.
- Put margin into the feed as a label and watch how much spend goes to the lowest-margin band.
Want to know what true margin your orders have and whether your campaign targets match it? We work it out as the first step when we take over an account as part of Google Ads management. Or just send us an enquiry below.
FAQ
How do you calculate profit margin?
Subtract cost price excluding VAT from selling price excluding VAT and divide by the selling price. Sell for 1,000, buy for 600: (1,000 − 600) ÷ 1,000 × 100 = 40%. For advertising, also subtract shipping, the payment fee and the loss on returns. That gives you true margin.
What’s the difference between margin and markup?
Margin is divided by selling price, markup by cost price. An item at 1,000 that cost 600 has a 40% margin and a 67% markup. A 50% markup equals a 33% margin.
Is margin calculated with or without VAT?
A VAT-registered business calculates without VAT, because the tax goes to the state. A business that isn’t registered uses the price the customer pays and a cost price including the VAT it can’t reclaim.
How do you calculate a selling price from a target margin?
Price excl. VAT = (cost price + per-order costs) ÷ (1 − target margin). With a cost of 600, per-order costs of 60 and a 35% target margin, that’s 1,015 excl. VAT, or 1,229 at 21% VAT.
How do you get break-even ROAS and max ACoS from margin?
Break-even ROAS = 100 ÷ margin in percent × 100; maximum ACoS equals margin. At a 29% true margin, break-even ROAS is 345% and maximum ACoS 29%. Set your campaign target above this line so profit is left after ads.
How much margin is enough for advertising?
There’s no universal line; it depends on average order value and per-order costs. But the lower your true margin, the higher the ROAS ads must reach: 500% at 20%, 1,000% at 10%. The approach that lifted MyDeko’s margin after ads to +37% wouldn’t work for goods with margins under 30%.
Sources
Discussion 0
Calculate margin differently, or got completely different numbers? Tell us how.
