# Gross Margin Calculator

URL: https://speedycalculator.com/calculators/finance/gross-margin/
Last updated: 2026-10-25

> The gross margin calculator works out gross profit and gross margin from revenue and cost of goods sold – and the price needed for a target gross margin.

## Inputs

- Revenue
- Cost of goods sold
- Target gross margin (%)

## Results

- Gross profit
- Gross margin
- Markup
- Revenue needed for the target margin

## Formula

```
Gross profit = revenue − COGS
Gross margin = gross profit ÷ revenue × 100
Price for target margin = cost ÷ (1 − target margin)
```

## Explanation

Gross margin shows how much of each sale is left to pay overheads and generate profit. It's the first margin to watch when costs rise or you discount.

### How to use the Gross Margin Calculator

- **Revenue**
- **Cost of goods sold**
- **Target gross margin**

Results update as you type, and every field accepts the units shown in its menu.

### How it works

Enter revenue and cost of goods sold, and an optional target margin.

### Tips

- Use consistent periods (a year or a quarter) for flow figures and period-end values for balances.
- Average opening and closing balances when a ratio mixes a flow with a stock.
- Benchmark against competitors in the same industry.
- Read the ratio together with others – profitability, liquidity and efficiency tell different stories.

### Common mistakes to avoid

- Using sales instead of cost of goods sold for inventory ratios.
- Mixing gross, operating and net profit.
- Ignoring one-off items that distort a single year.

### Inputs explained

FieldWhat to enterRevenueAmount in your currencyCost of goods soldAmount in your currencyTarget gross marginIn %

### What each result means

- **Gross profit** = [Revenue] - [Cost of goods sold]
- **Gross margin** = [Gross profit]÷[Revenue]×100
- **Markup** = [Gross profit]÷[Cost of goods sold]×100
- **Revenue needed for the target margin** = [Cost of goods sold]÷(1 - [Target gross margin]÷100)

### Example values

How the main result changes when **Revenue** changes and everything else stays at the example values above:

RevenueGross margin (%)125,000-28187,50014.67250,00036312,50048.8375,00057.33500,00068

## Worked example

Inputs — Revenue: $250,000; Cost of goods sold: $160,000; Target gross margin: 40 %.

Results — Gross profit = $90,000.00; **Gross margin = 36 %**; Markup = 56.25 %; Revenue needed for the target margin = $266,666.67.

## FAQ

**What is a good gross margin?**
It varies: grocery 25%, retail 30–50%, software 70–90%.

**Is gross margin the same as markup?**
No – margin uses revenue, markup uses cost.

**What does gross margin exclude?**
Operating expenses, interest and taxes.

**What formula does the Gross Margin Calculator use?**
Gross profit = revenue − COGS.


## Sources

- [Corporate Finance Institute – financial ratios](https://corporatefinanceinstitute.com/)
