๐Ÿ‡บ๐Ÿ‡ธ USC
Business & Work
๐Ÿ“Š

Margin Calculator

Find profit margin, markup and price from any two figures

๐Ÿ“Š Margin details

$
$

๐ŸŽฏ Your profit margin

60.00%
profit margin
Cost$40.00
Price (revenue)$100.00
Profit$60.00

๐Ÿ’ฐ Key figures

Profit margin
60.00%
Markup
150.00%
Profit (per unit)
$60.00
Cost as % of price
40.00%

๐Ÿ“‹ How this breaks down

Revenue (price)$100.00
โˆ’ Cost of goods$40.00
= Gross profit$60.00
Margin = profit รท price60.00%
Markup = profit รท cost150.00%

Estimate only - not financial or accounting advice. This shows gross margin on a single item (price minus cost of goods). It does not account for overhead, taxes, shipping, payment fees, returns or discounts.

โœ…

Last updated June 2026

Method: Profit margin is calculated as (price โˆ’ cost) รท price ร— 100, the standard accounting definition of gross margin. Markup uses (price โˆ’ cost) รท cost ร— 100, and the target-margin price uses cost รท (1 โˆ’ margin).

Included: Gross profit per item, profit margin %, markup %, the required selling price for a target margin, and a margin-vs-markup breakdown.

Not included: Overhead, taxes, shipping, payment processing fees, returns, discounts and other operating costs. Results are estimates for planning, not accounting figures.

Margin calculator: everything you need to know

Sell a product that costs you $40 for $100, and your gut might say you "made 150%." Your accountant would say you earned a 60% profit margin. Both numbers describe the same $60 of profit โ€” they just measure it against different things. That single distinction is where most pricing mistakes start, and it is exactly what this margin calculator is built to get right. Enter any two of cost, price and margin, and it returns your profit, your profit margin, and your markup, all at once.

What profit margin actually means

Profit margin is the share of each sale you keep as profit after covering the cost of the product. It is expressed as a percentage of the selling price, not the cost. A 30% margin means that for every dollar a customer pays, 30 cents is profit and 70 cents went to making or buying the item. Because margin is a slice of the price, it can range from below zero (selling at a loss) up toward โ€” but never reaching โ€” 100%.

The formula

Profit margin uses one simple equation:

Margin % = (Price − Cost) ÷ Price × 100

The numerator, Price โˆ’ Cost, is your gross profit. Dividing by the price turns that profit into a percentage of revenue. To find the price you need for a target margin, the formula rearranges to:

Price = Cost ÷ (1 − Margin ÷ 100)

And markup โ€” the same profit expressed against cost instead of price โ€” is:

Markup % = (Price − Cost) ÷ Cost × 100

Margin vs. markup: the difference that costs people money

Margin and markup describe the same dollars of profit but use different denominators, so they always produce different percentages โ€” and markup is always the bigger one. Pricing a product to a "60% markup" when you meant a 60% margin leaves real money on the table. Here is how a few common values translate:

Markup Equivalent margin Example ($40 cost)
25%20%Price $50
50%33.3%Price $60
100%50%Price $80
150%60%Price $100
300%75%Price $160

To convert between them: Margin = Markup รท (100 + Markup) ร— 100, and Markup = Margin รท (100 โˆ’ Margin) ร— 100. The calculator shows both numbers side by side so you never have to do this in your head. If you prefer to start from cost and add a markup directly, the dedicated Markup Calculator takes that route.

How to use this margin calculator

The calculator has two modes. Pick the one that matches the numbers you already have:

  1. "I know cost & price": enter what the item costs you and what you sell it for. The calculator returns the profit, the profit margin %, and the markup %.
  2. "I know cost & target margin": enter your cost and the margin you want to hit. The calculator solves for the selling price you need to charge, then shows the resulting profit and markup.
  3. Read the big number: the prominent figure at the top is your margin (in price mode) or your required price (in target-margin mode).
  4. Scan the supporting cards: the key-figures grid and the breakdown table show profit, markup, and how cost and profit split out of the price.

Everything updates instantly as you type, so you can drag a price up or down and watch the margin respond.

