US investors · 2026 tax year

Tax-loss harvesting: how it works, the rules and what it saves

Tax-loss harvesting means selling an investment that's worth less than you paid, so the loss counts on this year's return. The loss cancels capital gains dollar for dollar, up to $3,000 of what's left comes off your salary and other income, and the rest carries forward to later years. You can stay invested by buying something similar straight away, but not the same or a substantially identical security in the 30 days before or after the sale, or the wash sale rule postpones the loss. For 2026, the sale has to happen by December 31.

The four numbers that matterUS federal rules, taxable accounts
Against income$3,000A year, after your gains

$1,500 if married filing separately

Wash sale window61 days30 before, 30 after

Plus the day of the sale

DeadlineDec 31Trade date in 2026

Settling in January is fine

CarryoverNo limitUntil it's used up

Short- or long-term label kept

Tax-loss harvesting calculator

Enter the gains you've already taken this year and the losses you could take before December 31. You get the federal tax you'd save with the 2026 brackets and standard deduction, including the 3.8% surtax, plus your state's share.

$
Gains already taken in 2026
$
Held a year or less
$
Held more than a year
Losses you could harvest
$
$
%
Other income is salary and everything else before the standard deduction. A net loss already taken this year goes in as a negative gain.
Tax saved by harvesting $2,755 Federal tax on your 2026 gains goes from $3,130 to $375.
Net gain left to tax
$2,500
Loss taken off other income
$0
Loss carried to 2027
$0
Federal saving, 3.8% surtax included
$2,755
State saving
$0

The short-term loss cancels the short-term gain first, at your income tax rate. What's left of the losses cancels long-term gains at 15%.

Federal income tax and the net investment income tax for the 2026 tax year, with the standard deduction and your gains as your only investment income. The state line applies your rate to the change in income. Losses carried in from earlier years go in as a negative gain.

A year-end harvest, worked through

Maya is single and earns $110,000. By December she has taken two gains and holds two positions that are under water. She sells both losers and buys similar investments the same day.

Maya's 2026 trades

Single filer, $110,000 salary, no other investment income.

Already sold this year

  • A stock held since 2021Long-term gain+$15,000
  • A stock bought in February, sold in JuneShort-term gain+$4,000

Harvested in December

  • A stock bought in March 2026Short-term loss−$9,000
  • An international stock fund bought in 2023Long-term loss−$7,500

Where the $2,755 comes from

Schedule D nets losses against gains of the same kind first, then across. Maya is in the 22% bracket and her long-term gains are taxed at 15%.

  1. $4,000 of the short-term loss cancels her short-term gain, which would have been taxed at 22%.$880
  2. The other $5,000 crosses over and cancels long-term gain at 15%.$750
  3. The $7,500 long-term loss cancels more long-term gain at 15%.$1,125
  4. Tax on her gains drops from $3,130 to $375. $2,500 of long-term gain is left.$2,755

How much of it she keeps

The replacements Maya bought start at today's lower prices, so their cost basis is $16,500 lower than what she sold. If they recover and she sells them years later at a long-term gain, she pays $2,475 of that back at 15%. The $280 is hers for good: it's the gap between 22% now and 15% later on the short-term part. The rest is an interest-free loan from the IRS, and it becomes permanent if she never sells: shares left to heirs get a new cost basis at death, and shares given to charity aren't taxed.

  • Saved for good: $280
  • Postponed until she sells the replacements: $2,475

With no gains at all this year, the same two losses would still be worth taking. $3,000 comes off her salary, saving $660 at 22%, and the other $13,500 ($6,000 short-term, $7,500 long-term) waits for next year's gains.

The order losses are used in

The IRS doesn't let you choose which gain a loss cancels. Schedule D does it in this order every year, carryforwards included.

Step 1

Short against short

Short-term losses cancel short-term gains, the ones taxed like salary at 10% to 37%.

Step 2

Long against long

Long-term losses cancel long-term gains, taxed at 0%, 15% or 20%.

Step 3

Across the line

A net loss on one side cancels a net gain on the other. A short-term loss used here saves only the long-term rate.

Step 4

$3,000, then next year

A net loss left over takes up to $3,000 off other income, short-term losses first. The rest carries forward with its label.

The wash sale rule

Sell at a loss and buy the same thing back within 30 days, either side, and the loss doesn't count yet. It's added to the cost basis of the new shares, and their holding period starts from the old ones. Our wash sale tracker explains the adjustment in detail.

