Capital Gains Tax Calculator

Calculate capital gains tax owed on the profit from selling an asset, using the rate for your asset, income band and holding period.

Updated September 2026
$
$
%
Capital gains tax
75 $

The formula

Capital Gains Tax = (Selling Price − Purchase Price) × (Tax Rate ÷ 100)
# enter the specific rate for the asset, holding period and income band that applies — not a guessed flat percentage

Understanding Capital Gains Tax

Capital gains tax is a levy imposed on the profit earned from the sale of an asset, such as stocks, real estate, or bonds. This tax applies only when the asset is sold for more than its purchase price. The rate of capital gains tax varies depending on the holding period of the asset and the taxpayer's income bracket. Short-term capital gains, from assets held for less than a year, are taxed at ordinary income rates, while long-term gains benefit from lower tax rates. Understanding how to calculate capital gains tax is essential for effective financial planning.

Key points to consider:
  • The difference between the sale price and the purchase price is the capital gain.
  • Deductions, such as transaction costs, can reduce the taxable amount.
  • Tax rates differ for short-term and long-term gains.

How to calculate capital gains tax

Capital gains tax is charged on the profit from selling an asset, not the sale price itself — the taxable gain here is simply what you sold for minus what you paid, and the rate that applies depends on the asset, how long you held it and which country's rules govern the sale.

Rates are rarely a single flat number. The UK charges 18% or 24% depending on whether the gain falls inside or above your basic-rate band for 2026/27, after a £3,000 annual tax-free allowance. The US taxes gains held over a year at 0%, 15% or 20% federal depending on taxable income, and gains held a year or less at ordinary income rates instead — often far higher than either long-term rate.

The calculator asks for:

  • Purchase price ($)
  • Selling price ($)
  • Capital gains tax rate (%) — the rate for this asset, holding period and income band — not a flat guess

Results appear immediately — there is nothing to submit. Changing a field rewrites the link, so you can share the exact scenario you are looking at.

Some of the fields above will accept figures that seem unusual for your own situation, and that is deliberate: the formula behind capital gains tax works the same way regardless of scale, so the calculator does not stop you testing a hypothetical scenario a long way from your actual numbers — often the fastest way to see which input the result is most sensitive to.

Why capital gains tax matters

Most people who look up a capital gains tax calculation already have a specific number in mind — a quote, an offer, a target — and want to check it rather than learn the theory behind it. This page is built for that: enter your own figures, see the result immediately, and change any field to see how the answer moves without redoing the arithmetic from scratch each time.

Beyond a one-off check, the same calculation is worth revisiting whenever the underlying numbers change — a new interest rate, a change in income, a different term. Because the figures live in the page's own web address, coming back to update just one field and compare the new result against the old one takes seconds rather than starting again from a blank page.

It is also worth being clear about what a single figure like this can and cannot settle on its own. It answers the specific question the formula was built to answer, and nothing more — a favourable capital gains tax result does not automatically mean a decision is a good one overall, since plenty of other factors that a formula cannot capture, from personal circumstances to how comfortable a commitment feels, usually matter just as much as the arithmetic. Use the number as one solid input among several rather than the whole of the decision.

Where the same calculation needs to be run for several different scenarios side by side — three loan offers, two savings plans — the fastest approach is usually to open the calculator in a second browser tab for each one, so that the results can be compared directly rather than overwriting each other in a single set of fields.

Capital Gains Tax Example

Capital Gain = Sale Price - Purchase Price - Deductions
Example: $1,500 (Sale) - $1,000 (Purchase) - $50 (Fees) = $450 (Taxable Gain)
If the tax rate is 15%, the tax owed would be:
$450 * 0.15 = $67.50

Worked example

Here is the calculation with the starting values:

  • Purchase price: 1,000 $
  • Selling price: 1,500 $
  • Capital gains tax rate: 15 %

That gives:

  • Capital gains tax: 75 $

These figures are only the calculator's own starting values, included so the working is visible rather than hidden inside the tool above. Replace them with your own numbers and the same arithmetic applies — nothing about the method changes, only the inputs feeding it.

Factors Affecting Capital Gains Tax

Several factors influence the amount of capital gains tax you owe:
  • Holding Period: Assets held for over a year qualify for lower long-term rates.
  • Income Level: Higher earners may face additional taxes, such as the Net Investment Income Tax (NIIT).
  • Type of Asset: Certain assets, like collectibles, have different tax rates.
  • State Taxes: Some states impose their own capital gains taxes.

Reading the result

Enter the actual rate that applies to your specific gain, income band and holding period — not a guessed flat percentage — since the gap between the lowest and highest bracket in either country is large enough to change the answer by thousands on a five-figure gain.

