Skip to content
Omnikalc

Gain harvesting calculator: how many gains can you realize at a 0 % tax rate?

Enter your taxable income, the top of the 0 % bracket and the gains you want to realize to see the room, the tax avoided and the gains above it.

Updated on
Your inputs
$

Value out of range

$

Value out of range

$

Value out of range

%

Value out of range

Results

Room left in the 0 % bracket

$36,700

Gains realized at a 0 % federal rate

$30,000

Tax avoided compared with selling later

$4,500

Harvesting saves tax Realizing these gains now costs no federal tax and raises your basis for the future.
Gains above the 0 % bracket
$0
Tax on those gains at your later rate
$0
Basis gained on the shares you sold and rebought
$30,000

Long-term capital gains are taxed at 0 % up to a certain level of taxable income. This level is high enough that many retirees and families can realize gains at no federal tax. Gain harvesting means selling an appreciated asset that you have held more than a year while you are in the 0 % bracket, and then, if you wish, buying it back at once. The cost basis goes up to the new price, so you will owe less tax when you sell for good. This calculator shows the room, the gains you can realize at 0 %, and the tax avoided.

How the calculation works

  • Room in the 0 % bracket = top of the bracket − your taxable income
  • Gains realized at 0 % = the smaller of your planned gains and the room
  • Tax avoided = gains realized at 0 % × the rate you would pay later
  • Gains above the bracket = planned gains − gains realized at 0 %, taxed at the higher rate
  • Gains are added on top of your ordinary taxable income, which is why income decides the room

Example

Your taxable income is $60,000 and the 0 % bracket ends at $96,700, so you have $36,700 of room. You want to realize $30,000 of gains: all of it fits, so $30,000 is taxed at 0 %. If you waited and paid 15 % later, you would pay $4,500. Had you wanted to realize more than the room, the $0 above it would be taxed at 15 %, or $0.

Why it matters

This is a legal way to reset your basis for free. It is especially useful in years of low income, such as early retirement before Social Security and required distributions, or a year with a career break. Unlike a loss harvest, there is no wash sale rule for gains, so you can rebuy the same shares the same day.

Good to know

The extra income can reduce tax credits and deductions and increase the taxable part of Social Security benefits, ACA subsidies or Medicare premiums, so the true cost can be above 0 %. State taxes may still apply. Part of your gain can fall into the 15 % bracket if you cross the limit. The bracket amounts are indexed each year and depend on your filing status. Mutual funds may distribute gains you do not control.

In practice

Run your tax software with the gains added and check for effects on credits and premiums before selling. This tool is educational and is not tax advice.

Frequently asked questions

What is capital gain harvesting?

It is selling appreciated assets in a year when your income is low enough that the gain is taxed at 0 %, to raise the cost basis for later.

Is there a wash sale rule for gains?

No. The wash sale rule only applies to losses, so you can buy back the same asset right away after realizing a gain.

Can gains push me out of the 0 % bracket?

Yes. Gains stack on top of your ordinary income, so the part above the top of the bracket is taxed at 15 % or more.

What else can harvesting affect?

Higher income can reduce credits, raise the taxable share of Social Security and increase ACA or Medicare premiums.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.