Who this calculator is for

  • Retailers and resellers setting shelf or listing prices from a wholesale cost.
  • E-commerce and dropshipping sellers checking whether a product clears their target margin after cost.
  • Freelancers and service providers translating their delivery cost into a billable rate (pair this with the Hourly to Salary Calculator to value your time).
  • Makers and craftspeople pricing handmade goods so labor and materials are actually covered.
  • Small-business owners and students who need a quick, correct answer without confusing margin with markup.

Key terms explained

  • Cost (COGS): the direct cost of producing or buying the item โ€” materials, manufacturing, landed shipping to you. It excludes overhead.
  • Price / revenue: the pre-tax amount the customer pays you for one unit.
  • Gross profit: price minus cost. The raw dollars left before any other expenses.
  • Profit margin: gross profit as a percentage of the price.
  • Markup: gross profit as a percentage of the cost.
  • Net margin: profit after all costs (overhead, taxes, fees) as a percentage of revenue โ€” always lower than gross margin.

Worked example 1: finding the margin

You buy phone cases for $6 each and sell them for $24. Your gross profit is $24 โˆ’ $6 = $18. The margin is 18 รท 24 = 0.75, or a 75% profit margin. The markup, by contrast, is 18 รท 6 = 3.0, or a 300% markup โ€” same $18 of profit, very different percentages.

Worked example 2: pricing to a target margin

You make candles for $8 in materials and labor and want a 40% margin. Using Price = Cost รท (1 โˆ’ Margin), the math is $8 รท (1 โˆ’ 0.40) = $8 รท 0.60 = $13.33. At that price your profit is $5.33 per candle, which is a 40% margin and a 66.7% markup. Round to $13.99 and your margin edges up slightly to about 43%.

Worked example 3: the danger of confusing the two

Suppose your cost is $50 and you want a "50%" return. If you apply a 50% markup, you price at $75 and earn a 33.3% margin. If you apply a 50% margin, you price at $100 and earn a 100% markup. That is a $25 difference in price per unit on the same product, purely from which definition you used โ€” across thousands of sales it adds up fast.

Typical margin ranges by sector

"Good" margins vary enormously by industry, so compare yourself to peers rather than a single benchmark. As a rough orientation only:

  • Grocery and convenience retail: thin gross margins, often in the low double digits, made up for by volume.
  • Restaurants and food service: high food-cost percentages leave net margins frequently in the single digits.
  • Apparel and general retail: commonly priced at a 50โ€“60% gross margin (a roughly 100โ€“150% markup).
  • Software and digital products: very high gross margins, often 70โ€“90%, because the marginal cost per copy is near zero.

Tips for using margin in real pricing

  • Price on margin, not markup, when you compare across products โ€” margin is the figure that ties directly to your revenue and profit-and-loss statement.
  • Build in a cushion below your gross margin for the costs this tool ignores: payment fees, returns, shipping and overhead.
  • Recalculate when costs move. Supplier price increases quietly erode margin if your price stays fixed.
  • Watch discounts. A 20% off promotion on a 40% margin item cuts your profit roughly in half, not by 20%.

Gross margin vs. net margin

This calculator shows gross margin โ€” price minus the direct cost of the item. That is the right lens for setting a price, but it overstates how much you actually keep. Net margin subtracts every other expense: rent, salaries, marketing, software, payment processing, returns and taxes. A product can have a healthy 60% gross margin and still leave a 5% net margin once the whole business is paid for. Use gross margin per item to price, and net margin across the company to judge whether you are truly profitable.

Related concepts and calculators

This page answers "what is my margin, markup, or price?" If your question is different, a sister tool fits better:

Margin in a full profit-and-loss picture

The margin this tool reports is gross margin on a single item, but a business actually earns money across three nested layers. Gross profit is revenue minus the cost of goods sold (COGS) — the direct cost of making or buying what you sell. Operating profit subtracts the running costs of the business: rent, salaries, software, marketing and utilities. Net profit then takes out interest, one-off costs and taxes, leaving what the company truly keeps. Each layer has its own margin, and they fall in that order, so a product line with a strong 60% gross margin can still produce a thin net margin once the whole operation is paid for. When you price an item, gross margin is the right lens; when you judge the health of the business, look further down the statement with the Profit Margin Calculator.

Margin and break-even: pricing is only half the job

