Gross Profit Calculator

Calculate gross profit, gross margin, and COGS percentage from business totals or per-unit economics. Use net sales directly, derive net sales from sales reductions, or scale unit economics by quantity.

Choose the form that matches the figures you already have.
Display only. No currency conversion is performed.
Sales after returns, allowances, and sales discounts when those reductions apply.
Use the COGS figure that matches the same reporting period and sales basis.

Net sales = gross sales − returns/allowances − sales discounts. Enter only reductions that belong in your sales reporting definition; do not subtract COGS here.

Use the realized net price per unit for the scenario you are modeling.
May be a whole-unit count or another positive sales quantity appropriate to your model.
Optional result display

Your Gross Profit Results

Net sales 0 revenue basis
COGS 0 cost of goods sold
Gross margin 0 gross profit ÷ net sales
Gross Profit 0 net sales − COGS
Enter values for the selected calculation method.
Business view: 0

Calculation breakdown

Net sales0
COGS0
Gross profit formula0
Gross margin0
COGS as % of sales0

Transparent formula

Gross profit: net sales − cost of goods sold (COGS).

Gross margin %: gross profit / net sales × 100. COGS %: COGS / net sales × 100.

Gross profit is before selling, general, administrative, interest, tax, and other expenses that are outside the COGS definition used for the calculation.

Gross profit measures what remains from net sales after subtracting the cost of goods sold. It is an important operating checkpoint because it separates product or service delivery economics from many other business expenses. A company can have positive gross profit and still report a net loss after operating and non-operating expenses.

How to use the Gross Profit Calculator

Choose the input method that matches your data. If your accounting or reporting system already gives you net sales and COGS, use the default Net sales + COGS mode. This is the shortest path and avoids rebuilding values you already know.

If you have gross sales plus sales returns, allowances, or sales discounts, choose Gross sales − reductions + COGS. The calculator first derives net sales, then subtracts COGS.

If you are modeling one product or a simple sales scenario, choose Per-unit × quantity. Enter the realized net selling price per unit, COGS per unit, and quantity sold. The calculator scales both sales and COGS to the same quantity before calculating gross profit.

The currency selector changes display labels only and never applies an exchange rate. Use one consistent currency across all entered values.

What is gross profit?

Gross profit is the amount remaining after cost of goods sold is subtracted from net sales. On a multi-step income statement, it appears before many operating expenses and non-operating items.

Gross Profit = Net Sales − Cost of Goods Sold

Suppose net sales are 100,000 and COGS is 62,000. Gross profit is 38,000. That 38,000 is not automatically final profit because the business may still have payroll, rent, software, marketing, depreciation, interest, taxes, and other costs outside COGS.

Gross profit can be calculated for an entire business, a reporting segment, a product line, or a single unit, provided sales and cost figures use a consistent scope.

Gross profit and gross margin formulas

The core dollar or currency formula is:

Gross Profit = Net Sales − COGS

To express that result relative to revenue, calculate gross margin:

Gross Margin % = Gross Profit / Net Sales × 100

You can also examine the share of net sales consumed by COGS:

COGS % of Sales = COGS / Net Sales × 100

When net sales are positive, gross margin percentage plus COGS percentage equals 100%. This provides a useful arithmetic cross-check.

Net sales vs gross sales

Gross sales and net sales are not always the same number. Gross sales may be reduced by items such as sales returns, allowances, or sales discounts, depending on the reporting system and business.

Net Sales = Gross Sales − Sales Returns/Allowances − Sales Discounts

For example, gross sales of 220,000 with 20,000 of returns and allowances produce net sales of 200,000 before COGS is considered.

Do not subtract COGS as if it were a sales reduction. COGS is deducted after net sales to determine gross profit.

Definitions can vary across platforms and internal reports. When reconciling to accounting software, use the same revenue definition and period that the source system uses.

What belongs in cost of goods sold?

COGS represents the costs assigned to the goods or services sold under the accounting approach being used. For a retailer, this often centers on inventory cost associated with units sold. For a manufacturer, it can include product manufacturing costs assigned to sold units. Service businesses may use a cost-of-services or cost-of-revenue concept instead.

The exact classification matters. Some costs that feel “related to selling” are not necessarily COGS. Advertising, general office salaries, rent, software, and other selling or administrative expenses are commonly outside gross profit, although industry and accounting practices differ.

This calculator therefore does not attempt to build COGS from universal cost assumptions. Enter the COGS figure appropriate to your business, report, accounting policy, or management analysis.

Consistency is essential when comparing periods. If one period includes certain fulfillment costs in COGS and another classifies them elsewhere, the gross-margin change may partly reflect accounting classification rather than underlying economics.

Gross profit vs gross margin

Gross profit is an absolute amount. Gross margin is the same gross profit expressed as a percentage of net sales.

For net sales of 80 and COGS of 50, gross profit is 30 and gross margin is 37.5%.

30 / 80 × 100 = 37.5%

The percentage is often useful for comparing businesses or periods of different sizes, while the gross-profit amount shows how much currency is actually available before other expenses.

Do not confuse gross margin with markup. Markup divides the profit amount by cost, not sales. In the same 80-sales and 50-cost example, markup is 30/50 = 60%, even though gross margin is 37.5%.

Can gross profit be negative?

