How to Use Tax-Loss Harvesting to Offset Investment Gains

Turning Losses Into a Tax Advantage

Nobody likes losing money on an investment. But what if that loss could actually save you money at tax time? That’s the idea behind tax-loss harvesting — a strategy that lets you use underperforming investments to reduce the taxes you owe on gains elsewhere in your portfolio.

It sounds counterintuitive at first. You’re deliberately locking in a loss. But when used thoughtfully, it’s one of the more practical tools available to everyday investors, not just the wealthy ones with a team of advisors.

What Tax-Loss Harvesting Actually Means

At its core, tax-loss harvesting involves selling an investment that has dropped in value below what you paid for it. That realized loss can then be used to offset capital gains you’ve made on other investments during the same tax year.

Say you sold shares of a tech company earlier in the year and made a $5,000 gain. Later, you notice that another stock in your portfolio is sitting at a $3,000 loss. By selling that losing position, you can reduce your taxable gain to just $2,000 — meaning you only pay capital gains tax on that smaller amount.

If your losses exceed your gains, you can even use up to $3,000 of the remaining loss to offset ordinary income. Any amount beyond that can be carried forward into future tax years.

Short-Term vs. Long-Term Gains: Why It Matters

Not all capital gains are taxed the same way. Short-term gains — from assets held less than a year — are taxed at your regular income rate, which can be significantly higher than the long-term capital gains rate applied to assets held over a year.

When harvesting losses, it’s most efficient to use short-term losses to offset short-term gains first, since those carry the heavier tax burden. Long-term losses are best applied against long-term gains. The IRS has specific rules about how these are matched up, so it’s worth understanding the order before you act.

The Wash-Sale Rule: A Critical Limitation

Here’s where many investors trip up. The IRS has a rule called the wash-sale rule, which disallows the tax loss if you buy a “substantially identical” security within 30 days before or after the sale — that’s a 61-day window in total.

So if you sell shares of an S&P 500 index fund at a loss and immediately buy a nearly identical fund from a different provider, the IRS may reject your loss claim. To stay compliant, you’d need to either wait out the 30-day window or replace the holding with something similar but not substantially identical — like switching from one broad market ETF to another that tracks a different index.

When Does This Strategy Make the Most Sense?

Tax-loss harvesting is most valuable in years when you have significant realized gains, when you’re in a higher tax bracket, or when market volatility has left parts of your portfolio underwater. It’s not a strategy you use once — it’s something to revisit throughout the year, not just in December.

Automated investing platforms, sometimes called robo-advisors, often offer this as a built-in feature. But you can do it manually too, especially if you keep a close eye on your portfolio and work with a tax professional who understands your full financial picture.

A Few Practical Tips Before You Start

  • Track your cost basis carefully. You need to know what you originally paid for each investment to calculate the real loss.
  • Don’t let the tax tail wag the dog. Selling a fundamentally strong investment just to harvest a short-term loss can hurt your long-term returns.
  • Consider transaction costs. Frequent selling can eat into the savings, especially in taxable accounts with commissions or spreads.
  • Talk to a tax advisor. The rules around capital gains and losses can get complicated quickly, and a small mistake can cost more than the tax savings.

Tax-loss harvesting won’t make bad investments good, but it can make the best of a bad situation. Used wisely, it’s a quiet but effective way to keep more of your money working for you — and that’s what smart investing is really about.