A healthy margin per unit does not guarantee a profit if you do not sell enough units to cover your fixed costs. Fixed costs — rent, salaries, insurance, software subscriptions — are paid whether you sell one item or a thousand, and your gross margin per item is what pays them down. The break-even point is the number of units where total gross profit finally equals total fixed costs: Break-even units = Fixed costs ÷ gross profit per unit. A higher margin lowers your break-even point, which is one more reason small margin differences matter. If you run a business with meaningful overhead, pair this margin figure with the Break-Even Calculator to see how many sales it takes before the margin actually becomes profit.

Margin and discounts: protecting your profit on a sale

Discounts come straight out of the margin layer, so they hurt more than the headline percentage suggests. On a product with a 40% margin, a 20% price cut does not trim 20% of your profit — it can erase roughly half of it, because the discount is subtracted from the thin slice of profit rather than from the larger cost. The leaner your margin, the more dangerous a discount becomes: at a 20% margin, a 20% discount can wipe out the profit entirely and push the sale into a loss. Before you advertise a promotion, work out the post-discount price with the Discount Calculator, then run that new price back through this margin calculator to confirm you are still in the black. The volume the promotion brings in only helps if each discounted unit still carries a positive margin.

Pricing a service vs. a physical product

Margin works for services too, but the "cost" line is different. For a physical product, cost is the landed cost of goods. For a service, your cost is the direct cost of delivering it — the labor hours, subcontractors and materials tied to that specific job. The margin then tells you what share of each invoice is profit before overhead. The catch with service work is unbilled time: hours spent quoting, revising, traveling and chasing invoices are real costs that never appear on a bill, so the effective gross margin is usually lower than the on-paper figure. If you price from an hourly cost, convert it to an annual equivalent first with the Hourly to Salary Calculator to be sure your billable rate actually covers the cost of your time plus a margin, not just the cost.

When costs change: re-pricing to defend your margin

Margin erodes quietly. A supplier raises a wholesale price by a few percent, your selling price stays the same out of habit, and the margin you carefully set slips lower with every sale. To hold a target margin when cost rises, re-price with the same formula the calculator uses: new price = new cost ÷ (1 − target margin). A common mistake is to simply add the dollar increase in cost to the price — that keeps your profit per unit flat but lets the margin percentage fall, because the price now sits on a larger cost base. To truly preserve a 40% margin, the price has to rise by more than the cost did. Re-run the numbers here whenever a key input moves, and treat a quoted "raise" (whether on a cost or a wage) the way the Pay Raise Calculator treats a salary bump: as a percentage applied to a base, not a fixed amount.

Frequently confused: profit, profit margin and markup

These three words describe related but distinct things, and mixing them is the single most common source of pricing errors. Profit is a dollar amount (price minus cost). Profit margin is that profit as a percentage of the price. Markup is that same profit as a percentage of the cost. On a $40 cost sold for $100: the profit is $60, the margin is 60% and the markup is 150%. All three are correct descriptions of the exact same transaction. Trouble starts when a supplier quotes "60%" without saying whether they mean margin or markup, or when a spreadsheet built around markup is compared against a competitor's margin figure. The rule of thumb: markup is always the bigger percentage, because it divides by the smaller number. If a profitability figure sounds surprisingly high, check whether it is markup before you celebrate.

Sources & further reading

  • U.S. Small Business Administration (SBA) — Manage your finances (pricing and profitability basics for small businesses).
  • Internal Revenue Service (IRS) — Cost of Goods Sold (how COGS is defined for tax purposes).

โš ๏ธ Common mistakes & edge cases

Confusing margin with markup

A 50% markup is not a 50% margin. On a $40 cost, a 50% markup prices at $60 (33% margin), while a 50% margin prices at $80. Always confirm which one a supplier or spreadsheet means before you price.

Treating gross margin as take-home profit

Gross margin ignores overhead, fees, shipping, returns and taxes. A 60% gross margin item can net far less. Set prices with a cushion so your net margin stays positive after every other cost.

Trying to set a margin of 100% or more

Margin is a share of the price, so it can never reach 100% unless cost is $0. As the target margin nears 100% the required price shoots toward infinity โ€” that is why the calculator caps target margin below 100%.

Including sales tax in price or cost

