Margin Calculator
Calculate profit margin, markup percentage, selling price, and true e-commerce profit instantly – securely in your browser.
Why Use This Tool?
Setting accurate product pricing and understanding the difference between profit margin and markup is essential for e-commerce sellers, agencies, and retail managers. Our free Margin Calculator computes your exact selling price, gross profit, margin percentage, and markup percentage in real time, and shows your true net profit after marketplace fees, payment fees, shipping, and ad costs.
All pricing calculations run locally inside your web browser, ensuring your unit costs and commercial pricing figures stay completely confidential.
How to Use This Tool
4 Quick StepsChoose a Calculation
Pick Margin, Selling price, Maximum cost, E-commerce profit, or the Margin to Markup converter.
Enter Your Numbers
Input your item cost, selling price, or target margin, plus fees, shipping, and ad costs for online sales.
View Profit Breakdown
Instantly see profit, margin, markup, break-even price, and a visual breakdown of where every sale goes.
Compare Scenarios
Use the discount and pricing tables to test price tiers, then copy or share the results on WhatsApp.
Margin Calculator
Work out profit, margin and markup, find the right selling price, or see your true e-commerce profit after fees, shipping and ads.
Found this useful?
Margin and Markup Formulas
Margin and markup both start with the same profit, but they divide it by different numbers. Margin divides by the selling price, and markup divides by the cost. Here is every formula the calculator uses, with an item that costs 60 and sells for 100.
| Calculation | Formula | Example |
|---|---|---|
| Profit | Selling price – Cost | 100 – 60 = 40 |
| Margin % | Profit / Selling price x 100 | 40 / 100 x 100 = 40% |
| Markup % | Profit / Cost x 100 | 40 / 60 x 100 = 66.67% |
| Selling price from margin | Cost / (1 – Margin / 100) | 60 / (1 – 0.40) = 100 |
| Selling price from markup | Cost x (1 + Markup / 100) | 60 x (1 + 0.6667) = 100 |
| Maximum cost | Selling price x (1 – Margin / 100) | 100 x (1 – 0.40) = 60 |
Margin to Markup Conversion Table
Use this table to switch between the two. To reach the margin on the left, add the markup on the right to your cost.
| Margin | Markup Needed |
|---|---|
| 10% | 11.11% |
| 20% | 25% |
| 25% | 33.33% |
| 30% | 42.86% |
| 40% | 66.67% |
| 50% | 100% |
| 60% | 150% |
| 75% | 300% |
Real E-commerce Profit After Fees and Ads
A product with a 70% gross margin can still earn far less once shipping, payment fees and advertising are paid. Here is the example from the E-commerce profit mode.
| Item | Amount |
|---|---|
| Selling price | 49.99 |
| Product cost | – 15.00 |
| Shipping and packaging | – 7.00 |
| Payment fee (2.9% + 0.30) | – 1.75 |
| Ad cost per sale | – 8.00 |
| Net profit per order | 18.24 (36.49% net margin) |
| Break-even price | 31.20 |
| Most you can spend on ads per sale | 26.24 (break-even ROAS 1.91x) |
Frequently Asked Questions
Quick answers to common questions about profit margin, markup and pricing.
How do I calculate profit margin?
Subtract the cost from the selling price to get the profit, then divide the profit by the selling price and multiply by 100. For example, an item that costs 60 and sells for 100 makes 40 profit, which is a 40% margin.
What is the difference between margin and markup?
Both use the same profit, but margin compares it with the selling price while markup compares it with the cost. Buying at 60 and selling at 100 is a 40% margin but a 66.67% markup. Margin can never reach 100%, while markup can be any size.
How do I find the selling price from cost and margin?
Divide the cost by 1 minus the margin as a decimal. For a cost of 60 and a 40% margin, the price is 60 / 0.60 = 100. Choose Selling price in the calculator, enter the cost and target margin, and it also shows the price at other common margins.
Why is a 40% markup not the same as a 40% margin?
A 40% markup on a 60 cost gives a price of 84, which is only a 28.57% margin. Many sellers add a markup when they mean to reach a margin and end up with less profit than planned. Use the Target margin or Target markup switch to see the difference.
How much can I pay for a product and still hit my margin?
Choose Maximum cost, enter your selling price and the margin you need, and the calculator shows the most you can pay per item. For a 100 price and a 40% margin, the maximum cost is 60.
How do I calculate e-commerce profit after fees and ads?
Choose E-commerce profit and enter your price, product cost, shipping, packaging, marketplace fee, payment fee and ad cost per sale. The calculator shows your net profit per order, net margin, break-even price, the most you can spend on ads and the price you need for your target margin.
What is break-even ROAS?
ROAS is return on ad spend, or revenue divided by ad spend. Break-even ROAS is the lowest ROAS at which your ads still pay for themselves. If it is 2x, every 1 spent on ads must bring at least 2 in sales or you lose money.
How does a discount affect my margin?
A discount comes straight out of your profit, so margin falls much faster than the price. With a 40% margin, a 20% discount halves your profit, so you need twice as many sales to earn the same amount. The discount table in the Margin mode shows this for every common discount.
What is a good profit margin?
It depends on the business. Retail and e-commerce products often aim for a 30% to 50% product margin, grocery and electronics run much lower, and software and services can be far higher. After fees, shipping and ads, a net margin of 10% to 20% is healthy for many online stores.
Can a margin be more than 100%?
No. A 100% margin would mean the item cost nothing, so margin always stays below 100%. Markup has no limit, so a 200% markup is possible and equals a 66.67% margin.
Is gross margin the same as net margin?
No. Gross margin only subtracts the product cost. Net margin also subtracts shipping, fees, advertising and other costs, so it shows what you really keep. The E-commerce profit mode shows both.
Is my pricing data saved or sent anywhere?
No. Every calculation runs in your browser, so your costs and prices never leave your device. The calculator is free with no signup.
Related Free Tools
These free tools work well alongside the Margin Calculator. Like this one, they all run privately in your browser.