Capital Gains Tax and Retirement Planning (2026)
During your working years, capital gains tax is mostly a nuisance you deal with when you sell something. In retirement it becomes a central planning variable. You control almost every dollar of income you report — which account you draw from, when you sell, how much gain you realize — and that control is exactly what makes the difference between paying 0% and paying 23.8% on the same portfolio.
The core insight is that retirement gives most people a window of unusually low taxable income, usually between the last paycheck and the first required minimum distribution. Inside that window, long-term gains can often be realized entirely tax-free. Outside it, the same gains can drag Social Security into taxation, raise Medicare premiums, and stack on top of RMDs at the worst possible rate. This guide walks through how each of those pieces interacts, with worked numbers you can reproduce in our capital gains tax calculator.
Where Capital Gains Tax Applies in Retirement (and Where It Doesn't)
Before optimizing anything, be clear about which accounts even generate capital gains. This is the single most common source of confusion among retirees.
| Account type | Tax on growth | Tax when you withdraw |
|---|---|---|
| Taxable brokerage | Dividends & realized gains taxed yearly | Long-term gains at 0%/15%/20% on the gain only |
| Traditional IRA / 401(k) | Deferred, untaxed inside the account | Ordinary income on the full withdrawal — never capital gains rates |
| Roth IRA / Roth 401(k) | Tax-free | Tax-free if age 59½+ and the 5-year rule is met |
| HSA | Tax-free | Tax-free for qualified medical expenses; ordinary income otherwise |
| Inherited taxable assets | Basis stepped up at death | Gain measured from the date-of-death value |
Two consequences follow. First, a stock that tripled inside a traditional IRA gets no capital gains treatment at all — every dollar you pull out is ordinary income. Second, only your taxable brokerage account gives you the ability to choose how much income to recognize in a given year, because you decide when and which lots to sell. That flexibility is the raw material for every strategy below.
The 2026 Long-Term Capital Gains Brackets Retirees Should Memorize
Long-term gains (assets held more than one year) sit in their own rate schedule, driven by total taxable income — ordinary income first, then gains stacked on top. For 2026, per IRS Rev. Proc. 2025-32:
| Rate | Single | Married Filing Jointly | Head of Household |
|---|---|---|---|
| 0% | Up to $49,450 | Up to $98,900 | Up to $66,200 |
| 15% | $49,451 – $545,500 | $98,901 – $613,700 | $66,201 – $579,600 |
| 20% | Over $545,500 | Over $613,700 | Over $579,600 |
Layered on top is the 3.8% Net Investment Income Tax, which applies once modified AGI exceeds $200,000 (single) or $250,000 (joint). Those thresholds have never been indexed for inflation, so more retirees with large one-time sales cross them each year. Short-term gains — rare but not unheard of for retirees rebalancing recent purchases — are taxed at ordinary rates; see our short-term capital gains guide.
Crucially, the bracket thresholds are measured against taxable income after deductions. A married couple both over 65 in 2026 takes a $30,000 standard deduction plus $1,600 each for age, and under current law a temporary additional senior deduction of up to $6,000 per person applies through 2028 (phasing out as income rises). That means gross income can exceed $130,000 while taxable income still lands inside the 0% capital gains bracket.
0% Bracket Planning: The Retiree's Best Tax Break
Gain harvesting is the deliberate act of selling appreciated positions specifically to fill unused 0% bracket space, then immediately buying the same investment back. Unlike loss harvesting, the wash-sale rule does not apply to gains — you can repurchase the identical security the same afternoon. The result is a permanently higher cost basis at zero federal tax cost.
The three-step calculation
- Project your ordinary taxable income for the year: pensions, annuity payments, taxable Social Security, interest, and any traditional IRA withdrawals, minus your standard or itemized deduction.
- Subtract that figure from the top of the 0% bracket ($49,450 single / $98,900 joint). The remainder is your harvest room.
- Sell high-basis-shortfall lots — the ones with the largest gain per dollar of proceeds — until you have realized that amount of long-term gain. Reinvest immediately.
Two cautions keep this from being free money. Realized gains raise AGI, which can reduce Affordable Care Act premium subsidies for retirees under 65 — often the binding constraint for people retiring at 60. And harvesting uses up bracket space that a Roth conversion could have used instead, which is the trade-off in the next section.
Roth Conversions vs Gain Harvesting: You Usually Can't Do Both
A Roth conversion moves money from a traditional IRA to a Roth IRA and reports the converted amount as ordinary income. Because ordinary income is stacked underneath capital gains, every dollar converted displaces a dollar of 0% capital gains room. The two strategies compete for the same scarce resource: the space between your income and the top of a low bracket.
| Situation | Usually favors | Why |
|---|---|---|
| Large pre-tax IRA, modest taxable account | Roth conversion | Future RMDs would land in the 22–24% bracket or higher; converting at 10–12% is a clear arbitrage |
| Large low-basis taxable account, small IRA | Gain harvesting | RMDs will be small; the real risk is a forced high-rate sale later |
| Heirs in high tax brackets | Roth conversion | Roth assets pass tax-free; the 10-year inherited IRA rule makes pre-tax balances expensive to inherit |
| Heirs will inherit soon | Neither — hold | Stepped-up basis at death eliminates the embedded gain entirely |
| Charitable intent after 70½ | Qualified charitable distributions | QCDs satisfy RMDs without adding income, preserving 0% gain space |
A practical compromise many retirees use: convert in the first few low-income years to defuse the pre-tax balance, then switch to gain harvesting once projected RMDs look manageable. Whichever you choose, decide before December and confirm the numbers — a conversion cannot be undone, since recharacterization of conversions was eliminated in 2018.
Required Minimum Distributions and the Shrinking 0% Window
RMDs begin at age 73 for most current retirees (age 75 for those born in 1960 or later, under SECURE 2.0). They are always ordinary income — never capital gains — and they are not optional, with a penalty of 25% of the shortfall, reduced to 10% if corrected promptly.
The planning problem is displacement. An RMD fills your low brackets from the bottom, so it pushes your capital gains upward into the 15% or 20% band. A retiree who could realize $60,000 of tax-free gains at 68 may have zero 0% room at 75.
| Age | Pre-tax balance | IRS divisor | RMD | Approx. 0% gain room left (joint) |
|---|---|---|---|---|
| 72 | $1,200,000 | — | $0 | ~$65,000 |
| 73 | $1,240,000 | 26.5 | $46,800 | ~$18,000 |
| 78 | $1,300,000 | 22.0 | $59,100 | $0 |
| 85 | $1,250,000 | 16.0 | $78,100 | $0 |
Divisors come from the IRS Uniform Lifetime Table; balances are illustrative and assume modest growth net of withdrawals. The pattern is what matters: RMDs rise as a percentage of the account every year, so the window closes progressively rather than all at once.
How Capital Gains Interact With Social Security: the Tax Torpedo
Social Security is taxed based on provisional income: AGI excluding benefits, plus tax-exempt interest, plus one-half of your benefits. Capital gains are fully counted in that figure — including gains taxed at 0%.
| Provisional income (single) | Provisional income (joint) | Share of benefits taxable |
|---|---|---|
| Under $25,000 | Under $32,000 | 0% |
| $25,000 – $34,000 | $32,000 – $44,000 | Up to 50% |
| Over $34,000 | Over $44,000 | Up to 85% |
These thresholds were set in 1983 and 1993 and have never been indexed, which is why they now catch middle-income retirees routinely. The consequence for gain planning is counterintuitive: inside the phase-in range, realizing $1,000 of long-term gain can make an additional $850 of Social Security benefits taxable. That $850 is ordinary income, so a gain nominally taxed at 0% can still generate real tax.
Practical responses: realize large gains before claiming Social Security if possible, spread gains across years to stay below the 85% ceiling, or push a large sale into a year when you already hit the 85% cap (once fully capped, additional gains no longer drag benefits into taxation). Muni bond interest does not help here — it is added back into provisional income.
Medicare IRMAA: the second surcharge
A one-time large gain also affects Medicare. Part B and D surcharges (IRMAA) are based on MAGI from two years earlier, and the first tier begins near $109,000 for single filers and $218,000 for joint filers in 2026. Crossing a tier by a single dollar raises premiums for the whole year, so a $500,000 home or business sale at 68 can add well over $1,000 per person in premiums at 70. IRMAA is a cliff, not a phase-in — worth modeling before you sell.
Timing and Sequencing Strategies for Retirees
1. Map the low-income window explicitly
Draw a timeline from your retirement date to your RMD start age. Each year in that window has a bracket capacity. Filling it deliberately — with conversions, harvested gains, or both — converts a temporary opportunity into permanent tax savings. Doing nothing leaves the capacity unused forever.
2. Delay Social Security to widen the window
Claiming at 70 instead of 62 raises the benefit permanently and keeps provisional income near zero during the intervening years, which is precisely when gain harvesting and conversions are cheapest. The tax benefit is a genuine secondary argument for delayed claiming, on top of the higher benefit itself.
3. Use specific lot identification
Instruct your broker to use specific lot rather than average cost or FIFO. Selling the highest-basis shares first minimizes gain when you need cash; selling the lowest-basis shares first maximizes basis reset when you are deliberately harvesting at 0%. The same trade can produce wildly different taxable amounts depending on lot selection.
4. Pair harvesting with loss harvesting
Realized losses offset realized gains dollar for dollar, and up to $3,000 of net loss reduces ordinary income each year with the remainder carrying forward indefinitely. A retiree with a $40,000 loss carryforward can effectively sell $40,000 of gains with no tax regardless of bracket. Track carryforwards on Schedule D year to year — they are frequently forgotten.
5. Give appreciated shares instead of cash
Donating long-held appreciated stock directly to a charity or donor-advised fund avoids the gain entirely and yields a deduction at fair market value, subject to AGI limits. For retirees who itemize, this is more efficient than selling and donating proceeds. After 70½, compare against a QCD, which helps even for non-itemizers.
6. Consider holding the most appreciated assets for life
Assets held at death receive a stepped-up basis, erasing the unrealized gain for heirs. If you have enough other resources, the lowest-basis positions are often the ones to keep — spend the high-basis holdings and the IRA instead. This interacts with estate planning, so coordinate with your advisor.
7. Watch state taxes and residency
Most states tax capital gains as ordinary income with no preferential rate, and a handful have no income tax at all. Retirees relocating in retirement should time large sales relative to the residency change carefully; states can assert taxing rights over gains with in-state source or over incomplete moves. Compare your options with our state capital gains tax rates.
Five Costly Mistakes Retirees Make
- Selling everything in one year. Liquidating a concentrated position or rental property in a single tax year can push a lifetime of gain into the 20% bracket plus 3.8% NIIT. Spreading the sale, or using an installment sale, often cuts the bill materially. See our real estate capital gains guide.
- Assuming IRA money gets capital gains rates. It never does. Retirees who mentally price their IRA at 15% are understating their future tax by roughly half.
- Ignoring mutual fund distributions. Funds in taxable accounts distribute capital gains in December whether or not you sold anything. These count toward your bracket and can silently consume harvest room. Check estimated distributions in November.
- Forgetting the Social Security interaction. The 0% rate on paper is not 0% in practice when benefits are in the phase-in range.
- Waiting until December 31. Provisional income, IRMAA tiers, ACA subsidies, and bracket capacity all require estimates you can only act on before year end. Late December is too late to fix a January sale.
A Year-by-Year Planning Checklist
- January: estimate the year's ordinary income and identify bracket capacity.
- Spring: review lot-level unrealized gains and any loss carryforwards from last year's Schedule D.
- Mid-year: decide the conversion-versus-harvest split; execute in tranches rather than all at once.
- November: check fund distribution estimates, recompute provisional income, and verify you are not about to cross an IRMAA or NIIT threshold.
- December: complete conversions (hard deadline of December 31), harvest remaining 0% room, and take RMDs or QCDs.
- Ongoing: refresh projections after any large life event — a home sale, an inheritance, a spouse's death that changes filing status from joint to single.
That last point deserves emphasis. When one spouse dies, the survivor typically files jointly for that year and then as a single filer, cutting the 0% capital gains ceiling from $98,900 to $49,450 and the NIIT threshold from $250,000 to $200,000. Gains that were free become taxable at the same income level. Couples with large taxable accounts should consider accelerating some harvesting while both are alive, and should confirm how much basis step-up applies — 50% in most states, 100% in community property states.
Frequently Asked Questions
Do retirees pay capital gains tax on investments they sell?
Only on taxable brokerage holdings, and only on the gain above basis. Traditional IRA and 401(k) withdrawals are ordinary income no matter how the money grew, and qualified Roth withdrawals are tax-free. Many retirees pay 0% on long-term gains, since the 2026 0% bracket runs to $49,450 of taxable income for single filers and $98,900 for joint filers.
Should I do a Roth conversion or harvest capital gains at 0%?
Rarely both in the same year, because a conversion is ordinary income that consumes the same bracket space. Favor conversions when your pre-tax balance is large enough that future RMDs would land in a higher bracket, or when heirs would inherit pre-tax money. Favor harvesting when your taxable account holds most of the embedded gain and projected RMDs are modest.
Do capital gains make my Social Security benefits taxable?
Yes. Gains count in provisional income, so realizing a gain can make up to 85 cents of each additional benefit dollar taxable. This tax torpedo means a gain taxed at 0% can still raise your total bill, with effective marginal rates sometimes exceeding 20%. Realizing large gains before claiming benefits avoids the problem entirely.
Are required minimum distributions taxed as capital gains?
No — RMDs are always ordinary income. Their relevance to capital gains is indirect but significant: because ordinary income stacks beneath gains, RMDs consume your low brackets and push realized gains from 0% into 15% or 20%. Qualified charitable distributions are the main tool for satisfying an RMD without adding income.
What is the best withdrawal order to minimize capital gains tax?
A common default is taxable cash and dividends first, then long-term gains harvested up to the 0% ceiling, then traditional IRA withdrawals or Roth conversions to fill remaining low-bracket space, with Roth spent last. Highly appreciated positions are often held until death so heirs receive a stepped-up basis. Adjust for ACA subsidies before 65 and Medicare IRMAA tiers afterward.
Figures reflect IRS Rev. Proc. 2025-32 inflation adjustments for tax year 2026 and SECURE 2.0 distribution rules. Thresholds for Medicare IRMAA and senior deductions are subject to annual updates and legislative change. This guide is educational and not individualized tax advice; consult a CPA or CFP before executing conversions or large sales.