Our partnerSkilling
  • Spreads from 0.1 pips
  • 1,000+ instruments
  • Free demo account

65% of retail investor accounts lose money when trading CFDs with this provider.

SkillingOpen account
Tool

Capital gains tax calculator

Estimate the federal tax when you sell stocks, ETFs or crypto – long-term or short-term, with the 2026 and 2027 tax brackets.

Updated Fact-checked
$
$
$
Federal tax on the gain–

Federal tax only, based on the IRS brackets for 2026 and 2027 (checked 2 December 2026). The 3.8% net investment income tax is estimated using your taxable income in place of modified AGI. State tax comes on top in most states. Not tax advice.

How capital gains are taxed in the US

When you sell a stock, ETF or crypto for more than you paid, the profit is a capital gain. How it is taxed depends on how long you held it:

  • Long-term (held more than one year): 0%, 15% or 20%, depending on your taxable income.
  • Short-term (one year or less): taxed as ordinary income, at your normal bracket of 10% to 37%.

The gain is stacked on top of your other income. That is why the calculator asks for your other taxable income: part of a gain can fall in the 0% band and the rest in the 15% band.

Long-term capital gains rates 2026 and 2027

RateSingle 2026Joint 2026Single 2027Joint 2027
0%up to $49,450up to $98,900up to $51,050up to $102,100
15%to $545,500to $613,700to $563,200to $633,600
20%above $545,500above $613,700above $563,200above $633,600

The thresholds are taxable income, including the gain. Head of household: 0% up to $66,200 in 2026 and $68,350 in 2027; 20% above $579,600 and $598,400.

The 3.8% net investment income tax

If your modified AGI is above $200,000 (single) or $250,000 (married filing jointly), an extra 3.8% applies to the smaller of your investment income and the amount above the threshold. These thresholds are not adjusted for inflation, so more people pay it every year.

Ways to pay less

  • Hold for more than a year. Turning a short-term gain into a long-term one can cut the rate from 24% or 32% to 15%.
  • Harvest losses. Losses offset gains, and up to $3,000 of net losses a year can offset ordinary income. Watch the wash sale rule if you buy back within 30 days.
  • Use tax-advantaged accounts. Gains inside a Roth IRA or 401(k) are not taxed when you sell.
  • Use low-income years. In a year with little other income, gains may fall in the 0% band.

Active traders, futures and options have their own rules – see US trader taxes.

Questions and answers

What is the capital gains tax rate for 2026?

Long-term gains are taxed at 0%, 15% or 20% depending on taxable income; for a single filer the 0% rate applies up to $49,450 and 20% above $545,500. Short-term gains are taxed as ordinary income.

How do I calculate capital gains tax?

Subtract your cost basis from the sale amount to get the gain. Add it on top of your other taxable income and apply the long-term or short-term rates to the part of the gain that falls in each band.

Do I pay capital gains tax if I reinvest?

Yes. Selling and buying something else in a taxable account is still a sale. Only trades inside retirement accounts like an IRA or 401(k) are tax-free.

What is the 0% capital gains rate?

If your taxable income including the gain stays under $49,450 (single) or $98,900 (joint) in 2026, long-term gains in that band are taxed at 0%.

Is crypto taxed as capital gains?

Yes. The IRS treats crypto as property, so selling, swapping or spending it is a taxable sale with the same short- and long-term rules as stocks.

Our partnerSkilling

A Scandinavian broker with low spreads and the platforms you already know – Skilling Trader, cTrader, MetaTrader and TradingView.

  • Spreads from 0.1 pips1,000+ instruments
  • Four platformsSkilling Trader, cTrader, MetaTrader, TradingView
  • Lloyd's account insuranceUp to €1 million per account
  • Free demo accountPractise with real prices, no risk
The Skilling app on a phone

65% of retail investor accounts lose money when trading CFDs with this provider.