Margin & Markup Calculator (Cost ↔ Price)

Set a selling price from target gross margin, or reverse gross margin and markup from your current price. Extra costs, payment fees, ending optimization, and batch calculation are all handled in one page.

Instant calculation Runs in your browser Suggests price endings Batch CSV/TSV support

Calculations run in your browser and are not sent to the server.

What This Page Is For

Primary use case 1

Set a price from cost

Enter cost, extra costs, and a target margin to see the theoretical price and practical ending options side by side.

Primary use case 2

Check whether the current price makes sense

Reverse gross profit, gross margin, and markup from a selling price, then compare the result with your target.

Primary use case 3

Recalculate many products at once

Paste CSV or TSV data, review the preview, and export the result as CSV or TSV for spreadsheets.

How to Use It

  1. Choose one of the three modes: cost to price, price to margin, or batch calculation.
  2. Enter the cost, price, target margin, and extra costs that apply to your case.
  3. Adjust payment fees and decimal display in Advanced options if needed.
  4. Use the result summary, breakdown, formulas, and suggested endings to make a pricing decision immediately.

Sample Cases

Set a recommended price from cost

Example input: cost 1,200 / extra cost 230 / target margin 40%

Example output: theoretical price, gross profit, gross margin, markup, and ending suggestions such as 980, 990, and 999

Evaluate the current price

Example input: cost 600 / extra cost 50 / price 990

Example output: gross profit, gross margin, markup, and the gap from the target margin

Understand It Quickly

Gross margin

Gross margin shows how much gross profit remains relative to the selling price. Use it when you want to judge price quality from the selling-price side.

Gross margin = (price - cost - extra costs - price-based fee) / price

Markup

Markup shows how much profit is added relative to cost and fixed extra costs. Use it when you want to think from the cost base.

Markup = gross profit / (cost + extra costs + payment fixed fee)

Cost to price formula

When you derive a price from a target margin, extra costs and payment fees need to be included in the same equation. In practice, this difference directly affects the final selling price.

Recommended price = (cost + extra costs + payment fixed fee) / (1 - payment fee rate - target margin)

Glossary

Gross margin

The share of gross profit relative to the selling price. It tells you how much room remains after direct costs.

Markup

The share of gross profit relative to cost and fixed extra costs. It shows how much you added on top of the cost base.

Extra cost

Fixed per-sale costs such as packaging, shipping, and flat transaction fees.

Formulas

  • Gross profit = price - (cost + extra costs + payment fixed fee + price-based fee)
  • Gross margin = gross profit / price
  • Markup = gross profit / (cost + extra costs + payment fixed fee)
  • Recommended price = (cost + extra costs + payment fixed fee) / (1 - payment fee rate - target margin)

FAQ

How do I include fees?

Use the extra cost field for fixed costs, and enter percentage-based payment fees in Advanced options. You can also add a fixed payment fee separately.

Can I calculate a selling price from target margin?

Yes. In the Cost to Price tab, enter cost and target margin to get the theoretical selling price plus practical ending suggestions.

What about multiple products?

Paste CSV or TSV data into the Batch tab to calculate gross margin, markup, and recommended price for many products at once. Export the result as CSV or copy it as TSV.

Notes

  • This tool is based on gross profit calculations. It may differ from accounting profit that includes SG&A, labor, advertising, taxes, and other overhead.
  • Check your own rules for tax-inclusive pricing, VAT or sales tax, import duties, local pricing norms, and psychological pricing practices.
  • For a real pricing decision, also review competitive conditions, return policies, campaign mechanics, and payment terms.