Skip to content

Personal Finance

How a Retired Couple Can Sell Stock, Buy It Back the Same Day, and Still Pay 0% on the Gain

Digilifetrends Published 4 min read
A man wearing glasses and a blue and white plaid shirt sits at a wooden table, holding and reviewing white papers. A woman in a white hooded sweatshirt stands to his right, leaning over and pointing at a document on the table. A black laptop is closed to their left, and a dark binder with more papers is also on the table. The background is a dimly lit interior of what appears to be a kitchen or dining area.
A couple carefully reviews financial documents, potentially weighing options for funding education costs while navigating complex retirement account rules. Understanding these differences can help avoid unnecessary penalties.

Tax-gain harvesting allows investors in a low-income year to sell appreciated stock, pay 0% on the long-term gain, and then repurchase the shares right away. With that in mind, consider a retired couple living on Social Security and a small IRA withdrawal.

They plan to sell $90,000 worth of a stock that has climbed for decades, realizing a $60,000 long-term gain, and then buy the same shares back later that day. A friend cautions them about the wash sale rule, but the concern is misplaced.

Why the Wash Sale Rule Covers Losses Only

The wash sale rule targets one situation: you cannot claim a deduction for a loss if you buy substantially identical stock within 30 days[1] before or after the sale. A transaction completed at a gain is not covered. The gain is reported, and the repurchased shares receive a fresh cost basis equal to the price paid that day.

When those shares are sold later, the IRS measures the profit from that higher basis. Years of appreciation can be realized at 0%, reducing the next tax bill.

Where the Rule Appears in the Tax Code

The rule appears in 26 U.S.C. § 1091(a)[1], which begins with “In the case of any loss claimed to have been sustained”[1]. The IRS says the same thing in Publication 550 (2025): “A wash sale occurs when you sell or trade stock or securities at a loss”. Both sources tie the rule to losses. The 0% rate comes from 26 U.S.C. § 1(j)(5). Rev. Proc. 2025-32 adjusts the threshold for inflation and sets the 2026 maximum zero-rate amount at $98,900 for married couples filing jointly.

Who Can Use the 0% Rate?

To qualify, shares must be held for more than a year in a regular taxable brokerage account. Total 2026 taxable income, including gains, must stay at or below $98,900 on a joint return. That usually fits early retirees, workers in a gap year between jobs, and retirees who have not begun large IRA withdrawals. High earners do not qualify, and neither do short-term shares or stock held inside an IRA or 401(k).

Using the couple from the headline as an example, their other taxable income would need to be roughly $38,900 or less for the full gain to remain at 0%. Taxable income is what remains after deductions. In 2026, the joint standard deduction is $32,200. Each spouse who is 65 or older or blind adds $1,650.

The One Big Beautiful Bill also created a $6,000 senior deduction for each eligible individual. It applies to tax years beginning after December 31, 2024, and continues through 2028.

How to Capture the Gain Before Year-End

  1. Estimate 2026 taxable income without the sale. Include pensions, IRA withdrawals, interest, and the taxable portion of Social Security, then subtract deductions. Ordinary income fills the lower brackets first, and the gain is added on top.
  2. Determine your remaining room. The gap between that estimate and $98,900 is the starting point. Recalculate taxable Social Security and income-based deductions after adding the gain to see how much still qualifies for 0%.
  3. Tell your broker exactly which long-term lots to sell. Choose the shares with the largest gains.
  4. Sell and repurchase before the year ends. A same-day buyback is allowed.
  5. Review your brokerage’s cost-basis records to make sure the newly bought shares show the higher basis.

Costs That Can Reduce the Tax-Free Gain

State income tax is the first potential cost, because the federal 0% rate stops at the state line, and most states with an income tax treat the gain as taxable income.

Social Security benefits can also become taxable. Under 26 U.S.C. § 86[2], the gain counts toward the income test. For joint filers, benefits begin to be taxed above $32,000, and up to 85%[2] can be taxed above $44,000. Taxable benefits count as ordinary income, which reduces the available 0% room. A gain sized exactly to the dollar can spill partly into the 15% bracket.

Medicare has a built-in lag, since premium surcharges use income from 2 years earlier under 20 CFR 418.1135(a). That means a gain realized in one year can raise insurance premiums two years later. In 2026, the joint Part B surcharge begins above $218,000 of modified adjusted gross income. Unlike the capital gains bracket, Medicare uses income before standard and itemized deductions.

The holding period also resets. The repurchased shares start a new one-year clock. Under 26 U.S.C. § 1223(3)[3], the old holding period carries over only in a wash sale, and a sale at a gain is not one. If the new lot is sold within a year, any profit is short-term.

Finally, there is a 3.8% net investment income tax, but it applies only above $250,000 of joint income, which is far above the 0% bracket.

For households whose income dropped this year, the space under $98,900 can determine how much gain can be realized at 0%. A gain that might be taxed at 15% later can be taken tax-free now.

More from Digilifetrends