Advertisement

Capital Gains Tax Calculator (2026 Federal)

Estimate 2026 US federal capital gains tax on a sale: 0%, 15% or 20% long-term rates, short-term ordinary rates, the 3.8% NIIT and home-sale exclusion.

How long did you own it?
Wages, interest, business income — not counting this sale.
Leave blank for the 2026 standard deduction ($16,100 single, $32,200 joint, $24,150 head of household).
For a gain, select only if you qualify for the full exclusion: ownership/use tests, joint-filer conditions and no other exclusion within two years. Partial exclusions and nonqualified use are not modelled.

Selling shares, a fund, crypto or property for more than you paid creates a capital gain. Held more than a year, it is taxed at 0%, 15% or 20% depending on your total taxable income; held a year or less, it is taxed like wages. This calculator stacks the gain on your other income using the 2026 IRS thresholds and adds the 3.8% net investment income tax when it applies.

How to use this tool

  1. Enter your cost basis (price paid plus fees) and the sale price after selling costs.
  2. Choose how long you owned the asset.
  3. Pick your filing status and enter your other income for the year.
  4. Leave deductions blank to use the 2026 standard deduction, or enter your itemized total.
  5. Tick the home box if it was your main home (two-of-five-years rule).

Formula

Tax on the sale = tax(other income + gain − deductions) − tax(other income − deductions) + NIIT

Long-term gains sit on top of ordinary taxable income. For 2026 the 0% rate covers taxable income up to $49,450 (single or separate), $98,900 (joint) or $66,200 (head of household); 15% applies up to $545,500, $613,700, $306,850 (separate) and $579,600 respectively; 20% above that.

NIIT = 3.8% × the smaller of the gain and modified AGI above $200,000 (single or head of household), $250,000 (joint) or $125,000 (separate).

Example

A single filer earning $60,000 sells shares bought for $20,000 for $30,000 after two years. Taxable income without the sale is $60,000 − $16,100 = $43,900. The $10,000 gain first fills the rest of the 0% band ($49,450 − $43,900 = $5,550 at 0%); the remaining $4,450 is taxed at 15%: $667.50, an effective 6.68% on the gain. Sold within a year, the same gain would cost $1,550 at ordinary rates.

Frequently asked questions

What counts as long-term?

An asset you held for more than one year before selling. Anything held one year or less is short-term and taxed at your ordinary income rates.

Do I pay tax when I sell my house?

Not on the first $250,000 of gain ($500,000 for most married couples filing jointly) if you owned it and lived in it as your main home for at least two of the five years before the sale. The excluded part is not subject to the NIIT either.

What if I sold at a loss?

Losses offset gains first. Up to $3,000 of net loss ($1,500 filing separately) can reduce other income. Unused losses carry forward, including any deduction not absorbed at low income. This tool assumes no other capital transactions. Personal-home losses are not deductible.

Does a 0% gain still count as income?

Yes. It raises your adjusted gross income, which can affect credits and how much of your Social Security is taxable.

Sources

This tool gives an estimate for general information only. It is not financial, tax, legal or medical advice — check with a qualified professional before you rely on the result.

Last updated: 2026

Advertisement