A loss sold on December 15, 2026

No purchase of the same or a substantially identical security from November 15 to January 14.

Counts as buying back

  • The same stock or fund in any of your accounts, at any broker
  • Your IRA or Roth IRA buying it. Here the loss is gone for good
  • Your spouse buying it
  • Dividends reinvested into it during the window, for the shares they buy
  • A call option or other contract to buy it

Doesn't count

  • A different company in the same industry
  • Buying back on day 31 or later
  • Cryptocurrency held directly, which is property, not a security
  • Selling at a gain: the rule only covers losses

A dividend reinvestment of a few shares only disallows the loss on that many shares. Turn off reinvestment on anything you plan to harvest in December.

Staying invested: common fund swaps

The point is to keep your market exposure while the loss counts. Funds that follow different indexes hold different stocks in different weights, which is why investors use them as swaps. The IRS has never ruled on pairs of funds, so the closer two funds are, the more you're relying on judgment.

If you soldA swap that tracks a different index
VTIVanguard Total Stock Market · CRSP US Total Market
SCHBSchwab US Broad Market · Dow Jones U.S. Broad Stock Market
VOOVanguard S&P 500 · S&P 500
SCHXSchwab US Large-Cap · Dow Jones U.S. Large-Cap Total Stock Market
VXUSVanguard Total International Stock · FTSE Global All Cap ex US
IXUSiShares Core MSCI Total International Stock · MSCI ACWI ex USA IMI
VEAVanguard FTSE Developed Markets · FTSE Developed All Cap ex US
IEFAiShares Core MSCI EAFE · MSCI EAFE IMI
BNDVanguard Total Bond Market · Bloomberg U.S. Aggregate Float Adjusted
IUSBiShares Core Total USD Bond Market · Bloomberg U.S. Universal

Swapping VOO for another S&P 500 fund such as IVV is the grey zone: different issuer, same index, nearly the same holdings. For a single stock, the clean choices are to wait 31 days, or to buy a fund or a competitor you'd be happy to own. Swap back after the window if you prefer the original, keeping in mind that selling the replacement at a gain is a taxable sale too.

When harvesting doesn't pay

A harvest saves the rate your gains would have paid. When that rate is zero, or the loss sits where taxes don't reach, there's nothing to save.

0% bracket

Your gains are already tax-free

A married couple with $60,000 of income and $20,000 of long-term gains has $47,800 of taxable income, under the $98,900 limit for 0%. Their federal tax on the gains is $0, so harvesting an $8,000 loss saves $0 and only lowers their cost basis.

Retirement accounts

IRAs and 401(k)s

Losses inside an IRA, Roth or 401(k) never reach your return. Harvest in taxable accounts only.

Small or short-lived

Costs and a higher rate later

A loss of a few hundred dollars can disappear in the bid-ask spread of two trades. And if you expect a much higher tax rate when you sell the replacement, the postponed tax may come back bigger.

Tax-gain harvesting: the opposite move

When your long-term gains fall in the 0% band, sell winners instead and buy them straight back. You pay nothing now, and the new shares start at today's price, so a later sale owes less. The wash sale rule doesn't apply to gains.

The couple above has $51,100 of room left at 0% in 2026: their taxable income is $47,800 and the 0% band for long-term gains runs to $98,900 for married couples filing jointly ($49,450 single). Realizing up to that much more long-term gain costs no federal tax, though a gain can still cost state tax and push up other figures tied to income, such as ACA premium credits.

Harvesting outside the US

Other countries let losses cancel gains too, each with its own repurchase rule.

United Kingdom

A sale is matched with shares of the same company you buy back within 30 days after it, so "bed and breakfasting" doesn't crystallise the loss. Buying inside an ISA or a spouse's account isn't caught. See the UK share CGT calculator.

Canada

A superficial loss is denied when you, your spouse or a company you control buy the same property in the 30 days before or after the sale and still own it when those 30 days are up. The loss moves into the new shares' adjusted cost base. See the ACB calculator.

Australia

There's no fixed day count. The ATO treats a sale and quick buy-back done mainly for the tax loss as a wash sale it can cancel under the general anti-avoidance rules. See the Australian CGT calculator.

Find every harvestable loss across your brokers

A broker only has to report a wash sale on your 1099-B when the sale and the repurchase happen in the same account. A buy at another broker, in your IRA or by your spouse is usually yours to catch. AllInvestView puts every account in one tax report, so the losses and the repurchases sit side by side.

