Skip to content
Year-End Moves

Capital Gains Tax Calculator (2026)

Enter your other taxable income and your realized gains. See which rate each dollar of gain falls into, the 3.8% surtax, and how much more you could sell at a 0% federal rate.

Estimate only. Federal income tax for 2026, using the IRS rate tables. Excludes state tax, the alternative minimum tax, collectibles and unrecaptured section 1250 gain (taxed up to 25%), and qualified small business stock. Enter taxable income after the standard or itemized deduction.

How capital gains are taxed

When you sell an investment for more than you paid, the profit is a capital gain. If you held the asset for one year or less, it is a short-term gain, and it is added to your other income and taxed at your ordinary rate of 10% to 37%. If you held it for more than one year, it is a long-term gain, which gets lower rates of 0%, 15% or 20% depending on your total taxable income. This calculator applies those rules for the 2026 tax year using the figures in IRS Revenue Procedure 2025-32.

The 2026 long-term thresholds

Taxable income at which long-term gain rates change, 2026
Filing status0% up to15% up to20% above
Single$49,450$545,500$545,500
Married filing jointly$98,900$613,700$613,700
Head of household$66,200$579,600$579,600
Married filing separately$49,450$306,850$306,850

The thresholds apply to taxable income, which is income after deductions. Gains are “stacked” on top of your ordinary income: your ordinary income fills the lowest brackets first, and the gain sits above it. A single filer with $40,000 of other taxable income and a $30,000 long-term gain has $9,450 of gain below the $49,450 line, taxed at 0%, and $20,550 above it, taxed at 15%. The federal tax on the gain is $3,082.50, a blended 10.3%. The calculator performs exactly this stacking, including when your income is high enough that part of the gain lands in the 20% range.

The 3.8% net investment income tax

Higher earners may also owe the net investment income tax (NIIT), a 3.8% surtax on the smaller of your net investment income or the amount your modified adjusted gross income exceeds $200,000 (single or head of household), $250,000 (married filing jointly) or $125,000 (married filing separately). Those thresholds are set in the statute and are not adjusted for inflation. Net investment income includes capital gains, interest, dividends and rental income, but not wages. Enter your adjusted gross income before the gains, or leave it blank to let the tool estimate it from your taxable income and the standard deduction, and add other interest and dividends in the last field. Example: a married couple with $250,000 of other taxable income (about $282,200 AGI) and a $100,000 long-term gain pays $15,000 at 15% plus $3,800 of NIIT, a blended 18.8%.

Losses, netting and carryovers

Gains and losses are netted before tax. Short-term results are netted with short-term, long-term with long-term, and then a net loss in one group offsets a net gain in the other. If the whole year is a net loss, you can deduct up to $3,000 against other income ($1,500 if married filing separately) and carry the rest forward indefinitely. Enter losses as negative numbers. The tool shows the deduction and carryforward when your result is a loss.

Using the 0% room figure

The last line shows how much more long-term gain you could realize this year and still be in the 0% bracket. People with low taxable income, such as early retirees living off savings, can sell appreciated investments up to that line and immediately repurchase them, resetting their cost basis higher without paying federal tax. This is sometimes called gain harvesting. Remember that the extra income can reduce ACA premium tax credits, raise taxes on Social Security benefits and affect state taxes, so check those effects before selling. Our guide to capital gains tax rates goes through the rules in more depth.

What this calculator leaves out

  • State taxes. Most states tax gains as ordinary income; a few have no income tax at all.
  • Collectibles and real estate depreciation. Gains on collectibles are taxed up to 28%, and unrecaptured section 1250 gain on depreciated real estate up to 25%.
  • Home sale exclusion. Up to $250,000 ($500,000 joint) of gain on a main home may be excluded entirely.
  • Qualified dividends. They are taxed at the same 0/15/20 rates; add them to your long-term gain figure for a rough result.

Frequently asked questions

Do I owe capital gains tax if I reinvest the money?

Yes. A sale is taxable in the year you sell, whether or not you buy something else. The exceptions are specific provisions such as the home sale exclusion, like-kind exchanges of real property and sales inside retirement accounts.

What is the holding period for long-term treatment?

More than one year. The day after you acquire the asset is day one, and you must hold it past the one-year anniversary. Selling a day early makes the gain short-term.

Why does the tool ask for taxable income instead of salary?

The 0%, 15% and 20% thresholds are measured against taxable income, after the standard or itemized deduction. If you only know your salary, subtract the standard deduction ($16,100 single, $32,200 joint in 2026) and any pre-tax contributions to estimate it.

Are cryptocurrency gains taxed the same way?

Digital assets are treated as property, so gains follow the same short-term and long-term rules. Check IRS guidance on digital assets for reporting requirements.

Sources and further reading

Rate thresholds, brackets and the standard deduction are the 2026 figures in Rev. Proc. 2025-32. The NIIT thresholds are fixed by statute.