Determine the selling price per unit
Determine the cost per unit
Subtract cost per unit from selling price per unit
Divide the result by selling price per unit to get margin percentage
Multiply by 100 to convert to a percentage
Use the formula: Margin = (Selling Price – Cost) / Selling Price × 100
For gross margin, use direct production or purchase costs
For net margin, use total expenses after all costs and taxes
Check that all values are in the same currency and time period
