In short
This profit margin calculator shows how much of your revenue is left as profit after the costs you include. It gives the profit in dollars, the profit margin (profit as a share of revenue) and the markup (profit as a share of cost).
Use it for one product, one order or one month: enter revenue and cost for the same thing and the result updates as you type. If you only have a percentage, switch to Convert a percentage. It turns a markup into a margin, or a margin into the markup you need, with no dollar amounts.
- Example margin35%on $80.00 of revenue
- Example markup53.85%the same $28.00 of profit
- Profit$28.00$80.00 − $52.00
- Convert23.08%margin from a 30% markup
Inputs
How to use it
Before you start
Which costs to put in the profit margin calculator
The result is only as complete as the costs you enter. These are the choices most sellers make.
Count these
5- Product or materialsYesThe basic cost of the item.
- PackagingYesYou pay for it with every order.
- Shipping you payYesIf buyers pay you for shipping, count that money as revenue too.
- Marketplace and payment feesYesThey come out of every sale.
- Refunds and returnsYesThey lower revenue or add cost, so use your usual rate.
Your call
2- AdvertisingIt dependsInclude it for a profit-after-ads view. Leave it out if you will use the margin to find break-even ROAS.
- Your own timeYour choiceCounting it shows what you really earn. Leaving it out shows the margin on the goods.
Not per order
1- Rent, software and other fixed costsNot per orderPut them in a monthly view or a break-even calculation.
These are common choices, not rules. Pick one set, use it every time, and your results will be comparable.

