Margin Calculator
Calculate profit margins from cost and selling price. Essential for pricing, profitability analysis, and business planning.
Margin Formulas
| Type | Formula | Gross Margin %((Revenue - COGS) / Revenue) × 100 Net Margin %(Net Profit / Revenue) × 100 Markup %((Price - Cost) / Cost) × 100
Margin vs Markup
CostSelling PriceMarginMarkup $50$10050%100% $70$10030%43% $80$10020%25% | $60 | $100 | 40% | 67% |
Implementation
``javascript
function calculateMargin(cost, sellingPrice) {
const profit = sellingPrice - cost;
const margin = (profit / sellingPrice) * 100;
const markup = (profit / cost) * 100;
return { profit, margin, markup };
}
``
Industry Average Margins
| Industry | Typical Margin | Grocery2-3% Retail3-5% Software70-90% Restaurants3-9% Manufacturing5-10%