Tax-Loss Harvesting Wash Sale Rule 2026: How to Offset Capital Gains Without Tripping the IRS
A 2026 guide to tax-loss harvesting and the IRS wash sale rule — the 30-day window, the substantially identical test, and how to offset up to $3,000 of income.
Your brokerage statement shows a $14,200 unrealized loss on a tech ETF that’s been underwater for 18 months, right next to a $22,000 gain on an S&P 500 fund you’ve been meaning to rebalance out of. You already know selling the loser to offset the winner is called tax-loss harvesting. You also vaguely remember something about a “30-day rule” that can erase the deduction if you buy the same thing back. In 2026, that rule — the IRS wash sale rule — is where most DIY investors quietly trip themselves.
This piece walks through how tax-loss harvesting actually works in 2026, the exact mechanics of the wash sale rule, the “substantially identical” trap that catches ETF swappers, and the three action patterns that harvest losses cleanly.
What’s Happening: The 2026 Tax Framework
Tax-loss harvesting sells a security at a loss to offset capital gains elsewhere in the portfolio — and, if losses exceed gains, up to $3,000 per year of ordinary income (the ordinary-income offset has been $3,000 since 1978 and remains there in 2026). Unused losses carry forward indefinitely.
The core mechanic:
- Sell a security at a loss.
- Use the loss to offset short-term gains first, then long-term gains, in that order.
- Remaining losses offset up to $3,000 of ordinary income.
- Anything above that carries forward to future tax years.
The IRS wash sale rule gates this: if you buy the same or a “substantially identical” security within 30 days before or after the loss sale, the loss is disallowed and instead added to the cost basis of the replacement. You don’t lose the deduction permanently — you just defer it — but the timing hit matters.
Deep Dive: The Rules That Actually Matter
The 61-Day Wash Sale Window
The 30-day rule is a misnomer. The actual window is 30 days before + the sale date + 30 days after = 61 days during which you cannot hold the same or substantially identical security in any of your or your spouse’s accounts — including IRAs.
That last piece is the single most-missed rule. If you sell a losing position in your taxable brokerage and buy the same ETF in your IRA within the window, the wash sale triggers and — because it’s in the IRA — the basis adjustment has no tax benefit. You permanently lose the deduction.
The “Substantially Identical” Test
The IRS has never published a bright-line list. Consensus in 2026:
- Same CUSIP / share class of the same ETF: always substantially identical.
- Two S&P 500 index funds from different providers (VOO vs IVV vs SPY): gray area — IRS has never enforced, but most practitioners treat these as substantially identical.
- S&P 500 fund vs total market fund (VOO vs VTI): generally treated as not substantially identical.
- Same underlying index, different currency hedging or fund structure: generally safe.
- Different but correlated sectors (two tech ETFs): safe unless they track the same index.
The conservative rule: swap to a different index, not just a different provider.
Substantially Identical Test: Common Swap Pairs
| Sell (Loss) | Buy as Replacement | Substantially Identical? | Risk Level |
|---|---|---|---|
| VOO (S&P 500) | IVV (S&P 500) | Yes — same index | High |
| VOO (S&P 500) | SPY (S&P 500) | Yes — same index | High |
| VOO (S&P 500) | VTI (Total Market) | No — different index | Low |
| VTI (Total Market) | ITOT (Total Market) | Gray area — same exposure | Medium |
| VTI (Total Market) | SCHB (Broad Market) | Gray area — overlapping but different index | Medium |
| QQQ (Nasdaq-100) | XLK (Tech Sector) | No — different index | Low |
| BND (Total Bond) | AGG (Total Bond) | Yes — same index | High |
| BND (Total Bond) | BIV (Intermediate-Term Bond) | No — different index | Low |
| Individual stock (AAPL) | Tech ETF holding AAPL | No — substantially different | Low |
Timing and Settlement
Cost basis is tracked at the lot level in 2026 — your broker’s default cost-basis method (FIFO, average, specific ID) determines which shares are sold. Specific ID gives the most control for harvesting: you can sell exactly the tax lots with the largest losses.
Settlement still uses T+1 (next business day) following the 2024 change. Execution date — not settlement date — is what the wash sale window measures from.
What It Means For You
Three patterns frame tax-loss harvesting decisions in 2026:
- Rebalancing with concentrated gains elsewhere: harvest losses proactively before year-end to offset. Our index funds vs individual stocks lessons piece frames the broader allocation question — harvesting is the tax wrapper on the rebalancing.
- Market downturn in a taxable account: harvest losses as they appear, rotate to a non-substantially-identical replacement, keep the market exposure. Over a 30-year horizon this can add 0.3–0.7% of annualized alpha from pure tax efficiency.
- Single large concentrated position you want to diversify out of: harvest losses aggressively elsewhere to soak up the capital gains hit from the concentrated sale. This pairs with the broader risk-management framing in recession-proof investments.
The one scenario where harvesting doesn’t help: you’re in the 0% long-term capital gains bracket (roughly under $47,000 single / $94,000 MFJ taxable income in 2026). If your gains are taxed at 0% anyway, harvesting losses to offset them burns the losses without creating value. Different advice applies — revisit at higher income.
Action Steps
- Review your taxable account at quarter-end, not just December. December is crowded — better prices for non-substantially-identical replacements come earlier in the year.
- Set your broker’s cost-basis method to Specific ID if it isn’t already. FIFO can force you to sell higher-basis lots first, reducing harvesting flexibility.
- Identify positions with unrealized losses of at least $500 per lot — below that, the fees and tracking effort rarely pay off.
- Choose a replacement that tracks a different index. Same provider, different index is usually safer than different provider, same index. A common playbook: VOO (S&P 500) → VTI (total market) or VTI → ITOT.
- Check both IRAs and your spouse’s accounts for planned purchases in the 61-day window. This is the single most common mistake.
- Execute the sale and replacement same-day to minimize market risk during the swap. T+1 settlement makes this straightforward.
- Track harvested losses on Schedule D. TurboTax and most tax software pull the 1099-B and flag disallowed wash sales automatically — verify rather than trust.
Authority reference: the IRS Publication 550 on investment income is the official source for the wash sale and capital gains rules in 2026.
FAQ
Does the wash sale rule apply to mutual funds too?
Yes. Any “security” — stocks, ETFs, mutual funds — is covered. Bonds from the same issuer can also trigger it, though the IRS is less aggressive there.
What about cryptocurrency?
As of 2026, crypto is not subject to the wash sale rule under current IRS guidance — crypto is treated as property, not a security. Several legislative proposals would close this gap; check the latest rules before relying on it.
Can I buy the replacement security in my 401(k) during the window?
Technically, yes — the IRS has not explicitly extended the wash sale rule to employer retirement plans in the same way as IRAs. Most practitioners stay conservative and avoid it to sidestep ambiguity.
What if I accidentally triggered a wash sale?
The loss isn’t lost — it’s deferred. The disallowed amount is added to the cost basis of the replacement shares, so when you eventually sell those, you recoup the loss. The tax hit is timing, not dollars.
Does tax-loss harvesting work in retirement accounts?
No — IRAs and 401(k)s don’t have taxable capital gains or losses in the first place. Harvesting only makes sense in taxable brokerage accounts.
Bottom Line
Tax-loss harvesting in 2026 is one of the cleanest sources of “alpha” available to DIY investors — but only if you respect the wash sale rule across all your and your spouse’s accounts, including IRAs. Swap to a different index, keep the 61-day window clear, and track the harvested losses each year so you can offset gains and up to $3,000 of ordinary income. Over a long horizon, the tax savings compound into real money.
This article is for informational purposes only and does not constitute investment advice. Always do your own research before making financial decisions.