Where this goes wrong. Forgetting the tax-free allowance. The UK's £3,000 annual exempt amount for 2026/27 comes off the gain before any rate is applied, so a $1,500 sale at a $500 profit sitting entirely inside that allowance owes nothing — plugging the full gain into this calculator without subtracting the allowance first overstates the tax owed.

A useful check on any unfamiliar result is to compare it against a rough mental estimate first — round the inputs to convenient numbers and see whether the calculator's answer lands in roughly the same territory. A wildly different figure usually means one of the fields was entered in the wrong unit, most often a percentage typed as a whole number where a decimal was expected, or the reverse.

Short-term capital gains apply to assets held for one year or less and are taxed at ordinary income rates. Long-term capital gains apply to assets held for more than one year and benefit from reduced tax rates, typically 0%, 15%, or 20%, depending on your income.

Yes, certain exemptions exist. For example, the sale of a primary residence may exclude up to $250,000 (or $500,000 for married couples) of capital gains if specific conditions are met. Additionally, gifts or inheritances may qualify for stepped-up cost basis rules.

In the UK, no — Private Residence Relief exempts your only or main home from capital gains tax entirely in almost all cases. In the US, individuals can exclude up to $250,000 of gain ($500,000 married filing jointly) on a primary residence, with only the excess taxed.

Strategies to minimize capital gains tax include:

  • Holding assets for over a year to qualify for long-term rates.
  • Offsetting gains with capital losses (tax-loss harvesting).
  • Investing in tax-advantaged accounts like IRAs or 401(k)s.

In the UK, yes as of 30 October 2024 — shares, funds and residential property gains all use the same 18%/24% rates, where previously property carried higher rates. In the US, the distinction that matters is short-term versus long-term holding period, not asset type: anything held a year or less is taxed as ordinary income regardless of what it is.

No, capital gains tax is only triggered when you sell an asset for a profit. Unrealized gains (increases in value without selling) are not taxable.

It returns capital gains tax. With 1,000 $ purchase price, 1,500 $ selling price and 15 % capital gains tax rate, that comes to 75 $. Change any field and the figure moves with it.

Tax Rate Calculation Example

Taxable Gain: $10,000
Tax Rate: 20% (for high-income earners)
Tax Owed: $10,000 * 0.20 = $2,000

Whenever one of the underlying figures changes — a new interest rate, a different balance, an updated term — since the result only reflects what is currently in the fields. There is no need to keep a separate record of past results; the web address for a filled-in version already carries the figures used to produce it.

State-Specific Capital Gains Taxes

Some states, like California and New York, impose additional taxes on capital gains. These rates vary and can significantly impact your total tax liability. Always check your state's tax laws to ensure accurate calculations.

Not unless a tax rate or a fee is explicitly one of the inputs above. Where it is not, the figure shown is a gross calculation, and any tax due depends on your personal circumstances and current tax rules, which are worth checking separately.

State Tax Example

Federal Tax: $2,000
State Tax (5%): $10,000 * 0.05 = $500
Total Tax: $2,500

The arithmetic itself is exact — the calculator applies the formula shown above precisely, with no rounding until the final figure is displayed. The uncertainty, where it exists, is entirely in the inputs: an estimated rate or an approximate balance carries that same approximation through to the result.

Reporting Capital Gains on Your Tax Return

Capital gains must be reported on Schedule D of your federal tax return. Include details such as the asset's description, purchase and sale dates, and the gain or loss amount. Failure to report accurately can result in penalties.

Common Mistakes When Calculating Capital Gains Tax

Avoid these errors:
  • Forgetting to include transaction fees in the cost basis.
  • Misclassifying short-term gains as long-term.
  • Overlooking state tax obligations.

Cost Basis Adjustment Example

Purchase Price: $5,000
Improvements: $1,000
Adjusted Cost Basis: $5,000 + $1,000 = $6,000
Sale Price: $8,000
Capital Gain: $8,000 - $6,000 = $2,000

Capital Gains Tax Planning Strategies

Effective planning can minimize your tax burden:
  • Time asset sales to optimize tax rates.
  • Use tax-loss harvesting to offset gains.
  • Consider charitable donations of appreciated assets.

Final Thoughts on Capital Gains Tax

Understanding how to calculate capital gains tax is crucial for maximizing your after-tax returns. By leveraging exemptions, deductions, and strategic planning, you can reduce your liability and keep more of your investment profits. Always consult a tax professional for personalized advice.

Was this calculator helpful?

Tap a star to rate it. Your feedback helps us improve the tools people rely on most.