The math
Profit margin and markup formulas
Revenue is the amount received. Included cost is the total you entered. The margin formula divides by revenue. The markup formula divides by cost. So the same profit gives two different percentages. In convert mode both are written as numbers (30 for 30%), and markup is always measured on cost.
Take the money you receive and subtract the costs you chose to include.
Divide the profit by the revenue, then multiply by 100 to turn it into a percent. It tells you how many cents of every dollar you keep.
Divide the profit by the cost instead of the revenue, then multiply by 100. It tells you how much you added on top of what the item cost.
Think of the cost as 100 parts. The price is those 100 parts plus the markup. So the profit's share of the price is the markup divided by (100 + markup).
Think of the price as 100 parts. The margin is the profit part and the rest is cost, so divide the profit part by the cost part.
Multiply your cost by this number to get the price.
Excel and Google Sheets
Profit margin in Excel or Google Sheets
The same calculation works in Excel and Google Sheets. Put the headings in row 1 and the numbers in row 2.
| Cell | What it holds | Enter |
|---|---|---|
| A2 | Revenue | 80 |
| B2 | Included cost | 52 |
| C2 | Profit | =A2-B2 |
| D2 | Profit margin (format as %) | =C2/A2 |
| E2 | Markup (format as %) | =C2/B2 |
| F2 | Price for a 30% margin, rounded up to the cent | =ROUNDUP(B2/(1-0.3), |
| G2 | Markup from the margin in D2 (format as %; matches E2) | =D2/(1-D2) |
| H2 | A markup to convert (type it with the % sign) | 30% |
| I2 | Margin from the markup in H2 (format as %) | =H2/(1+H2) |
Example
Profit margin example, step by step
Take an illustrative sale of $80.00 where the included costs add up to $52.00. These are the calculator's starting numbers.
Of every $1 of revenue, about 35¢ is left after the included costs. Measured against cost, the same $28.00 is a 53.85% markup.
Convert mode
Converting a percentage
In convert mode the calculator starts at a 30% markup. No dollar amounts are needed; the $100 row only checks the answer.
- Markup you enter30%Starting value
- Margin23.08%30 ÷ (100 + 30) × 100
- Price as a multiple of cost×1.31 + 30 ÷ 100
- Check with dollars23.08%$100.00 cost, $130.00 price: $30.00 ÷ $130.00 × 100
Adding 30% to your cost keeps 23.08% of the price, not 30%. To keep 30% of the price you need a 42.86% markup.
Picture it
Where the $80.00 goes
Same profit, two percentages
Margin and markup, side by side
Margin · Markup
Three cases
More examples
| Case | Revenue | Included cost | Profit | Margin | Markup |
|---|---|---|---|---|---|
| One $38 order | $38.00 | $22.40 | $15.60 | 41.05% | 69.64% |
| A month of sales | $12,400.00 | $9,300.00 | $3,100.00 | 25% | 33.33% |
| The $80 item at 10% off | $72.00 | $52.00 | $20.00 | 27.78% | 38.46% |
The order's cost is $12.00, $1.50, $5.50, $3.40: materials, packaging, postage and fees, all assumed for the example. The discount row keeps the $52.00 cost of the worked example.
Interpret
What your margin and markup mean
Margin and markup answer different questions
Margin tells you how much of each dollar you take in is left. Markup tells you how much you added on top of what the item cost. With a positive profit, markup is always larger than margin.
A negative result is a loss
If costs are above revenue the profit is negative. With $50.00 of revenue and $80.00 of cost, profit is -$30.00, margin is -60% and markup is -37.5%.
Margin cannot pass 100%
With no cost at all, you keep all of the revenue and the margin is 100%. Markup has no such limit, and with zero cost it is undefined because you cannot divide by zero.
A converted percentage fits any cost
Convert mode does not need a dollar amount. A 30% markup is a 23.08% margin on a $5 item and on a $5,000 one. This holds when the markup is on the same cost that the margin subtracts.
Convert from the number you set
Results are rounded to two decimals, so converting a result back can miss by a hundredth. A 30% markup gives a 23.08% margin, but 23.08% converts back to a 30.01% markup because it was rounded from 23.0769%.
Targets
What is a good profit margin?
There is no number that is good for every business. A margin is good when it pays for everything you have to cover and still leaves what you want to earn. Work backward from that.
- Start from the goodsWith $10,000.00 of monthly revenue and $6,500.00 of product, packaging, shipping and fees, profit is $3,500.00 and the margin is 35%.
- Subtract what you pay whatever you sellAdd $2,000.00 of rent, software and subscriptions. The cost is now $8,500.00, so $1,500.00 is left, which is 15% of revenue.
- Set the margin you needTo take home $2,500.00 a month on $10,000.00 of revenue, the goods must earn 45%. That is a better target than an average.
Compare your margin with your own earlier months and between your products before you compare it with anyone else. Averages published elsewhere count different costs for different years, so this page quotes none.
Names
Gross, operating and net margin
These names describe how many costs were subtracted. The calculator gives whichever one matches the costs you enter. Enter only the cost of the goods you sold, and it works as a gross profit margin calculator.
The income statement levels follow OpenStax Financial Accounting, listed under sources.
Avoid
Margin mistakes that change the answer
Mixing units or periods
Use revenue and cost for the same item or the same period. Monthly revenue with a per-item cost gives a result that means nothing.
Leaving out costs
Fees, shipping you pay and packaging all lower profit. If they are not in the included cost, the margin looks better than your real one.
Treating a markup as a margin
Adding 40% to a $36.00 cost gives a price of $50.40, but the margin on that price is only 28.57%. To reach a margin you want, work from the price instead.
Wrong40% markup:$50.40 price, 28.57% marginRight40% margin:$60.00 price

Look it up
Quick reference tables
| If your margin is | Your markup is | Price = cost × |
|---|---|---|
| 10% | 11.11% | 1.1111 |
| 20% | 25% | 1.25 |
| 25% | 33.33% | 1.3333 |
| 30% | 42.86% | 1.4286 |
| 40% | 66.67% | 1.6667 |
| 50% | 100% | 2 |
| 60% | 150% | 2.5 |
From the conversion formulas above. Percentages are rounded to two decimals and multiples to four.
| If your markup is | Your margin is | Price = cost × |
|---|---|---|
| 10% | 9.09% | 1.1 |
| 20% | 16.67% | 1.2 |
| 25% | 20% | 1.25 |
| 30% | 23.08% | 1.3 |
| 40% | 28.57% | 1.4 |
| 50% | 33.33% | 1.5 |
| 75% | 42.86% | 1.75 |
| 100% | 50% | 2 |
| 150% | 60% | 2.5 |
| 200% | 66.67% | 3 |
To find the price that gives a target margin, use the Product Pricing Calculator under Related. It has its own table of prices for common targets.
Limits
Costs and limits this margin math ignores
- Only the costs you enter are subtracted. No platform fees, taxes or overhead are added automatically.
- Revenue must be above $0. Cost can be $0.
- Amounts accept up to two decimal places and up to $1 billion. Money is handled in whole cents, and percentages show up to two decimals.
- It is a calculation, not accounting, tax or financial advice.
- It runs in your browser. Nothing you enter is saved or sent anywhere.
- Convert mode accepts a markup from 0% to 10,000% and a margin from 0% to 99.99%, with up to two decimals. A 100% margin would mean zero cost, so it has no markup. Negative percentages are not accepted there; use price and cost for a loss.
- The price multiple shows up to four decimals. On a $1,000 cost, ×1.4286 gives $1,428.60, while $1,000 ÷ 0.70 rounded up to the cent is $1,428.58. For an exact price, use the Product Pricing Calculator.
Questions
Questions
Why are my margin and markup different?
Margin is profit divided by revenue. Markup is profit divided by cost. The profit in dollars is the same, but the denominator changes the percentage. Margin vs markup: how to calculate each
Can the margin be negative or above 100%?
It can be negative when costs are above revenue. It cannot go above 100% unless cost were negative, which the calculator does not accept.
How do I find the price that gives a target margin?
Write the margin you want as a decimal and take it away from 1. Divide the cost by the result. Then round up to the next cent, so the margin does not fall below your target. Use the Product Pricing Calculator
Does it include marketplace fees?
Not on its own. Add the fees you pay to the included cost. For Etsy US orders there is a calculator that works out the fees for you. Open the Etsy Fee & Profit Calculator (US)
Why does my margin drop when I give a discount?
The cost stays the same while revenue falls, so every dollar of discount comes straight out of profit. A 10% discount takes the $80.00 example to $72.00, profit falls from $28.00 to $20.00, and margin falls from 35% to 27.78%.
How do I get a 30% margin on a $50.00 cost?
Divide the cost by 0.70. That gives $71.43, which leaves $21.43 of profit, rounded up to the next cent. The quick reference tables show other target margins.
How do I calculate profit margin in Excel or Google Sheets?
Put revenue in A2 and cost in B2, then use =(A2-B2)/A2 and format the cell as a percentage. The spreadsheet section above lists every formula, including markup and a target price.
Is markup based on cost or on the selling price?
On this page markup is always measured on cost: selling price minus purchase price, divided by purchase price, times 100, as OpenStax defines it. Some retailers quote a markup on the selling price instead. The University of Maine Cooperative Extension notes that the retail trade calls that number a margin. So if someone quotes a 30% markup on retail, convert it as a 30% margin.
What margin does keystone pricing give?
Keystone pricing doubles the wholesale price. Doubling is a 100% markup, which is a 50% margin. On a $20.00 cost, the price is $40.00, and the $20.00 of profit is half of that price.
Can I convert a gross margin to a markup?
Yes, as long as the markup is on the same cost. Gross margin is net sales minus the cost of goods sold, divided by net sales; Shopify's profit reports use ([net sales − cost] ÷ net sales) × 100. A 40% gross margin converts to a 66.67% markup on the cost of goods sold, not on all your costs.
Sources
Sources and review
Sources5 official pages, each read on the date shownShow allHide
- Shopify profit reportshelp.shopify.com · Read
Definitions of profit and margin as used in a store report, and gross margin as (net sales − cost) ÷ net sales × 100. This page is not a Shopify fee estimate.
- OpenStax Contemporary Mathematics 6.2: discounts, markups and sales taxopenstax.org · Read
How markup is defined on cost, and price = cost × (1 + markup).
- OpenStax Principles of Marketing 18.3: retailing strategy decisionsopenstax.org · Read
Markup as (selling price − purchase price) ÷ purchase price × 100, keystone pricing as doubling the wholesale price, and gross margin as net sales minus the cost of goods sold, shown as a share of net sales.
- University of Maine Cooperative Extension, Bulletin #3000: Basic Pricing Strategies for Small Businessesextension.umaine.edu · Read
Markup can be quoted on cost or on the selling price; the retail trade calls a markup on the selling price a margin.
- OpenStax Financial Accounting 6.6: multi-step income statementsopenstax.org · Read
Gross margin, income from operations and net income as the successive levels of an income statement.
The page text was last updated on October 25, 2026 and the sources were last checked on October 7, 2026. Example figures are illustrative and were made with the same formulas as the calculator.
Found a mistake or something unclear? Tell us. See how we check our pages.