An investment loss can lower the tax cost of an investment gain. But the loss has to qualify. A purchase made too close to the sale can undo the expected tax result.
How does tax-loss harvesting work?
Tax-loss harvesting means selling an investment that is worth less than you paid for it. The completed sale creates a capital loss. That loss can offset capital gains from other sales on your tax return.
The point is not to make a bad investment look good. You already have the loss. The sale turns that drop in value into a tax item that may reduce gains recognized in the same year.
The tax result depends on the rest of your return. Short-term and long-term gains and losses follow different steps before they are combined. Your holding periods, other trades, and carried-over losses can all change the final number.
What is a simple tax-loss harvesting example?
Suppose you bought an investment for $20,000 and later sold it for $14,000. That sale creates a $6,000 capital loss.
Earlier in the same year, you sold another investment and recognized a $10,000 capital gain. The $6,000 loss can offset part of that gain, leaving a $4,000 net capital gain before considering your other trades and tax items.
This does not mean you saved $6,000 in tax. It means $6,000 of gain was offset. The actual tax effect depends on whether the gains and losses are short-term or long-term, your tax rates, and the rest of your return.
What is the wash-sale rule?
A wash sale happens when you sell stock or securities at a loss and buy substantially identical stock or securities within 30 days before or after the sale. If the rule applies, you cannot claim that loss right away.
In a taxable account, the disallowed loss is generally added to the tax cost of the replacement investment. That usually delays the loss until a later sale. A purchase in an IRA or Roth IRA can also trigger the rule. The IRA’s tax cost is not increased, so the loss may be permanently lost instead of delayed.
The rule is wider than many investors expect. These purchases may matter:
- Buying the same investment back a week after selling it.
- An automatic dividend reinvestment that buys a small number of shares.
- A purchase in a second brokerage account.
- A purchase in your IRA or Roth IRA.
- A spouse buying the same investment.
“Substantially identical” is not a simple name-matching test in every case. The IRS says the answer depends on the facts and circumstances. Do not assume two similar funds are different enough without reviewing the specific investments.
Why might your broker’s tax form miss a wash sale?
A Form 1099-B may not show every wash sale you must report. Brokers are required to report only certain wash sales, mainly when matching securities are sold and bought in the same account. The tax rule can still apply across accounts or when a spouse or retirement account makes the replacement purchase.
That is why investment activity and tax reporting must be coordinated. Before filing, gather trade records from every taxable and retirement account. Include your spouse’s accounts when relevant. Flag automatic purchases, and review trades made in January that could affect a loss sale from December.
Your tax preparer may need to adjust a transaction on Form 8949 even when the broker did not. Share the records before the return is prepared, not after a notice arrives.
The bottom line
Tax-loss harvesting can offset capital gains, but a nearby purchase can delay or erase the expected benefit. Check all accounts, automatic trades, and a spouse’s activity before treating the loss as deductible.
Santafino’s fee-only fiduciary wealth management firm and CPA firm coordinate investment activity with tax reporting. That gives the investment decision and the tax return one shared set of facts.
FAQ
What is tax-loss harvesting?
Tax-loss harvesting means selling an investment for less than you paid so the capital loss can offset capital gains. The sale must be completed, and the wash-sale rule can delay or prevent the deduction.
How long do you have to wait to avoid a wash sale?
The rule looks at purchases made within 30 days before or after the loss sale. That creates a 61-day window centered on the sale date, including the day of the sale.
Can a wash sale happen across two brokerage accounts?
Yes. A purchase in another account, an IRA, or a Roth IRA can count, even if the broker does not show the wash sale on Form 1099-B.
Does a spouse's purchase trigger the wash-sale rule?
It can. IRS guidance says a spouse's purchase of substantially identical stock can cause a wash sale, so both spouses' accounts should be reviewed together.