Tax-loss harvesting planner

Pick the lots, see the tax before and after

Your stock and ETF lots at a loss show up with their broker, purchase date and whether the loss is short- or long-term. Set a goal, such as a loss to harvest, gains to offset or cash to raise, and the planner builds a basket and shows the estimated tax before and after. Replacement shares bought in any account inside the window are flagged as a wash sale, and a Smart Alert can watch the window for you.

See the US tax report
AllInvestView AllInvestView tax-loss harvesting planner: three losing lots in CRM, ADBE and NKE across Fidelity and Schwab in the basket, estimated tax USD 753.26 before and USD 231.63 after, USD 521.62 lower, with USD 406.50 of the NKE loss disallowed by 10 replacement shares bought inside the wash-sale window AllInvestView tax-loss harvesting planner: three losing lots in CRM, ADBE and NKE across Fidelity and Schwab in the basket, estimated tax USD 753.26 before and USD 231.63 after, USD 521.62 lower, with USD 406.50 of the NKE loss disallowed by 10 replacement shares bought inside the wash-sale window
The planner on a demo account at two brokers. Selling three losing lots cuts the estimated tax by USD 521.62, and 10 NKE shares bought at Fidelity inside the window disallow USD 406.50 of the loss on the NKE lot sold at Schwab.View full-size View full-size

Five mistakes that undo a harvest

  1. Buying back in the IRA

    An automatic contribution into the same fund inside your IRA, within 30 days, wipes out the loss for good instead of postponing it.

  2. Forgetting dividend reinvestment

    A reinvested dividend in the window is a purchase. Turn reinvestment off on positions you plan to harvest.

  3. Selling the wrong lot

    Brokers default to first in, first out, which often sells your oldest and cheapest shares. Pick the specific high-cost lots at the time of the sale.

  4. Harvesting into the 0% band

    A loss that only cancels long-term gains taxed at 0% saves nothing and lowers your basis. Look at gain harvesting instead.

  5. Losing track of the carryforward

    Unused losses only help if they reach next year's Schedule D. Keep the Capital Loss Carryover Worksheet, or a tracker that carries the figure for you.

Tax-loss harvesting questions

What is tax-loss harvesting?

Selling an investment that's worth less than you paid, so the loss counts on this year's return. The loss cancels capital gains dollar for dollar, and up to $3,000 of what's left comes off your other income. You can stay invested by buying something similar, as long as it isn't substantially identical to what you sold within 30 days either side of the sale.

How much can tax-loss harvesting save?

The loss times the rate it would have been taxed at. A loss that cancels a short-term gain saves your income tax rate, up to 37% in 2026; one that cancels a long-term gain saves 0%, 15% or 20%, plus 3.8% if you pay the net investment income tax. Part of it comes back later, because the shares you buy as a replacement start from a lower cost basis.

What is the wash sale rule?

If you buy the same or a substantially identical security in the 30 days before or after you sell it at a loss, you can't deduct the loss then. It isn't gone: it's added to the cost basis of the shares you bought. Purchases by your spouse, in your IRA and through dividend reinvestment count too, and a repurchase in an IRA cancels the loss for good.

How much capital loss can I deduct in a year?

All of it against capital gains, plus up to $3,000 of other income ($1,500 if married filing separately). Anything left carries forward to the next year with no time limit and keeps its short-term or long-term character.

When is the deadline for tax-loss harvesting in 2026?

December 31, 2026. The loss belongs to the year of the trade date, so a sale placed on the last trading day counts even if it settles in January. Any repurchase inside the next 30 days still triggers the wash sale rule, so a December sale's window runs into January.

Can I harvest losses in an IRA or 401(k)?

No. Gains and losses inside an IRA, 401(k) or other retirement account don't go on your return, so a loss there saves nothing. Harvest in taxable brokerage accounts, and watch that the IRA doesn't buy back what you just sold.

Does the wash sale rule apply to crypto?

Not in 2026. The rule covers stock and securities, and the IRS treats cryptocurrency as property, so a crypto loss counts even if you buy the coin back the same day. It does apply to crypto ETFs and funds, which are securities.

See your losses before December 31

Link your brokers or bring in your trade history, and the tax report shows your losing stock and ETF lots, what harvesting them would save and which buys would trigger a wash sale.

Create a free account

Related calculators and guides

Sources

Rules and thresholds checked on 26 October 2026 for the 2026 tax year. This page explains federal rules in general terms; state rules differ.