Capital gains tax calculator

Enter what you sold for, what it cost you and the tax rate for short or long holding periods. The calculator shows the gain, the tax and what is left. Tax rates and holding-period rules differ by country and change, so you supply the rates.

Both rates are example numbers, not current rates. Replace them with the rates that apply to you.
Estimated tax742.50
Profit after tax4,207.50
Gain (sale − cost − fees)
4,950.00
Taxable gain
4,950.00
Rate used
15%

Runs in your browser: nothing you enter is sent anywhere.

How to use it

  1. Enter the sale price, the cost basis and any selling fees.
  2. Choose short-term or long-term and enter the rates that apply to you.
  3. Add losses you can offset, if any, and read the tax and profit after tax.

How it works

Gain = sale − cost − fees. Taxable gain = max(0, gain − losses). Tax = taxable gain × the rate of the chosen period. Profit after tax = gain − tax. A negative gain shows as a loss, with no tax.

Worked example

Sale 15,000, cost 10,000, fees 50: gain 4,950. Long-term at 15% gives tax of 742.50 and a profit after tax of 4,207.50.

Tips

  • Keep records of the purchase price and costs: the cost basis is the number people most often get wrong.
  • Not every tax system has two rates, and some include other levies; this tool models only a flat rate on the gain.
  • For the total return of an investment, see the percentage calculator.

Frequently asked questions

How is a capital gain calculated?

Sale price minus cost basis minus the costs of selling. Selling for 15,000 an asset that cost 10,000 with 50 in fees gives a gain of 4,950.

What is the difference between short-term and long-term?

Many countries tax gains on assets held for a short time differently from those held longer. In the US the usual dividing line is more than one year. Where you live the rule and the rates may differ, so choose the period and enter the rate that applies to you.

Why are the rates not filled in for me?

Rates, brackets and thresholds change and differ by country, state and income. The values pre-filled here are only examples. Enter your own, and check with the tax authority or an adviser.

How do losses work here?

Losses you enter are subtracted from the gain before the rate is applied, and the taxable gain cannot go below zero. Real rules on using and carrying over losses are more detailed, so treat this as an estimate.

More in Finance

All tools in this category: Finance ·Updated November 3, 2026

Privacy choices

Google Analytics shows us which tools are used and whether they work. It may set cookies. Your choice is kept in this browser.