Profit Margin Formula: How to Calculate It

A formula that looks simple on paper causes more pricing mistakes than almost any other seller calculation — usually because of what does or doesn't get included in 'cost.' This breaks down the formula precisely, with the mistakes that quietly inflate a margin number.

By Marginory team · Online sellers with hands-on experience across Etsy, Shopify & PODUpdated Fee data verified against official platform documentation

The formula

Profit margin (%) = (Revenue − Cost) ÷ Revenue × 100

Margin is calculated as a percentage of the selling price— that's the detail that trips people up. A $30 item that costs $21 has a margin of ($30 − $21) ÷ $30 = 30%. The denominator is revenue, not cost.

Worked example

Selling price$40.00
Total cost (product + fees + shipping)$27.00
Profit$13.00
Margin32.5%

Calculate your own margin instantly →

The mistake that inflates margin numbers

The most common margin calculation error is using only product/material cost in the formula, ignoring platform fees, shipping you absorb, and ad spend. A seller who calculates margin this way on Etsy might see a 45% number that's actually closer to 30% once the platform's roughly 10-15% fee cut is included. This gap compounds — a business planned around an inflated margin figure can look profitable on paper while actually running thin or negative.

Calculate true margin with all costs included →

Margin vs. markup — related but not interchangeable

Margin and markup are often confused because they describe the same underlying dollar profit, just as a percentage of two different bases. Margin uses selling price as the denominator; markup uses cost. This means a target margin and a target markup with the same percentage number produce different prices — a frequent source of pricing errors when the two terms get swapped.

Full breakdown: markup vs margin →

Frequently Asked Questions

What is the profit margin formula?
Profit margin (%) = (Revenue − Cost) ÷ Revenue × 100. It expresses profit as a percentage of the selling price, not as a percentage of cost — that distinction is what separates margin from markup.
What counts as 'cost' in the margin formula?
For a complete picture: product/material cost, platform fees, shipping cost you absorb, and any ad spend attributable to the sale. Many sellers only subtract product cost, which inflates the margin number and misrepresents actual profitability.
Is 30% margin the same as 30% markup?
No — they're calculated from different bases (margin from selling price, markup from cost) and are never the same number except at 0%. A 30% margin actually requires roughly a 43% markup.