Home / Free Tools / Free Ecommerce Tool
This ecommerce profit margin calculator shows how much of each order you actually keep once every variable cost is paid. Gross margin is the number most founders quote, but it ignores shipping, payment fees, ad spend and returns. Enter six numbers and the calculator returns your gross margin, your contribution margin before ads, your expected return cost, and your net profit and net margin per order.
It is useful for Shopify brands that are growing revenue but not seeing the cash in the bank. Very often the gap sits between a healthy-looking gross margin and a thin net margin once acquisition and returns are counted.
Subtract product cost, shipping, payment fees, ad cost per order and expected returns from the selling price, then divide by the price. A $70 order with $21 COGS, $8 shipping, a 3% fee, a $25 CPA and 6% returns keeps $9.70 of net profit, a 13.9% net margin, despite a 70% gross margin.
Inputs: Selling price per order ($), Product cost (COGS) per order ($), Shipping and fulfilment per order ($), Payment processing fee (%), Ad cost per order (CPA) ($), Return rate (%). The calculator runs in your browser; nothing is stored.
Use per-order averages from the last 30 to 90 days so one unusual week does not skew the result.
The calculator works from the top of the order down, removing one layer of cost at a time.
Gross margin % = (price - COGS) / price
Contribution margin before ads = price - COGS - shipping - (price x fee %)
Expected return cost per order = price x return rate %
Net profit per order = contribution margin before ads - CPA - return cost
Net margin % = net profit per order / price
To keep it simple, the calculator treats every return as a full refund of the selling price. In practice you may resell some returned stock, while also paying return postage, so treat the figure as an estimate.
Example (illustrative numbers, not client data): a $70 order with $21 COGS, $8 shipping and fulfilment, a 3% payment fee, a $25 CPA and a 6% return rate. Gross margin is ($70 - $21) / $70 = 70.0%. The fee is $2.10, so contribution margin before ads is $70 - $21 - $8 - $2.10 = $38.90. Expected return cost is $70 x 6% = $4.20. Net profit is $38.90 - $25 - $4.20 = $9.70 per order, a net margin of 13.9%.
| Line | Example value |
|---|---|
| Selling price per order | $70.00 |
| Gross margin | $49.00 (70.0%) |
| Contribution margin before ads | $38.90 |
| Ad cost per order (CPA) | $25.00 |
| Expected return cost (6%) | $4.20 |
| Net profit per order | $9.70 |
| Net margin | 13.9% |
Look at where the biggest drop happens. In the example, a 70% gross margin falls to 13.9% net, and the $25 CPA is the largest single cost after the product itself. That tells you where effort pays back first.
A negative net profit does not always mean stop. A first order can lose a little money if customers reorder reliably, but you need repeat purchase data to prove it. Note that net profit here is before fixed costs such as salaries, software and rent, so those still need to be covered from it.
These errors make a store look more profitable than it is. For the reasoning behind each cost layer, see our contribution margin guide at /glossary/contribution-margin.
Gross margin only subtracts product cost from the selling price. Net margin per order also removes shipping, payment fees, ad cost and returns. A store can show a 70% gross margin and still keep under 15% net once acquisition and refunds are counted, which is why net margin is the better measure of a healthy order.
It depends on your product, price point and how much repeat purchase you get. Rather than chase a universal benchmark, make sure net profit per order is positive on the first purchase, or that repeat orders reliably cover any first-order loss. Then work to widen the gap between contribution margin and CPA.
For a DTC brand that relies on paid acquisition, yes. Ad spend is a variable cost that rises with every order you buy. Leaving it out hides the biggest cost after product for many stores. This calculator includes it as CPA, the average ad cost to acquire one order.
Every refunded order loses its revenue, while you often still pay the outbound shipping and fees. This calculator simplifies by treating each return as a full refund of the price, so the expected cost per order is price times return rate. At a 6% return rate on a $70 order, that is $4.20.
Work on the largest cost first. Lower CPA with stronger creative and better conversion rates, raise order value with bundles and upsells, negotiate product and fulfilment costs, and reduce returns with clearer product pages. Small gains on each line add up, because they all come out of the same order.
Book a Brand Growth Audit. Gaurav walks through your ad account, store and unit economics with you to find where each order loses margin. Book a Brand Growth Audit.