How to calculate true profit on Shopify (COGS, fees, shipping and ads)
Open Shopify Analytics and the big number is total sales. It feels like success, but it's the top of the funnel, not the bottom. Real profit is what survives after every cost of getting that order out the door — and most of those costs live in five different places. Here's the full stack.
Start from net sales, not gross
First, strip the noise out of revenue:
Net sales = Gross sales − Discounts − Refunds − Taxes you collect on behalf of the state
Tax isn't your money, and discounts/refunds were never collected. Start from net sales so every margin below is honest.
Subtract the five real costs
True profit comes from peeling off costs in order:
- COGS (cost of goods sold) — what each item cost you. This is the biggest lever and the one Shopify only tracks if you fill in "Cost per item" on every variant.
- Payment processing fees — roughly 2.9% + €0.30 per order on most gateways, more for some cards and currencies. Real fees vary per transaction.
- Shipping cost — what you paid the carrier, minus what the customer paid you. Free shipping is a cost, not a feature.
- Refunds and returns — the refunded amount plus, often, the lost product and return shipping.
- Ad spend — Meta, Google, TikTok. The cost of getting the order, not fulfilling it.
Put together:
Profit after ads = Net sales − COGS − Fees − Shipping − Refunds − Ad spend
The line just above ad spend is your contribution margin. The final line is what actually lands in the bank before fixed costs.
A worked example
A €90 order:
| Line | Amount |
|---|---|
| Net sales | €90.00 |
| COGS | −€34.00 |
| Payment fee | −€2.91 |
| Shipping | −€5.50 |
| Contribution margin | €47.59 |
| Ad spend (blended/order) | −€22.00 |
| Profit after ads | €25.59 |
The €90 "sale" is really about €25 of profit. Miss any one of those lines and you'll over-state profit by 10–40%.
Why blended ad spend, not per-order attribution
Attribution (which exact ad drove which order) is noisy and increasingly broken after iOS privacy changes. For knowing your profit, you don't need it. Take total ad spend for a period and total orders, and you get MER (marketing efficiency ratio) and a blended cost per order that's robust and honest. Learn more in MER and blended ROAS explained.
Automate it instead of rebuilding a spreadsheet monthly
You can do this in a spreadsheet once. Doing it every day, per product and per channel, by hand, is where it falls apart. Margeny connects Shopify and your ad accounts and computes net profit per order, product and day automatically — COGS, fees, shipping, refunds and ad spend included.
Know your real profit this week
Connect your store in minutes. 14-day free trial, no card required.