Sales tax is collected for the government, not kept as profit. Putting it in the price field inflates your margin. Use pre-tax price and your true landed cost so the percentage reflects real profit.

Note: This calculator gives a planning estimate of gross margin, not accounting or financial advice. Your real profit depends on overhead, fees, taxes, returns and discounts.

❓ Frequently asked questions

How do you calculate profit margin?

Profit margin is profit divided by price (revenue), times 100. The formula is Margin % = (Price โˆ’ Cost) รท Price ร— 100. For example, if an item costs $40 and sells for $100, the profit is $60 and the margin is 60 รท 100 ร— 100 = 60%. Margin is always a share of the selling price, so it can never reach 100% unless the cost is zero.

What is the difference between margin and markup?

Both measure profit, but against different bases. Margin is profit as a percentage of the selling price (profit รท price), while markup is profit as a percentage of the cost (profit รท cost). On a $40 cost sold for $100, the margin is 60% but the markup is 150%. Markup is always the larger number, which is why the two are easy to confuse and dangerous to mix up when pricing.

How do I find the price for a target margin?

Rearrange the margin formula: Price = Cost รท (1 โˆ’ Margin รท 100). To earn a 60% margin on a $40 cost, divide $40 by (1 โˆ’ 0.60) = 0.40, giving a price of $100. Use the calculator's 'I know cost & target margin' mode to do this instantly for any cost and margin.

Why can't profit margin be 100% or more?

Margin is profit as a fraction of the price, and profit can never exceed the price itself (your profit is the price minus a non-negative cost). The only way to reach a 100% margin is a cost of $0. As your target margin approaches 100%, the required price approaches infinity, which is why the calculator caps target margin below 100%.

Is margin calculated on gross or net profit?

This calculator computes gross margin, which uses only the direct cost of the product (cost of goods sold). Net margin subtracts all other expenses too โ€” overhead, rent, salaries, marketing, payment fees and taxes โ€” and is always lower. Use gross margin for per-item pricing decisions and net margin to judge whether the whole business is profitable.

What is a good profit margin?

It depends entirely on the industry. Grocery and retail often run on single-digit net margins, restaurants frequently sit in the 3โ€“9% range, while software and digital products can exceed 70โ€“80% gross margin because each extra unit costs almost nothing to produce. Compare your margin to peers in your sector rather than to a universal target.

How do I convert markup to margin?

Use Margin % = Markup รท (100 + Markup) ร— 100. A 150% markup converts to 150 รท 250 ร— 100 = 60% margin. To go the other way, Markup % = Margin รท (100 โˆ’ Margin) ร— 100, so a 60% margin equals a 150% markup. The calculator shows both numbers at once so you never have to convert by hand.

Does a higher price always mean a higher margin?

Only if your cost stays the same. Raising the price while holding cost flat increases both profit and margin. But if a price increase comes with higher costs โ€” premium materials, faster shipping, extra service โ€” the margin can stay flat or even shrink. Always compare price and cost together, which is exactly what this calculator does.

Should sales tax be included in the price field?

No. Use the pre-tax selling price you actually keep as revenue. Sales tax is collected on behalf of the government and passed through, so it is not part of your profit and including it would overstate your margin. Likewise, enter cost as your true landed cost of the product, excluding any tax you can reclaim.

Can I use this for services, not just products?

Yes. Treat your cost as the direct cost of delivering the service (labor hours, subcontractors, materials) and the price as what you bill the client. The margin then tells you what share of each invoice is profit before overhead. For labor-heavy work, remember that unbilled time and overhead can make the net margin much thinner than the gross margin shown here.

๐Ÿ’ก Good to know

Markup always looks bigger than margin

For the same profit, markup is the larger percentage because it divides by the smaller number (cost). A 60% margin is a 150% markup. When a number sounds impressively high, check whether it is markup before celebrating.

Discounts hit margin harder than they look

A 20% discount does not shave 20% off your profit โ€” it can wipe out most of it. On a 40% margin item, a 20% price cut nearly halves the profit, because the discount comes straight out of the slim profit layer, not the cost.

Price to margin, manage to net

Use gross margin to set individual prices, but track net margin across the whole business. A catalog of high-gross-margin products can still run at a loss if overhead and fees are not controlled.

Related Calculators