Formulas and sources
Each formula this calculator uses, where it comes from, and what it leaves out. "How it works" shows the same formula with your own numbers.
Markup and margin from cost and price
Cost+Markup, Price+Margin and Cost+Price modes
- Markup %
- the profit as a share of the cost
- Margin %
- the profit as a share of the selling price (the gross margin)
- P
- the selling price
- C
- the cost
Cost+Markup finds the price as P = C × (1 + Markup % ÷ 100), and Price+Margin finds the cost as C = P × (1 − Margin % ÷ 100). A price below the cost gives a negative markup and margin.
Source: Uses OpenStax's markup percentage and gross margin formulas (Gomez Albrecht and colleagues, 2023) [1], applied to one product; its purchase price is the cost here.
Markup to margin
Markup → Margin mode
- Margin %
- the margin that markup gives
- Markup %
- the markup you enter
The cost and price shown beside it are an illustration on a cost of 100. A markup of -100% or less has no margin.
Source: Standard formula; no single publisher. It follows from the OpenStax definitions [1].
Margin to markup
Margin → Markup mode
- Markup %
- the markup that margin needs
- Margin %
- the margin you enter
A margin of 100% or more has no markup: no cost is low enough.
Source: Standard formula; no single publisher. It follows from the same two OpenStax definitions [1].
Fees, net profit and net margin
Cost+Markup, Price+Margin and Cost+Price modes, with E-commerce Fee Deduction on
- Fees
- the selling fees on one sale
- P
- the selling price
- Fee %
- the fee, as a share of the selling price
- Fixed Fee
- any flat fee per order
- C
- the cost
You enter both fees; the tool knows no marketplace's or payment processor's rates. In Conversion, the fees are worked on the example sale the conversion is shown on, not on a price of yours.
Source: CalcTrail's own model of selling fees; no publisher. For comparison, reported net margins of US public companies: NYU Stern, January 2026 [2].
Sources
- Gomez Albrecht M, Green M, Hoffman L. Principles of Marketing, section 18.3 "Retailing Strategy Decisions", "Markup" and "Gross Margin". OpenStax, Rice University, 2023 (web edition read October 5, 2026).
- Damodaran A. Margins by Sector (US), columns "Gross Margin" and "Net Margin". NYU Stern School of Business, Data as of January 2026; the page is replaced each January.
What this calculator does not cover
- It works on one product's cost and price. A business's reported gross margin uses its total net sales and cost of goods sold, as OpenStax's worked example does.
- It does not count volume discounts, a blend of margins across products, or fixed overhead. The Break-Even Calculator adds fixed costs and sales volume.
Sources checked on .