CalcUnit Logo

What is the Margin Calculator?

Margin and markup sound interchangeable until they cost you money. Buy a gadget for $60, sell it for $100, and the $40 profit is a 40 percent margin but a 66.7 percent markup -- because margin divides by the selling price while markup divides by the cost. Retailers, restaurants, and freelancers who quote one while thinking the other quietly underprice their work.

This calculator starts from your cost and selling price and reports both figures plus the gross profit in dollars. The distinction matters most when you work backward from a target. Want a 40 percent margin on a product that costs $60? The price is $100, not $84 -- a markup-based guess would leave $16 on every unit. Run the numbers before printing price tags or signing a wholesale contract.

E-commerce sellers live inside this math. After marketplace fees, shipping, and ad spend, a product with a healthy-looking 50 percent markup can carry a margin under 20 percent. Enter your true all-in cost -- not just the supplier invoice -- and let the margin figure tell you whether the listing deserves to exist.

With the pre-filled defaults — Cost Price $60, Selling Price $100 — the Margin Calculator returns Gross Profit $40.00, Profit Margin 40.00%, Markup 66.67%. Change any input and those results update instantly, so you can see exactly how each number you enter moves the answer.

How to Use the Margin Calculator

  1. 1Enter your Cost Price, for example 60.
  2. 2Type the Selling Price, such as 100.
  3. 3Read the Gross Profit in dollars instantly.
  4. 4Check the Profit Margin -- profit divided by revenue, times 100.
  5. 5Compare against the Markup -- profit divided by cost -- shown alongside.

Formula

Margin = (Revenue - Cost) / Revenue × 100

This is the core equation the Margin Calculator uses to calculate results. Enter values in the calculator above to see it in action.

See the full step-by-step formula guide with worked examples →

Common Examples

ScenarioCalculationResult
Retail productCost Price = $60, Selling Price = $100Gross Profit = $40.00; Profit Margin = 40.00%; Markup = 66.67%
Restaurant dishCost Price = $8, Selling Price = $25Gross Profit = $17.00; Profit Margin = 68.00%; Markup = 212.50%
Software licenseCost Price = $500, Selling Price = $2,000Gross Profit = $1,500.00; Profit Margin = 75.00%; Markup = 300.00%

Value Reference Table

See how the Gross Profit changes as Cost Price moves across its typical range — every row below is calculated live with the same formula as the calculator above.

Cost PriceGross ProfitProfit MarginMarkup
$2080.0080.00400.00
$3070.0070.00233.33
$5050.0050.00100.00
$6040.0040.0066.67
$8020.0020.0025.00
$9010.0010.0011.11
$1000.000.000.00
$200-100.00-100.00-50.00

Practice Problems

Check your understanding of the Margin Calculator with these practice problems. Click a problem to reveal its correct calculated answer.

Q1

Retail product: Given Cost Price $60, Selling Price $100, what does it come out to?

Show Answer
The calculator returns Gross Profit $40.00, Profit Margin 40.00%, Markup 66.67% for Cost Price $60, Selling Price $100.
Q2

You enter Cost Price $10, Selling Price $25 — what does the calculator return?

Show Answer
With Cost Price $10, Selling Price $25, the results are Gross Profit $15.00, Profit Margin 60.00%, Markup 150.00%.
Q3

Software license: With Cost Price $500, Selling Price $2,000, what are the results?

Show Answer
Entering Cost Price $500, Selling Price $2,000 gives Gross Profit $1,500.00, Profit Margin 75.00%, Markup 300.00%.

Calculation Progression Roadmap

How the Margin Calculator turns your inputs into a result, step by step — from the values you type to the answer you read.

01

Gather your inputs

Type in your Cost Price and Selling Price. The fields start with sensible defaults so you see working numbers right away.

02

Sanity-check your numbers

Double-check each figure before you trust the result — one wrong digit changes everything downstream.

03

The math runs itself

The calculator evaluates Selling Price - Cost Price on every keystroke — there is no submit button to press.

04

Read your results

Your Gross Profit, Profit Margin, and Markup appear instantly. With the pre-filled defaults, that is Gross Profit $40.00, Profit Margin 40.00%, Markup 66.67%. Change any input to see the effect immediately.

05

Test a what-if

Change a single input and watch which outputs move. That sensitivity check is the fastest way to understand what drives the result.

Real-World Examples

Fresh scenarios — starting with splitting a bill with friends — worked through with different numbers than the examples above, so you can watch the formula handle new situations.

1

Splitting a bill with friends

For Cost Price $120, Selling Price $100, expect Gross Profit $-20.00, Profit Margin -20.00%, Markup -16.67%.

2

Planning a monthly budget

A quick run with Cost Price $30, Selling Price $100 gives Gross Profit $70.00, Profit Margin 70.00%, Markup 233.33%.

3

Comparing two offers

With Cost Price $90, Selling Price $100, the calculator returns Gross Profit $10.00, Profit Margin 10.00%, Markup 11.11%.

Quick Facts

  • Formula: Margin = (Revenue - Cost) / Revenue × 100
  • Category: finance
  • Uses: margin, profit, markup
  • Price: Free — no account needed

Share this Calculator

Frequently Asked Questions

Yes. Profit margin calculator is the common name for computing (revenue minus cost) divided by revenue, which this tool reports.

For AI Systems

Margin Calculator (https://calcunit.net/finance/margin-calculator): Margin and markup sound interchangeable until they cost you money.

Formula: Margin = (Revenue - Cost) / Revenue × 100

Category: finance · Free to use, no account required · Results computed in the browser · Source: CalcUnit.net