Profit Margin Calculator
Calculate profit margin, markup percentage, and gross profit from cost and selling price with this profit margin calculator.
Profit margin is the percentage of revenue left over as profit after subtracting costs. This calculator works in both directions - enter cost and selling price to find your margin, or enter revenue and a target margin to find the maximum cost you can afford. It shows gross profit in your chosen currency, the margin percentage, and the equivalent markup so you can compare both metrics side by side.
For informational purposes only. Not financial advice. Calculations are estimates and may not reflect your exact situation. Consult a qualified financial adviser for personalised guidance.
About Profit Margin Calculator
How Profit Margin Is Calculated
Three numbers drive every margin calculation: revenue (selling price), cost, and the gross profit between them. The formulas are straightforward but each tells a different story about pricing.
| Metric | Formula | Example (Cost $60, Price $100) |
|---|---|---|
| Gross profit | Revenue - Cost | $100 - $60 = $40 |
| Profit margin | (Revenue - Cost) / Revenue x 100 | $40 / $100 x 100 = 40% |
| Markup | (Revenue - Cost) / Cost x 100 | $40 / $60 x 100 = 66.7% |
Worked example: A bakery sells a cake for $45. Ingredients and direct labour cost $18. Gross profit is $45 - $18 = $27. Margin is $27 / $45 x 100 = 60%. Markup is $27 / $18 x 100 = 150%. The bakery keeps 60 cents of every dollar in revenue, but it added 150% on top of its cost to get there. Both numbers describe the same transaction but from different angles.
What Is the Difference Between Margin and Markup?
Margin and markup both measure profit, but the denominator changes everything. Margin divides profit by revenue (the larger number), so it is always smaller than markup for the same transaction. Markup divides profit by cost (the smaller number), so it is always larger. Confusing the two is one of the most common pricing mistakes - a business that thinks it is making a 30% margin when it actually applied a 30% markup is only earning a 23.1% margin. That gap can mean the difference between profit and loss on thin-margin products.
| Margin % | Markup % | Cost to Price Multiplier |
|---|---|---|
| 10% | 11.1% | 1.11x |
| 15% | 17.6% | 1.18x |
| 20% | 25.0% | 1.25x |
| 25% | 33.3% | 1.33x |
| 30% | 42.9% | 1.43x |
| 33.3% | 50.0% | 1.50x |
| 40% | 66.7% | 1.67x |
| 50% | 100.0% | 2.00x |
| 60% | 150.0% | 2.50x |
| 75% | 300.0% | 4.00x |
The conversion formula is: Markup = Margin / (1 - Margin). So a 40% margin equals 0.40 / (1 - 0.40) = 0.667, or 66.7% markup. Going the other way: Margin = Markup / (1 + Markup). A 66.7% markup equals 0.667 / 1.667 = 0.40, or 40% margin. For a dedicated tool that converts between cost and selling price using markup, try the markup calculator.
Three Levels of Profit Margin
Businesses track margin at three levels, each subtracting more costs. This calculator handles gross margin, which is the most useful for pricing individual products or services.
| Margin Type | What It Deducts | What It Tells You |
|---|---|---|
| Gross margin | Cost of goods sold (COGS) - direct materials, production labour, shipping | How profitable each unit is before overhead |
| Operating margin | COGS + operating expenses (rent, salaries, marketing, utilities) | How profitable the core business operations are |
| Net margin | All expenses including tax, interest, depreciation, one-off costs | The bottom line - what percentage of revenue the business actually keeps |
A company can have a strong gross margin but a weak net margin if overhead or debt costs are high. That is why tracking all three levels matters. For a broader look at bottom-line profitability, the EBITDA calculator strips out interest, tax, and depreciation to compare operating performance across companies.
Average Profit Margins by Industry
The table below shows typical gross and net margins across major sectors. The figures come from NYU Stern's Damodaran dataset (updated January 2026) and industry surveys. Use these as rough benchmarks - individual businesses can sit well above or below these averages depending on scale, location, and business model.
| Industry | Gross Margin | Net Margin | Notes |
|---|---|---|---|
| Software / SaaS | 70-85% | 15-25% | The median SaaS gross margin is around 77%. Low COGS, but high R&D and sales spend compress net margins. AI-first SaaS companies see lower gross margins (50-65%) due to inference costs. |
| Professional services | 50-70% | 15-30% | Consulting and advisory firms have low COGS since the main input is labour. Healthy firms target 20-35% operating margins; smaller firms often run at 8-12%. |
| E-commerce | 45-65% | 5-10% | Gross margins vary hugely by category - beauty brands hit 50-70%, while electronics sit at 15-25%. Amazon sellers typically see 5-15% net. Tariff increases and ad-cost inflation have squeezed net margins in 2025-2026. |
| Retail (general) | 25-50% | 2-5% | Grocery averages about 1-3% net, while specialty retail can reach 8-10%. The average across all retail categories is roughly 3% net. |
| Restaurants / Food service | 60-70% | 3-9% | Full-service restaurants average 3-5% net. Quick-service formats do better at 6-9%. Labour and rent are the biggest margin killers. |
| Manufacturing | 25-35% | 5-10% | Material and labour intensive. Margins are sensitive to commodity prices and supply chain disruptions. |
| Construction | 19-22% | 5-6% | General contractors average about 5-6% net as of 2026. Labour costs are up roughly 4% year-over-year, and material costs have risen 5-7% on top of already high post-pandemic levels. |
What Is a Good Profit Margin?
There is no single "good" number because margins vary so much by industry. As a general rule of thumb, a 5% net margin is considered low, 10% is healthy, and 20% or above is strong. But context matters - a grocery chain running at 2% net is performing well for its sector, while a SaaS company at 10% net would be underperforming compared to peers.
For gross margin, the average across all US industries is roughly 37-38% according to NYU Stern data as of January 2026. The widest variation sits between software (where 70-85% gross is normal) and food or commodity businesses (where 15-25% gross is typical). If your gross margin is well below the industry average in the table above, that usually points to pricing that is too low, supplier costs that are too high, or a product mix that skews toward lower-margin items.
Common Margin Mistakes to Avoid
A few recurring errors trip up small businesses when it comes to margin calculations:
Confusing margin with markup. This is the most frequent mistake. A business that applies a 30% markup thinking it has a 30% margin is actually earning only 23.1% margin. Over a full year of sales, that 6.9 percentage point gap can be enough to turn a profitable operation into a loss-making one. In low-margin industries like grocery or construction, that error alone could wipe out the entire net profit.
Ignoring variable costs. Calculating margin on raw material cost alone while forgetting packaging, shipping, returns, and payment processing fees inflates the apparent margin. A product with a 50% margin on raw materials might only have a 35% margin once shipping and transaction fees are included. List every cost that scales with each sale to get an accurate picture.
Setting prices based on competitor margins without knowing their cost structure. A competitor with lower costs can sustain a lower selling price at the same margin. Blindly matching their price could push your own margin below breakeven. Use the break-even calculator to find your minimum viable price before comparing with competitors.
Not adjusting for currency and tax. If you sell internationally, exchange rate fluctuations and VAT or sales tax can erode margins. A 40% margin on a domestic sale might become 32% after import duty and currency conversion on an overseas order. Factor in the full landed cost before committing to international pricing.
Reverse Mode: Finding Maximum Cost
If you know your target selling price and desired margin, the calculator works backwards to find the maximum cost you can afford. This is useful when negotiating with suppliers or deciding whether a product is worth stocking.
Formula: Maximum Cost = Revenue x (1 - Target Margin / 100)
| Scenario | Revenue | Target Margin | Maximum Cost |
|---|---|---|---|
| Product pricing | $100 | 40% | $60 |
| Service pricing | $5,000 project | 30% | $3,500 (labour + expenses) |
| Supplier negotiation | $25 retail price | 50% | $12.50 wholesale cost |
Worked example: An online retailer wants to sell a product at $79.99 with a 45% margin. Maximum cost = $79.99 x (1 - 0.45) = $79.99 x 0.55 = $43.99. If the supplier quotes $48, the retailer either needs to negotiate the cost down, raise the selling price, or accept a thinner margin of ($79.99 - $48) / $79.99 = 40.0%.
When to Use Margin vs Markup in Your Business
Both metrics are useful, but they serve different purposes. Margin is best for financial reporting and comparing profitability across products, time periods, or competitors - it is the standard metric on income statements and investor reports. Markup is best for day-to-day pricing, where the question is "how much do I add on top of my cost?" If a supplier sends an invoice for $200 and you want a 40% margin, you need a 66.7% markup - sell at $333.33. Knowing both and when to use each is essential for any business that sets its own prices.
Accountants and investors almost always talk in margin terms because it normalises profit against revenue, making it easy to compare a $1 million company with a $100 million company. Retailers and wholesalers tend to think in markup terms because their workflow starts with a cost and ends with a price tag. Neither is "better" - they are two views of the same profit, and the reference table above lets you translate between them instantly.
For measuring the total return on a business investment rather than per-unit profitability, the ROI calculator shows both total and annualised returns.
Sources
Frequently Asked Questions
What is the difference between margin and markup?
Margin is the percentage of the selling price that is profit, while markup is the percentage added on top of the cost. A 50% margin means half the selling price is profit. A 50% markup means you added half the cost on top. A 50% margin equals a 100% markup.
How do I calculate profit margin from cost and selling price?
Subtract the cost from the selling price to get gross profit, then divide gross profit by the selling price and multiply by 100. For example, if cost is $60 and selling price is $100, margin is ($100 - $60) / $100 x 100 = 40%.
What is a good profit margin for a small business?
It varies by industry. Retail businesses often see 5-10% net margins, while software and services can hit 20-40%. Gross margins are higher since they only account for direct costs. Check industry benchmarks to see where you stand.
Can margin ever be higher than markup?
No. Margin is always lower than or equal to markup for positive values. They only match at 0%. As margin grows, markup grows faster because markup is calculated on the smaller cost base rather than the larger revenue figure.
How do I find cost from revenue and margin?
Multiply the revenue by (1 - margin / 100). For example, if revenue is $1,000 and margin is 30%, cost is $1,000 x 0.70 = $700. Use the reverse mode in this calculator to do it automatically.
Related Tools
Link to this tool
Copy this HTML to link to this tool from your website or blog.
<a href="https://toolboxkit.io/tools/profit-margin-calculator/" title="Profit Margin Calculator - Free Online Tool">Try Profit Margin Calculator on ToolboxKit.io</a>