How profit is worked out
Profit margin is profit divided by revenue. The hard part is getting both numbers honest, so the calculator works one order at a time and subtracts every cost that comes with that order:
Card fee = revenue × processing % + fixed fee
Refunds = revenue × refund rate
Profit = revenue − product − shipping − packaging − card fee − third-party fee − refunds − ad cost
Margin = profit ÷ revenue
Revenue is the price after discount, because that's what the customer pays and what Meta or Google record as the purchase value. Using it as the denominator for margin, break-even ROAS and ROAS means the three numbers line up with each other and with your ad dashboards.
Two more outputs come from the same breakdown. Profit before ads (revenue minus everything except ad spend) is the most you can pay to get one order and still break even, shown as max cost per order. Break-even ROAS is revenue divided by profit before ads.
Worked example
A $40 product that costs $12 to make, ships for $6 in a $1.50 mailer, sold on the Basic plan with Shopify Payments (2.9% + 30¢ on a standard US card2). Ads cost $8 per order and 5% of orders are refunded, with the items going back into stock.
| Line | How | Amount |
|---|---|---|
| Revenue | $40, no discount | $40.00 |
| Product cost | $12 × 95% (refunded items are resold) | −$11.40 |
| Shipping | carrier label | −$6.00 |
| Packaging | mailer | −$1.50 |
| Card fee | $40 × 2.9% + $0.30 | −$1.46 |
| Refunds | $40 × 5% | −$2.00 |
| Profit before ads | contribution per order | $17.64 |
| Ad cost | ad spend ÷ orders | −$8.00 |
| Profit | margin 24.1% | $9.64 |
The markup on that product is 233.3% ($12 to $40), which looks generous. After everything else, 24.1% of the price is left as profit. That gap is why it pays to run the numbers per order instead of reasoning from markup. Profit before ads is $17.64, so this product breaks even at 2.27x ROAS, and any order that costs more than $17.64 in ads loses money.
The same product in a 20% off sale
Revenue falls to $32.00 and almost every cost stays put. Profit drops from $9.64 to $2.27, a 7.1% margin. The discount took 76% of the profit, not 20%. Enter your average discount across all orders, not the headline code: if a third of orders use a 15% code, that's 5%.
Reverse mode: the price for a 25% margin
Some costs don't move with the price (product, shipping, packaging, the fixed 30¢, ad cost per order) and some are a share of it (card %, third-party fee, refunds). Solving for the price:
= $27.20 ÷ 67.1% = $40.54
At $40.54 the order keeps $10.13, exactly 25% of the price. If card fees, refunds and the target add up to 100% or more, no price works, and the calculator says so instead of printing a nonsense number.
What each input means for a Shopify store
- Selling price
- The product price before any discount. The card fee is a percentage of the whole amount charged, so if you charge shipping separately, add what the customer pays for shipping to the price and put your real shipping cost in the shipping field.
- Product cost
- The landed cost of one unit: supplier price plus inbound freight and duties per unit. For print-on-demand or dropshipping, the supplier's charge per unit.
- Shipping you pay
- What the carrier or your 3PL charges for this order, including per-order pick-and-pack fees.
- Packaging & other
- Anything else that comes with each order: mailer, inserts, an app that bills per order.
- Average discount
- The average discount across all orders, as a share of the list price.
- Ad cost per order
- Ad spend divided by orders over the same period. If only some orders come from ads, total ad spend divided by all orders gives the blended figure most stores should plan with.
- Refund rate
- The share of orders refunded in full. Shopify doesn't return card fees when you refund4, so the calculator keeps the fee on refunded orders. Leave the box ticked if refunded items go back into stock; untick it if they're written off.
- Shopify plan and processing rate
- Prefilled with Shopify Payments' online rate for a standard US card on each plan. US rates now depend on card type: business cards and all domestic American Express cards are "Premium", international cards carry an extra charge, and your exact schedule is in Settings > Payments > View payment rates3. If most of your customers pay with Amex, raise the rate.
- Third-party gateway
- If orders go through a gateway other than Shopify Payments, Shopify adds its own transaction fee: 2% on Basic, 1% on Grow, 0.6% on Advanced, 0.2% on Plus1. Tick the box and put your gateway's rate in the processing fields. On stores created on or after 12 May 2025 the same fee applies to amounts paid with store credit or gift cards4.
Margin, markup and break-even ROAS
Markup is profit on top of cost: (price − cost) ÷ cost. Margin is profit as a share of the price: (price − cost) ÷ price. A 100% markup is a 50% gross margin. Same product, two very different-looking numbers.
Gross margin only takes off the product cost. Contribution margin takes off every cost that comes with an order: card fees, shipping, packaging, refunds. Contribution margin decides how much you can spend on ads, because break-even ROAS is 1 ÷ contribution margin. In the example, gross margin is 70.0% but contribution margin is 44.1%, so break-even ROAS is 2.27x, not the 1.43x gross margin would suggest. For a quick margin-to-ROAS lookup table, use the break-even ROAS calculator; to check a live campaign against it, the ROAS calculator.
Shopify fees used here
US rates, checked 2026-09-16. Shopify's pricing page lists the subscription and the third-party fee for each plan1 but no longer prints the card rates. The online and in-person figures below are the per-plan rates Shopify publishes on its own site2, and they're standard-card rates.
| Plan | Shopify Payments online | In person | Third-party fee |
|---|---|---|---|
| Basic | 2.9% + 30¢ | 2.6% + 10¢ | 2% |
| Grow | 2.7% + 30¢ | 2.5% + 10¢ | 1% |
| Advanced | 2.5% + 30¢ | 2.4% + 10¢ | 0.6% |
| Plus | Not published | Not published | 0.2% |
For what these fees add up to per month with your subscription, and when a bigger plan pays for itself, use the Shopify fee calculator.
What this calculator leaves out
- Sales tax and VAT. Prices here are before tax. The card fee is charged on tax you collect too, which shaves a little more off.
- Chargebacks. On a chargeback the bank takes the disputed amount and a chargeback fee straight away6. If you get them regularly, add the expected cost per order to "packaging & other".
- Currency conversion. A US store selling in other currencies through Shopify Payments pays a 1.5% conversion fee on those orders5. Add it to the processing %, weighted by the share of orders it applies to.
- Subscription, apps and staff. Fixed monthly costs aren't per-order costs. Profit per order times orders has to cover them. To fold them in, divide the monthly total by orders and add the result to "packaging & other".
- Return shipping. If you pay for return labels, add label cost × refund rate to "packaging & other".
- One product at a time. For a whole store, use average order value and average costs per order, or run your top products separately.
FAQ
What is a 30% margin on $100?
$30 of profit on a $100 price, so costs are $70. The markup on those costs is 42.9% ($30 ÷ $70). A 30% margin always means profit is 30% of the price, not 30% on top of cost.
Is a 30% profit margin good for a Shopify store?
It depends which margin. A 30% gross margin (price minus product cost) usually leaves little or nothing once shipping, card fees and ads come out. A 30% net margin after ads is healthy for most stores. There's no reliable industry-wide benchmark to compare against; the test that matters is whether profit per order times orders covers your fixed monthly costs.
Does this include my Shopify subscription?
No. The subscription is a fixed monthly cost, not a per-order one. Divide it by your monthly orders and add the result to "packaging & other" if you want it in the per-order figure. The fee calculator does that split for you.
How much does Shopify take from a $40 sale?
On Basic with Shopify Payments and a standard US card, $1.46: 2.9% of $40 plus 30¢. There's no extra Shopify transaction fee when you use Shopify Payments. With a third-party gateway you pay the gateway's rate plus Shopify's 2% on Basic.
Why does the calculator charge card fees on refunded orders?
Because Shopify does. Its Help Center says credit card transaction fees aren't returned when you issue a refund4.
What's the difference between this and the break-even ROAS calculator?
This one starts from a product's price and costs and tells you profit per order, with break-even ROAS as one output. The break-even ROAS calculator starts from a margin and is built around the ad question: the lowest ROAS you can run at, with a margin-to-ROAS lookup table.