Tax-loss harvesting is the practice of selling an investment for less than its cost in a taxable account, so the realized loss offsets capital gains or, within a limit, ordinary income. The saving is real but usually smaller and later than the headline suggests: the replacement investment starts with a lower cost basis, so more gain is taxed when it is eventually sold, and the wash-sale rule postpones the deduction if the same or a substantially identical investment is bought within 30 days before or after the sale.
Key takeaways
- Losses offset gains, then up to $3,000 a year ($1,500 if married filing separately) of other income; the rest carries forward until used, though not past the taxpayer's death.
- A $5,000 loss is worth $0 against a gain in the 0% long-term band, $750 at 15%, $1,000 at 20% and $1,200 against a short-term gain taxed at an assumed 24%.
- A wash sale normally postpones the loss by adding it to the new shares' basis; a repurchase inside an IRA or Roth IRA loses it without that adjustment.
- Harvesting mostly defers tax: deferring $750 for 10 years is worth about $243 at a 4% discount rate, more if the loss offsets short-term gain now and the later gain is long-term.
- The wash-sale statute does not expressly cover digital assets. A House committee-approved bill would cover sales after September 14, 2026; as of October 20, 2026 it was not law.
How capital losses are netted
Every sale in a taxable account produces a capital gain or loss against the cost basis. Gains and losses on assets held one year or less are short-term; those held more than one year are long-term, with the holding period counted from the day after acquisition through the day of sale, per IRS Topic 409. Net short-term gains are taxed as ordinary income, so the most valuable loss is one that ends up offsetting short-term gain.
IRS Publication 550 sets out the steps. Short-term gains and losses, including any short-term carryover, are combined into a net short-term figure; long-term items, including any long-term carryover, into a net long-term figure; and the two are then combined. If the total is a loss, the deduction against other income is the lesser of $3,000 ($1,500 if married filing separately) or that net loss, claimed on line 7a of Form 1040. Anything above the limit carries over to later years.
Illustrative example 1: a short-term gain and a losing position
Assume an investor has a $10,000 short-term gain and a marginal ordinary rate of 24%. The figures ignore state tax, the 3.8% surtax discussed below and trading costs.
| Scenario | Net result | Federal tax at 24% |
|---|---|---|
| No loss harvested | $10,000 net short-term gain | $2,400 |
| Sell a position down $8,000 | $2,000 net short-term gain | $480 |
| Sell a position down $15,000 instead | $5,000 net loss: $3,000 deducted, $2,000 carried forward | $0 on the gain, plus $720 saved on ordinary income |
Selling the $8,000 loser saves $1,920 ($2,400 minus $480). In the third row the $10,000 gain is fully offset, saving $2,400, and the $3,000 deduction saves another $720 (3,000 × 24%), for $3,120 in the first year, with $2,000 left for later years. In both cases the investor has still lost $8,000 or $15,000 on the position itself.
What a loss is worth at each rate
A harvested loss saves tax at the rate of whatever it offsets. Most long-term gains are taxed at 0%, 15% or 20% (collectibles and some other gains have higher maximum rates). Revenue Procedure 2025-32, section 3.03, sets the 2026 amounts up to which the 0% and 15% rates apply; above the 15% amount the rate is 20%.
| 2026 filing status | Top of 0% band | Top of 15% band |
|---|---|---|
| Single (all other individuals) | $49,450 | $545,500 |
| Married filing jointly / surviving spouse | $98,900 | $613,700 |
| Married filing separately | $49,450 | $306,850 |
| Head of household | $66,200 | $579,600 |
The thresholds apply to total taxable income, including the gain, so one gain can straddle two rates. The net investment income tax (NIIT) adds 3.8% for people whose modified adjusted gross income (MAGI) exceeds $200,000 (single or head of household), $250,000 (married filing jointly) or $125,000 (married filing separately), per IRS Topic 559. It applies to the lesser of net investment income, which includes net gains from selling stocks, bonds and mutual funds, or the MAGI excess over the threshold.
| What the $5,000 loss offsets | Rate | Federal tax saved |
|---|---|---|
| Long-term gain in the 0% band | 0% | $0 |
| Long-term gain | 15% | $750 |
| Long-term gain | 20% | $1,000 |
| Long-term gain, NIIT applies | 15% + 3.8% | $940 |
| Long-term gain, NIIT applies | 20% + 3.8% | $1,190 |
| Short-term gain (24% assumed) | 24% | $1,200 |
Each row is the loss times the rate. The NIIT rows assume that, before the loss, MAGI is at least $5,000 above the threshold and net investment income is at least $5,000; if MAGI were only $2,000 over, the surtax saving would be $76, not $190. State income tax comes on top.
The wash-sale rule in brief
Under Publication 550, a wash sale occurs when stock or securities are sold at a loss and, within 30 days before or after the sale (a 61-day window), the investor buys substantially identical stock or securities, acquires them in a fully taxable trade, acquires a contract or option to buy them, or acquires them for an IRA or Roth IRA. A purchase by the investor's spouse or a corporation the investor controls also counts; dealers acting in the ordinary course of business are exempt.
For purchases outside retirement accounts the loss is postponed, not forfeited: the disallowed loss is added to the basis of the new shares, and the holding period of the old shares carries over. The IRA case is different. Revenue Ruling 2008-5 holds that the loss is disallowed and that the investor's basis in the IRA or Roth IRA is not increased, so there is no later deduction to recover it.
Illustrative example 2: a wash sale and its basis adjustment
Assume an investor bought 100 shares for $5,000 and sold them for $4,200, a loss of $800. Ten days later the investor buys 100 substantially identical shares for $4,300 in the same taxable account.
Disallowed loss = $5,000 - $4,200 = $800
New basis = $4,300 + $800 = $5,100
Gain if sold later for $5,500 = $5,500 - $5,100 = $400
The $800 is not deducted this year. If the new shares are later sold for $5,500, the taxable gain is $400 instead of the $1,200 that the $4,300 purchase price alone would imply, so the loss is recovered then. Because the holding period carries over, that later sale can qualify as long-term sooner.
Deferral, not elimination
Harvesting lowers the basis of what the investor holds. Shares bought for $10,000 and sold at $5,000 realize a $5,000 loss; a replacement bought for $5,000 that climbs back to $10,000 carries a $5,000 gain the original shares would not have had. Tax is saved now and owed later, unless that gain is never taxed.
Illustrative example 3: what the deferral is worth
Assume a $5,000 loss offsets a long-term gain taxed at 15%, saving $750 now, and the replacement is sold in 10 years with a $5,000 larger gain, also at 15%, costing $750 then. At a 4% discount rate:
PV = tax later / (1 + r)^n = $750 / (1.04)^10 = $750 / 1.4802 = $506.67
Benefit of deferral = $750 - $506.67 = $243.33
Here r is the discount rate and n the number of years. The benefit is about $243, not $750, assuming an unchanged rate, a 4% value on the saved $750 and a sale after 10 years. If the later rate were 20%, the later $1,000 would have a present value of $675.56 and the benefit would fall to $74.44. The rate gap can also work the other way: a loss that offsets a short-term gain at 24% saves $1,200 now, while the extra $5,000 of gain, if later long-term at 15%, costs $750.
For an heir, the deferral can become permanent. Inherited property generally takes a basis equal to its fair market value at death (or the alternate valuation date), per IRS Publication 551, so gain built up before death is not taxed to the heir, except on appreciated property the heir or spouse gave the decedent within one year before death. Donated shares are a different case: for shares held over a year, IRS Publication 526 says the deduction generally uses fair market value, not the lowered basis, subject to exceptions, limits and itemizing.
When harvesting is worth less
- No gains, or gains in the 0% band. Without gains, only $3,000 a year is usable; a loss that must offset 0%-band gains saves no federal tax on them.
- Costs. Bid-ask spreads and any higher fund expenses on the replacement reduce the net saving, and can consume most of a small loss.
- State taxes. Each state sets its own income tax rules, which can differ from the federal rules described here.
- Drift from the original plan. A replacement that differs from what was sold changes the portfolio; the rebalancing calculator compares current weights with target weights (it does not model taxes).
Crypto, funds and direct indexing
Digital assets
The IRS digital assets page treats digital assets as property, producing a capital gain or loss on sale for investment holdings. The wash-sale statute speaks of stock or securities, and the Joint Committee on Taxation (JCT), in its description of H.R. 10357, says digital assets are not expressly within its scope and the IRS has issued no guidance on the point.
The House Ways and Means Committee approved the Digital Asset Tax Certainty Act (H.R. 10357) 38-5 on September 16, 2026. Per the JCT description, it would apply the wash-sale rule to traded digital assets other than qualified U.S. dollar stablecoins, and the version the committee approved would apply it to dispositions after September 14, 2026, the day the bill was introduced. As of October 20, 2026, Congress.gov lists that vote as the latest action; the bill has not passed either chamber. A crypto loss realized and bought back now could be affected if it is enacted in this form.
Fund and ETF swaps
Publication 550 says whether securities are substantially identical depends on all the facts and circumstances; ordinarily one corporation's stock is not substantially identical to another's. Its examples cover stock, preferred stock, bonds and warrants, not funds, so whether two funds tracking similar indexes are substantially identical is a judgment on the facts. Buying the same fund back within the window, whether in a taxable account or an IRA or Roth IRA, is covered.
Direct indexing
FINRA's overview of direct indexing describes it as buying many or all of the stocks in an index, which some investors pair with harvesting by selling the individual stocks that have fallen; it also warns that returns may differ from the index's and could be markedly lower, and that fees may be higher.
Frequently asked questions
Can a loss on my house or car offset gains?
No. IRS Topic 409 states that losses from selling personal-use property, such as a home or a car, are not deductible.
Does a carried-over loss stay short-term or long-term?
It keeps its character. Publication 550 says a long-term carryover reduces the next year's long-term gains before it reduces short-term gains. When the carryover is calculated, short-term losses are used first toward the annual limit.
What happens to an unused loss carryover after death?
Per Publication 550, it can be deducted only on the decedent's final income tax return, within the annual limits; the estate cannot deduct or carry over any of it.
What if I rebuy fewer or more shares than I sold?
Publication 550 matches the shares bought with an equal number of the shares sold, in the order they were bought. Only the matched shares fall under the wash-sale rule, so part of the loss can still be deducted, and the disallowed part is spread across the matched replacement shares in proportion.
Where do harvested sales and wash sales go on the return?
Sales go on Form 8949 and Schedule D; a wash sale gets "W" in column (f) and the disallowed loss as a positive number in column (g), per Publication 550. Box 1g of Form 1099-B shows it only for covered securities repurchased with the same CUSIP number in the same account, but an unreported wash sale still applies.
Checklist before selling at a loss
- Confirm the position is held in a taxable account; the rules above apply to losses realized there.
- Check the holding period and whether the loss is short-term or long-term, since it is netted against gains of the same type first.
- Estimate the rate the loss would offset using the tables above, including the 3.8% surtax if MAGI will stay above the threshold.
- List every purchase of the same or a substantially identical investment across all accounts, including IRAs and a spouse's accounts, for 30 days before and after the sale.
- Compare the tax saved with trading costs, the lower basis of the replacement and any state tax difference.
- Keep records of the sale, replacement and basis; carried-forward losses are figured on the worksheet in Publication 550 or the Schedule D instructions.
Sources
- IRS Topic 409, Capital gains and losses
- IRS Publication 550 (2025), Investment Income and Expenses
- IRS Topic 559, Net investment income tax
- IRS Revenue Procedure 2025-32 (2026 inflation adjustments)
- IRS Revenue Ruling 2008-5 (wash sales and IRAs)
- IRS Publication 551, Basis of Assets
- IRS Publication 526 (2025), Charitable Contributions
- IRS, Digital assets
- Joint Committee on Taxation, Description of H.R. 10357 (JCX-47-26)
- Joint Committee on Taxation, Description of the Chairman's amendment to H.R. 10357 (JCX-50-26)
- House Ways and Means Committee, September 16, 2026 release
- Congress.gov, H.R. 10357, Digital Asset Tax Certainty Act
- FINRA, The Basics of Direct Indexing