Tax-loss harvesting is exactly what it sounds like: selling an investment that's worth less than you paid for it, realizing that loss on paper, and using it to offset gains elsewhere in your portfolio — or, if losses exceed gains for the year, up to $3,000 of ordinary income ($1,500 if married filing separately), according to the IRS's own guidance on capital losses. Anything beyond that $3,000 annual cap doesn't disappear — it carries forward to future tax years with no expiration date.
The mechanics are simple. The rule that turns this into something people actually get wrong is not.
The wash-sale rule, in plain terms
The wash-sale rule disallows the tax loss if you buy a "substantially identical" security within 30 days before or after the sale — a 61-day window total, since the 30-day count runs in both directions from the sale date. Sell a stock at a loss on December 15 and buy it back on January 10, and the loss is disallowed for tax purposes even though a full month has passed since the sale.
The rule applies clearly to individual stocks — sell Apple at a loss and buy it back inside the window, and the loss is wiped out. It gets more flexible with ETFs: selling one S&P 500 index ETF and immediately buying a different issuer's comparable fund generally avoids a wash sale despite the two funds holding nearly identical portfolios, because they aren't the same security. Notably, as of 2026 the wash-sale rule does not technically apply to cryptocurrency under current IRS interpretation — though pending legislation could extend it to digital assets, so this is a gap that may not stay open.
Where careful investors still get caught
- Automatic dividend reinvestment. If a fund you sold at a loss pays a dividend during the 61-day window and that dividend automatically reinvests into more shares of the same fund, you've triggered a wash sale without placing a single manual trade.
- Buying the same security in a different account. Selling a position at a loss in a taxable brokerage account while a retirement account — yours or a spouse's — buys the identical security during the window still counts. The IRS looks across all of an investor's accounts, including a spouse's, not just the one where the sale happened.
- Year-end timing that spills into January. A loss harvested in mid-December creates a restricted window that runs into the following January — exactly when many automatic rebalancing programs execute their first trades of the new year.
The 2026 brackets this is actually optimizing around
Long-term capital gains — on assets held more than a year — are taxed at 0%, 15%, or 20% depending on total taxable income. For the 2026 tax year, the brackets break down as follows:
- Single filers: 0% up to $49,450; 15% from $49,451 to $545,500; 20% above $545,500.
- Married filing jointly: 0% up to $98,900; 15% from $98,901 to $613,700; 20% above $613,700.
Harvesting a loss that offsets a gain which would otherwise have been taxed at 15% or 20% is a meaningfully different outcome than harvesting a loss purely to capture the $3,000 ordinary-income offset — both are legitimate, but the size of the benefit depends entirely on what the loss is actually being matched against.
The honest limits of this strategy
Tax-loss harvesting is a real, IRS-sanctioned tool — not a gimmick. But it's optimizing a tax bill, not an investment thesis. Selling a fundamentally sound holding purely to harvest a loss, then scrambling to find a "similar enough but not identical" replacement, adds trading costs and portfolio drift in service of a benefit that's capped at $3,000 a year against ordinary income. For most patient, long-term portfolios, this is a worthwhile once- or twice-a-year housekeeping exercise — not a strategy to build a portfolio around.