Yes. If COGS exceeds net sales, the result is a gross loss. For example, net sales of 40,000 and COGS of 46,000 produce gross profit of −6,000 and a gross margin of −15%.

A gross loss means the sales generated in that scope and period did not cover the COGS assigned to them before considering other expenses.

This may arise from low selling prices, high product costs, inventory write-down effects within the chosen COGS measure, unusual production conditions, product mix changes, or other factors. The calculator identifies the arithmetic result but does not diagnose the business cause.

Per-unit gross profit and quantity

For a simple single-product scenario, per-unit gross profit is:

Gross Profit per Unit = Net Selling Price per Unit − COGS per Unit

If both unit values are consistent across the modeled quantity, total gross profit is:

Total Gross Profit = (Unit Price − Unit COGS) × Quantity

For example, a product selling at a net 45 per unit with 27 of COGS generates 18 of gross profit per unit. At 1,000 units, that is 18,000 of gross profit.

Real ecommerce data can involve variable discounts, returns, shipping treatment, product mix, and different unit costs. In those cases, using actual aggregate net sales and COGS may be more accurate than assuming one average unit.

Gross profit vs net profit

Gross profit subtracts COGS from net sales. Net profit goes further by accounting for additional expenses and, depending on the definition used, other income and expense items.

A company can therefore have a strong gross margin but weak or negative net profit if operating expenses are high. Conversely, improving gross profit can give the business more capacity to absorb fixed operating costs.

Because “net profit” can be used differently in informal contexts, reconcile any analysis to the specific income-statement definition you are using.

How to interpret changes in gross profit

An increase in gross profit can come from higher sales volume, higher realized selling prices, lower COGS per unit, a more favorable product mix, or a combination of these factors.

Gross margin can move differently from gross profit. A business may generate more gross-profit dollars while its margin percentage falls if sales grow rapidly at lower-margin prices. Or margin can improve while total gross profit falls if revenue declines sharply.

For useful analysis, compare both the amount and percentage and investigate the underlying drivers. Price changes, discounts, returns, supplier costs, manufacturing efficiency, freight treatment, and product mix can all matter.

There is no universal “good” gross margin. Sustainable levels vary substantially by industry, business model, accounting classification, competitive environment, and stage of growth.

Worked gross-profit examples

Example 1: net sales and COGS

Net sales = 100,000 and COGS = 62,000:

Gross Profit = 100,000 − 62,000 = 38,000
Gross Margin = 38,000 / 100,000 = 38%

Example 2: derive net sales first

Gross sales = 220,000, returns and allowances = 20,000, and COGS = 140,000:

Net Sales = 220,000 − 20,000 = 200,000
Gross Profit = 200,000 − 140,000 = 60,000

The gross margin is 30%.

Example 3: per-unit economics

Net selling price = 45, unit COGS = 27, quantity = 1,000:

Net Sales = 45 × 1,000 = 45,000
COGS = 27 × 1,000 = 27,000
Gross Profit = 18,000

The gross margin is 40%.

Example 4: gross loss

Net sales = 40,000 and COGS = 46,000:

Gross Profit = −6,000
Gross Margin = −15%

Example 5: same margin, different scale

Business A has 10,000 of net sales and 6,000 of COGS; Business B has 1,000,000 of net sales and 600,000 of COGS. Both have a 40% gross margin, but their gross-profit amounts are 4,000 and 400,000 respectively.

Common gross-profit mistakes

Using gross sales when the report requires net sales. Returns, allowances, or discounts may need to be deducted first.

Subtracting all business expenses as COGS. Gross profit is not the same as net profit.

Comparing periods with inconsistent COGS classifications. Reclassification can change gross margin without changing the underlying economics.

Confusing gross margin with markup. Margin divides by sales; markup divides by cost.

Ignoring a zero-sales denominator. Gross margin percentage is undefined when net sales are zero, even though gross profit as an amount can still be calculated.

Using mismatched periods. Sales and COGS should cover the same scope and reporting period.

Assuming a high gross margin guarantees net profitability. Operating and non-operating expenses still matter.

Frequently asked questions

How do I calculate gross profit?

Subtract cost of goods sold from net sales: Gross Profit = Net Sales − COGS.

How do I calculate gross margin?

Divide gross profit by net sales and multiply by 100.

Is gross profit the same as revenue?

No. Revenue or net sales is the top-line sales amount used in the formula. Gross profit is what remains after COGS is deducted.

Is gross profit the same as net profit?

No. Gross profit is before many operating and non-operating expenses that are included later when determining net profit.

Can gross profit be negative?

Yes. If COGS is greater than net sales, the result is a gross loss.

What happens if net sales are zero?

Gross profit can still be computed as net sales minus COGS, but gross margin percentage is undefined because dividing by zero is not valid.

Should returns be deducted before gross profit?

If your revenue definition treats returns and allowances as reductions of sales, deduct them to arrive at net sales before subtracting COGS.

What is a good gross margin?

There is no universal target. Appropriate margins depend on industry, product mix, cost classification, competition, pricing strategy, and business model.

Important note

This calculator applies the standard gross-profit relationship using the sales and COGS figures you provide. It does not determine the accounting classification of a particular expense, tax treatment, inventory method, or reporting policy. For financial statements, tax reporting, or audited figures, use the definitions and accounting rules applicable to your business and jurisdiction.