WalletGrower
Taxes

Tax-Loss Harvesting: How to Turn Investment Losses Into Tax Savings

Rachel Kim
April 12, 2026
9 min read

Updated April 15, 2026

Quick answer: Tax-loss harvesting is the practice of selling investments at a loss to offset capital gains — and up to $3,000 of ordinary income per year — on your tax return. Unused losses roll forward indefinitely. Done right in a taxable brokerage account, it can save high earners several thousand dollars a year without changing overall portfolio risk. Watch out for the IRS "wash sale" rule, which disallows the loss if you buy a "substantially identical" security within 30 days before or after the sale. Last verified: April 2026.

Most investors think of their portfolio in one color — green when it's up, red when it's down. Tax-loss harvesting is the strategy that turns red into green. By intentionally realizing losses on investments that are underwater, you create a tax asset you can use to offset gains elsewhere in your portfolio, lower the tax bill on your paycheck, and compound more wealth over decades.

It's not a loophole. It's not aggressive. The IRS has acknowledged it in the tax code for decades. But it does have rules, and the difference between a legitimate harvest and a technical foot-fault (the wash-sale rule) is narrower than most people realize. This guide walks through exactly how the mechanics work, when to harvest, what to buy as a replacement, and how to calculate the real dollars you'll save in 2026.

How tax-loss harvesting actually works

When you sell a security for less than you paid, you "realize" a capital loss. The IRS lets you use that loss to offset capital gains from other sales during the same tax year. If your losses exceed your gains, you can deduct up to $3,000 of the net loss against ordinary income (wages, interest, etc.) in a single year. Any remaining loss carries forward indefinitely into future tax years.

Here's the ordering the IRS uses to pair gains and losses, which matters because short-term gains are taxed at your marginal rate (up to 37% federal in 2026) while long-term gains top out at 20% (or 23.8% with net investment income tax):

  1. Short-term losses first offset short-term gains
  2. Long-term losses first offset long-term gains
  3. Any net loss that remains offsets the opposite category
  4. Any remaining net loss up to $3,000 offsets ordinary income
  5. The rest carries forward to future years

The tax savings are the difference between your marginal rate on the loss category and zero. A $10,000 short-term loss used against short-term gains for a taxpayer in the 35% federal bracket saves $3,500 in federal tax alone — more if you live in a state like California that taxes capital gains as ordinary income.

The wash-sale rule — the trap that undoes the whole strategy

Section 1091 of the Internal Revenue Code — the wash-sale rule — says that if you sell a security at a loss and buy a "substantially identical" security within 30 days before or 30 days after the sale, the loss is disallowed for the current year. Instead, it's added to the cost basis of the replacement security, so you eventually recover the loss when you sell the replacement — but you lose the immediate tax benefit.

"Substantially identical" is the phrase that trips people up. The IRS has never issued a bright-line definition, but the consensus among tax attorneys is:

  • Same stock: clearly identical. Selling 100 shares of Apple at a loss and buying 100 shares of Apple 10 days later triggers the rule.
  • Two index funds tracking the same index: likely substantially identical. Selling VOO (Vanguard S&P 500) and buying SPY (SPDR S&P 500) within 30 days is widely treated as a wash sale even though the tickers differ.
  • Two funds tracking similar but different indexes: generally not substantially identical. Selling VOO and buying VTI (total U.S. market) is the textbook harvest swap — the indexes are ~85% overlapping but legally different.
  • Stock and an option on the same stock: yes, covered by the rule.
  • Spousal and IRA accounts: the rule applies across all your accounts, including your spouse's and your IRA. Harvesting a loss in a taxable account and having your IRA auto-buy the same fund 20 days later still triggers the wash.

When to harvest losses (and when not to)

