Profit Margin Calculator

See profit, profit margin, and markup from a cost and a selling price (revenue), or switch mode to turn a cost plus a target margin into the required selling price. Dollars round half-up to cents; percents stay readable. Press Calculate for the breakdown.

Profit margin inputs

How profit margin results are calculated

Two modes share one set of definitions. From cost + revenue: profit = revenue − cost, marginPercent = (profit ÷ revenue) × 100, and markupPercent = (profit ÷ cost) × 100. Revenue must be greater than 0 (margin divides by revenue). Cost must be greater than 0 (markup divides by cost). Cost higher than revenue is allowed and yields a negative profit.

Target margin: sellingPrice = cost ÷ (1 − marginPercent ÷ 100) when the margin is below 100. A margin of 100% or more is rejected. Money amounts use round-half-up to cents (same approach as the discount calculator) before percents are taken, so the percents match the dollars on screen. Percents display with at most six significant digits and four decimal places.

Worked examples

Cost $40, revenue $50

Profit = $50 − $40 = $10.00. Margin = ($10 ÷ $50) × 100 = 20%. Markup = ($10 ÷ $40) × 100 = 25%.

Cost $25, revenue $100

Profit = $100 − $25 = $75.00. Margin = 75%. Markup = ($75 ÷ $25) × 100 = 300%.

Cost $80, target margin 20%

Selling price = $80 ÷ (1 − 20 ÷ 100) = $100.00. Profit $20.00, margin 20%, markup 25%.

Formula

profit = revenue − cost; marginPercent = (profit / revenue) × 100; markupPercent = (profit / cost) × 100; target sellingPrice = cost / (1 − marginPercent/100) when margin < 100

Not financial advice

This profit margin calculator is for general arithmetic only and is not financial, tax, investment, accounting, or professional advice. Results are rounded to cents and display-rounded percents, and may differ from your books, POS, or tax return. Verify critical figures with an accountant or your own records before pricing or reporting. GlobalToolHub assumes no liability for decisions made using these estimates.

Frequently asked questions

What is the difference between profit margin and markup?

Margin is profit divided by revenue (selling price). Markup is profit divided by cost. On a $40 cost and $50 selling price, profit is $10, margin is 20%, and markup is 25%. The same dollar profit is a smaller percent of the higher selling price than of the cost.

How is profit calculated from cost and revenue?

Profit = revenue − cost. Example: $50 revenue and $40 cost → profit $10.00. Margin = ($10 ÷ $50) × 100 = 20%. Markup = ($10 ÷ $40) × 100 = 25%.

How do I find the selling price for a target margin?

Selling price = cost ÷ (1 − margin ÷ 100), and the margin must be less than 100%. Example: cost $80 and a 20% target margin → $80 ÷ 0.80 = $100.00 selling price, profit $20.00, markup 25%.

Can profit be negative if cost is higher than revenue?

Yes. Cost above revenue is allowed and means a loss. Cost $50 and revenue $40 → profit −$10.00, margin −25%, markup −20%. Negative cost or negative revenue is rejected.

Why is a 100% target margin rejected?

A 100% margin would mean profit equals the entire selling price and cost is zero, so selling price = cost ÷ 0. That division is undefined. Margins of 100% or more return a clear error instead of Infinity.

How are dollars and percents rounded?

Money uses round-half-up to cents (same approach as the discount calculator) before margin and markup are computed, so the percents match the dollars shown. Percents use up to six significant digits and at most four decimal places. Cents rounding can nudge a target margin slightly (for example $1 at 10% becomes a $1.11 price and a 9.9099% actual margin).

What if cost or revenue is zero?

Margin divides by revenue and markup divides by cost, so either value at zero (including amounts that round to $0.00) returns an error instead of Infinity or NaN. Enter a cost and a revenue greater than $0.00.

Related tools

Discount Calculator Percentage Calculator Paint Calculator Unit Converter Text Counter