Gross margin calculator. Price, cost, margin and markup, with the math shown.
Enter what you charge and what the work costs you to get gross profit, gross margin and markup. Or start from your cost and the margin you want, and get the price to charge. Each result shows the formula with your numbers.
Free, no signup. Updated December 1, 2026.
Margin from price and cost
- Gross profit
- $3,000.00
- Markup on cost
- 42.9%
- Gross margin
- 30.0%
The math
- Gross profit = price - cost = $10,000.00 - $7,000.00 = $3,000.00
- Gross margin = gross profit ÷ price × 100 = $3,000.00 ÷ $10,000.00 × 100 = 30.0%
- Markup = gross profit ÷ cost × 100 = $3,000.00 ÷ $7,000.00 × 100 = 42.9%
Price for a target margin
- Gross profit
- $3,000.00
- Markup to use on cost
- 42.9%
- Price to charge
- $10,000.00
The math
- Price = cost ÷ (1 - margin ÷ 100) = $7,000.00 ÷ (1 - 0.3) = $10,000.00
- Gross profit = price - cost = $10,000.00 - $7,000.00 = $3,000.00
- Markup = margin ÷ (100 - margin) × 100 = 30% ÷ (100 - 30) × 100 = 42.9%
Runs in your browser. Nothing you type is saved or sent to us.
How to use the gross margin calculator. 4 steps.
01
Enter the price
The amount you charge for the job or line, before sales tax.
02
Enter your cost
What the work costs you: labor with its burden (the labor burden calculator gives the hourly rate), materials, equipment and subcontractors.
03
Read margin and markup
Gross profit, gross margin and markup on cost update as you type, with the math under them.
04
Or work backward
Enter your cost and the margin you want, and the right side gives the price to charge and the markup that gets you there.
Gross margin questions. Plain answers.
- What is gross margin?
- Gross margin is gross profit as a percent of the price. Gross profit is the price minus the cost of doing the work. A job you sell for $10,000 that costs you $7,000 has $3,000 of gross profit and a 30% gross margin.
- How do I calculate gross margin?
- Subtract the cost from the price, divide by the price, and multiply by 100. Gross margin = (price - cost) ÷ price × 100. For $10,000 and $7,000: ($10,000 - $7,000) ÷ $10,000 × 100 = 30%.
- What is the difference between gross margin and markup?
- Both are gross profit as a percent, on a different base. Margin divides the profit by the price; markup divides it by the cost. The same $3,000 profit on a $7,000 cost and a $10,000 price is a 30% margin and a 42.9% markup. The markup vs margin calculator converts one to the other.
- How do I price a job to hit a target margin?
- Divide the cost by one minus the margin. Price = cost ÷ (1 - margin ÷ 100). For a 30% margin on $7,000 of cost: $7,000 ÷ 0.70 = $10,000. Adding 30% to the cost instead gives $9,100, which is only a 23.1% margin.
- What costs should I put in?
- The calculator uses whatever cost you enter. For a job's gross margin, enter the direct cost of the work: field labor with its burden, materials, equipment and subcontractors. Office rent, trucks you don't charge to the job, and admin salaries then have to come out of the gross profit. The labor burden calculator gives you the true hourly cost of field labor.
- What gross margin should a contractor aim for?
- It depends on your trade, job size and overhead, so this page does not give a benchmark. Work it backward instead: the gross margin has to cover your overhead and leave the net profit you want. If overhead runs 15% of revenue and you want 10% left over, you need about a 25% gross margin on the work you sell.
- Can gross margin be more than 100% or negative?
- It can't be more than 100%, because that would mean the work cost less than nothing. At a cost of $0 the margin is exactly 100%. It is negative when the cost is more than the price: the job lost money.
- Is what I type saved?
- No. The calculator runs in your browser and nothing you type is stored or sent to us. Close the page and the numbers are gone.
More free tools for contractors.
- Markup vs margin calculator
Convert markup to margin and back, with a chart of common values and why the two get mixed up.
- Labor burden calculator
Wage, payroll taxes, workers' comp, benefits, paid time off and unbillable hours to a burdened cost per billable hour.
- Purchase order generator
Fill in a PO with agreed prices and terms, download a PDF or CSV. Blank templates too.
- Change order generator
Price a change with overhead, profit and days, see the revised contract sum, download a PDF.
Margin you priced can still leak at the supplier invoice. Send us a batch of supplier invoices with your POs and price agreements, and the supplier invoice variance report shows each overcharge on its own page.