The best time to harvest is whenever a position is materially underwater — you do not have to wait until December. Many brokerages (Wealthfront, Betterment, Fidelity's tax-loss harvesting service) scan taxable accounts daily and execute harvests automatically when losses cross a threshold.

That said, three windows matter:

  1. Any time the market drops 5% or more. Broad drawdowns are the richest harvest opportunities because almost every index fund has an unrealized loss.
  2. Late December. The IRS calendar year closes Dec 31, so you need the trade settled by that date for the loss to count on the current year's return.
  3. Right after buying a volatile position. New positions have the smallest cost-basis buffer, so short-term drawdowns often push them into loss territory quickly.

Do not harvest if: (1) your marginal rate will be higher in future years (you're better off saving the loss for later), (2) you're in the 0% long-term capital gains bracket ($47,025 single / $94,050 married in 2026 — a loss is worthless here), or (3) the position is inside a tax-advantaged account like a 401(k), IRA, or HSA. Losses inside those accounts have no tax value because gains aren't taxed there either.

Comparison: popular harvest swaps for 2026

Sell (loss)Buy (replacement)Index overlapExpense ratio differenceWash-sale safe?
VOO (S&P 500)VTI (Total U.S. Market)~85%+0.00%Yes
VTI (Total U.S. Market)SCHB (Schwab Broad Market)~95%-0.01%Likely yes
QQQ (Nasdaq-100)VUG (Vanguard Growth)~70%-0.16%Yes
VEA (Developed ex-U.S.)IEFA (iShares Core MSCI EAFE)~90%+0.02%Likely yes
VWO (Emerging Markets)IEMG (iShares Core EM)~85%-0.02%Likely yes
BND (Total Bond)AGG (iShares Core Bond)~97%+0.00%Gray area

Doing the math — a real example

Say you bought $60,000 of a tech fund in 2024 and it's worth $48,000 today. You're in the 32% federal bracket and have $10,000 of short-term gains from other trades you closed this year.

  • Sell the tech fund → realize a $12,000 long-term loss
  • $10,000 of the loss offsets $10,000 of short-term gains → saves ~$3,200 federal tax (32% × $10,000)
  • Remaining $2,000 of loss offsets up to $3,000 of ordinary income → saves ~$640 federal tax
  • Total federal tax savings: ~$3,840 in a single year
  • Immediately buy a broad U.S. market fund (VTI) with the $48,000 proceeds — stay invested and maintain market exposure

After 31 days, if you want your original tech-fund allocation back, you can switch back without triggering the wash-sale rule (the 30-day window has closed). Most investors just keep the replacement — the long-run returns are very similar.

Pros:

  • Reduces your current-year tax bill without changing your overall market exposure
  • Locks in a permanent tax asset (loss carryforwards don't expire)
  • Especially powerful for high earners in top federal and state brackets
  • Some robo-advisors automate the entire process daily

Cons:

  • Only applies to taxable brokerage accounts — useless in 401(k)/IRA/HSA
  • Lowers the cost basis of the replacement security, so the tax is deferred, not eliminated (still net-positive because of the time value of money)
  • Wash-sale rule traps the unwary, especially across spousal or IRA accounts
  • Transaction timing and record-keeping add complexity
  • Zero benefit for taxpayers in the 0% long-term capital gains bracket

How the pros automate it

Three approaches have become standard in 2026:

Robo-advisor tax-loss harvesting (Wealthfront, Betterment, Schwab Intelligent Portfolios): Direct-indexing or ETF-based portfolios are scanned daily. Losses are harvested automatically, with a pre-selected swap pair to avoid wash sales. Fees are 0.25%–0.40% of assets per year, which for large taxable accounts is usually more than offset by the harvested loss value.

Direct indexing (Fidelity Managed FidFolios, Wealthfront Stock-Level TLH, Vanguard Personalized Indexing): instead of owning one S&P 500 ETF, you own 100-200 of the underlying stocks directly. Losses can be harvested at the individual-stock level even when the overall index is up, producing 2-4x the harvest yield of ETF-only TLH. Worth considering once your taxable portfolio passes roughly $250,000.

Manual harvesting at a discount broker (Fidelity, Schwab, Vanguard, Robinhood): free to execute, but requires you to identify candidates and execute the swap yourself. A spreadsheet showing cost basis by tax lot is essential. Most brokers now show unrealized gain/loss by lot directly in their portfolio view.

Record-keeping rules you cannot skip

  • Save every 1099-B. Your broker reports all realized gains and losses to the IRS. The form also flags wash sales your broker identified within a single account — but not wash sales across brokers or into your IRA.
  • Track the cost-basis method. "Specific identification" (you pick the tax lots to sell) beats "average cost" or "FIFO" for harvesting because it lets you sell only the underwater lots. Set specific-ID as your default at the broker.
  • Keep a harvest log. For every swap: date sold, security sold, cost basis, sale price, loss, replacement security, date bought. A simple spreadsheet is enough. When loss carryforwards span years, you'll thank yourself.

Related tools and guides on WalletGrower:

Frequently asked questions

Q: Can I harvest losses in my 401(k) or IRA?
No. Losses inside tax-advantaged accounts have no tax value, because capital gains and income are not taxed in those accounts to begin with. Tax-loss harvesting is strictly a taxable-brokerage-account strategy.

Q: How much can I actually save in a year?
The deduction against ordinary income is capped at $3,000 per year ($1,500 if married filing separately), but the offset against capital gains is unlimited. For someone in the 32% federal bracket with $20,000 of short-term gains fully offset by harvested losses, the single-year savings are around $6,400 in federal tax alone, plus state tax savings.

Q: Do loss carryforwards ever expire?
No. Unused capital losses roll forward indefinitely until you use them up or until death. At death, carryforwards are lost — they do not transfer to heirs. Something to plan for in older investors' tax strategies.

Q: What happens if I accidentally trigger a wash sale?
The loss is disallowed for the current year but added to the cost basis of the replacement security. You eventually recover the loss when you sell the replacement. You don't lose the tax benefit forever — you just lose the timing. Brokerages track wash sales within their own systems; cross-brokerage or cross-account wash sales are your responsibility to track.

Q: Is harvesting worth it for small accounts?
The $3,000 ordinary-income deduction is the same for a $10,000 portfolio and a $10 million portfolio, but the paperwork is the same too. Most advisors say the strategy is clearly worth it above roughly $25,000 in taxable assets; below that, you're better off focusing on maxing tax-advantaged accounts first (401(k), IRA, HSA).

Q: Can I harvest in December and rebuy the same fund in January?
Only if at least 31 days pass between the sale and the repurchase. A late-December sale and a mid-January repurchase fall within the 30-day window and will be flagged as a wash. Wait until the first trading day more than 30 days after the sale, or stay in the replacement security indefinitely.

Q: Do robo-advisor fees eat up all the harvested savings?
Rarely. Most robos charge 0.25%–0.40% per year. Harvesting yield on diversified taxable portfolios averages 0.5%–2.0% per year in tax savings (higher in volatile years, much higher with direct indexing). For most high earners with six-figure taxable accounts, the net benefit is positive even after fees.

This article is for informational purposes and does not constitute tax, legal, or investment advice. Tax laws change; 2026 federal brackets and capital gains thresholds are the ones cited here. Consult a qualified CPA or tax attorney before making significant tax-motivated trades. WalletGrower may earn a commission if you open an account through links on this page, at no cost to you.

Get Free Credit Score

Earn Extra Cash with Swagbucks

Get paid for surveys, shopping online, and watching videos. Over $800M paid to members.

Start Earning

Sponsored partner

Affiliate Disclosure

WalletGrower may earn affiliate commissions when you sign up for products and services through our links. This does not cost you anything extra and helps us maintain our free guides and tools. We only recommend services we believe provide genuine value.

Enjoyed this article?

Subscribe to WalletGrower for free weekly strategies to grow your money.

Join 10,000+ readers. No spam, unsubscribe anytime.

Related Articles