Margin Calculator (General Version)
Calculate margin from cost and selling price
Enter your cost and selling price to see profit per unit, gross margin, and markup. Use Advanced only if you want totals or a target margin price.
Advanced (optional)
Margin calculator for pricing products and checking profitability
This margin calculator is built for one job: check whether a selling price is profitable compared to your cost, and understand what that means in practical terms. If you sell a product or a service, you are usually making a pricing decision, not doing accounting. You want to know the profit per unit, the gross margin percentage, and how your pricing compares to your cost base.
The calculator uses the standard gross margin formula: profit equals selling price minus cost, and gross margin percentage equals profit divided by selling price. It also shows markup percentage, which is profit divided by cost. Margin and markup are often confused. They answer different questions, and mixing them up leads to wrong pricing.
Use the default view when you have two numbers: your cost per unit and your selling price per unit. The output gives you a quick sanity check. If your margin is low, you will struggle to cover overheads, discounts, refunds, payment fees, and normal business variability. If your margin is negative, you are selling below cost and losing money on each unit, even before overheads.
Assumptions and how to use this calculator
- This calculator reports gross margin, not net profit. It does not include rent, salaries, marketing spend, tax, or other overheads unless you add those into your cost per unit yourself.
- “Cost” should be your direct unit cost (often called cost of goods sold). For services, treat it as the direct delivery cost per job or hour you want to recover.
- Selling price is assumed to be the amount the customer pays before any discounts you plan to apply. If you discount often, use an expected average selling price.
- Quantity is optional and is only used to scale per-unit results into totals. If you do not know quantity, leave it blank and the calculator will assume 1.
- Target margin pricing is optional. If you enter a target margin percent, the calculator estimates the selling price needed to hit that margin on the given cost.
Common questions
What is the difference between margin and markup?
Margin is profit divided by selling price. Markup is profit divided by cost. A 50% markup is not a 50% margin. For example, if cost is 100 and price is 150, profit is 50. Markup is 50%, but margin is 33.33%.
Why can my margin look “good” but I still feel broke?
Because gross margin does not include overheads and cash timing. You can have a healthy margin per unit but still run out of cash if overheads are high, inventory sits too long, customers pay late, or you reinvest aggressively.
What should I use for cost if I am not sure?
Use your best estimate of direct unit cost. For products, include purchase cost plus unavoidable per-unit fees like packaging and payment processing. For services, include the direct time cost you want to recover. If you are unsure, do not pretend you are precise. Start with a conservative estimate and update it when you have better data.
What does a negative margin mean?
It means your cost is higher than your selling price. You lose money on each unit before you even consider overheads. If you are doing this intentionally as a loss leader, you need a clear plan for how you recover that loss elsewhere.
How do I use target margin pricing correctly?
Pick a margin that makes sense for your business model and risk. Enter it as a percentage. The calculator then estimates the selling price needed to hit that margin on the given cost. If the required price is not viable in your market, your options are to reduce cost, increase perceived value, change the offer, or accept a lower margin knowingly.