Margin Calculator
Enter values and click Calculate to see the breakdown.
Enter values and click Calculate to see the breakdown.
How Does the Formula Work?
The margin calculator computes profit margin, markup percentage, cost, revenue, and profit from any two known values. Understanding the difference between margin and markup is essential for pricing strategy, profitability analysis, and financial planning. Margin measures profit as a percentage of the selling price (revenue), while markup measures profit as a percentage of cost. These two metrics describe the same profit from different perspectives — this calculator converts between them instantly. Business owners, freelancers, retailers, and financial analysts use these calculations daily to set prices, evaluate deals, and track profitability.
Margin % = (Profit ÷ Revenue) × 100
Markup % = (Profit ÷ Cost) × 100
Revenue from Cost + Margin: Revenue = Cost ÷ (1 − Margin/100)
Revenue from Cost + Markup: Revenue = Cost × (1 + Markup/100)
Example: Cost $80, Revenue $100 → Profit $20, Margin 20%, Markup 25%
Margin vs Markup — The Critical Difference
Margin and markup are the most commonly confused financial metrics. They describe the same profit amount but use different bases. If you buy a product for $80 and sell it for $100, the profit is $20. The margin is 20 percent (20 divided by 100 — the selling price). The markup is 25 percent (20 divided by 80 — the cost). Higher margins always correspond to higher markups, but the numbers are never equal unless both are zero. A 50 percent margin equals a 100 percent markup. A 33 percent margin equals a 50 percent markup. Confusing the two when setting prices can destroy profitability. If you intend a 30 percent margin but accidentally apply a 30 percent markup, your actual margin is only 23 percent — a significant shortfall that compounds across thousands of transactions.
Industry Benchmarks
Profit margins vary enormously by industry. Grocery stores operate on thin margins of 1 to 3 percent. Restaurants target 60 to 70 percent food cost (30 to 40 percent margin). Retail clothing averages 50 to 60 percent markup (33 to 38 percent margin). Software and SaaS companies enjoy 70 to 90 percent gross margins because marginal cost of digital delivery is near zero. Professional services (consulting, law, accounting) target 40 to 60 percent margins. Manufacturing ranges from 10 to 35 percent depending on the product. E-commerce averages 20 to 45 percent. Luxury goods often exceed 60 percent margins. Understanding where your industry falls helps you set competitive prices and identify whether your margins are healthy or need improvement.
Pricing Strategies
There are three fundamental pricing approaches. Cost-plus pricing adds a fixed markup to cost — simple but ignores market dynamics. Value-based pricing sets price according to perceived customer value — potentially higher margins but requires market research. Competitive pricing matches or undercuts competitors — may sacrifice margin for volume. Most successful businesses use a hybrid approach: they know their cost floor (minimum margin to cover expenses), understand competitive pricing, and capture value through differentiation. This calculator supports all three strategies by letting you work backward from a target margin to find the required selling price, or forward from cost and markup to find the resulting margin. Use the different calculation modes to model scenarios: what margin do I get at this price? What price do I need for a 40 percent margin?
Gross vs Net Margin
This calculator computes gross profit margin — the difference between revenue and direct cost of goods sold (COGS). Net profit margin subtracts all expenses (rent, salaries, marketing, taxes, depreciation) from revenue. A business might have a 40 percent gross margin but only a 10 percent net margin after overhead. Both metrics are important: gross margin evaluates product-level profitability and pricing strategy, while net margin evaluates overall business health. The S&P 500 average net profit margin is approximately 11 to 12 percent. If your net margin significantly trails your gross margin, you may have an overhead efficiency problem rather than a pricing problem. Use this calculator for product-level pricing decisions, and combine it with your full income statement for net margin analysis.
Using This Calculator
Select the calculation mode based on what you know: Cost and Revenue gives you margin and markup directly. Cost and Target Margin calculates the required selling price. Revenue and Target Margin finds the maximum cost you can afford. Cost and Markup shows the resulting revenue and margin percentage. The color-coded margin indicator provides instant feedback: green for margins above 50 percent (excellent), blue for 20 to 50 percent (healthy), yellow for 0 to 20 percent (thin), red for negative (loss). Try different scenarios to find the optimal price point where margin meets market acceptance.
Margin for Freelancers
Freelancers and solopreneurs often struggle with pricing because they forget to account for non-billable hours, self-employment taxes, health insurance, retirement savings, and business expenses. A freelancer charging $50 per hour with 60 percent utilization, 30 percent effective tax rate, and $500 per month in business expenses needs to earn at least $100 per billable hour to maintain a healthy margin. Use this calculator to work backward from your target annual income to find the minimum hourly or project rate that covers all costs and provides your desired profit margin.
Conversion Quick Reference
Common margin-to-markup conversions: 10% margin = 11.1% markup, 20% margin = 25% markup, 25% margin = 33.3% markup, 30% margin = 42.9% markup, 33.3% margin = 50% markup, 40% margin = 66.7% markup, 50% margin = 100% markup, 60% margin = 150% markup, 75% margin = 300% markup. Memorizing these benchmarks helps you quickly evaluate deals and pricing without a calculator. This tool validates your mental math and handles the exact conversions for any value you enter.
Tips & Recommendations
50% margin = 100% markup. Always clarify which metric you mean when discussing pricing.
Use 'Cost + Target Margin' mode to find the exact selling price for your desired margin.
Calculate margins monthly. Seasonal cost changes can erode profitability without you noticing.
Don't forget shipping, packaging, returns, and payment processing fees in your cost calculation.
Frequently Asked Questions
What's the difference between margin and markup?
Margin = Profit ÷ Revenue. Markup = Profit ÷ Cost. Same profit, different base. 50% margin = 100% markup.
What's a healthy profit margin?
Varies by industry: 1-3% grocery, 30-40% restaurants, 70-90% software. Compare to your industry average.
How do I set a target margin?
Select 'Cost + Target Margin' mode. Enter your cost and desired margin percentage to find the required price.
Is this gross or net margin?
Gross margin (revenue minus direct cost). Net margin subtracts all expenses including overhead, taxes, etc.
Why is my margin lower than my markup?
Margin is always lower because it divides by revenue (larger number). Markup divides by cost (smaller number).
Recent Calculations
No calculations yet