Watch Out for Wash Sales

March 28, 2024 Hayden Adams
What the IRS rule on wash sales might mean for you.

Getting a tax break when you sell a losing investment—better known as tax-loss harvesting—is one of the few upsides of dumping an underperforming asset. So, you wouldn't want to lose that tax break by falling afoul of an IRS rule governing "wash sales."

In short, a wash sale is when you sell a security at a loss for the tax benefits but then turn around and buy the same or a similar security. It doesn't even need to be intentional. For example, if you sold only part of a position for tax-loss harvesting purposes and then had reinvested dividends, you could lose some of your tax break.

Here we'll answer common questions about the wash sale rule.

Q: How does the wash sale rule work?

If you sell a security at a loss and buy the same or a substantially identical security within 30 calendar days before or after the sale, you won't be able to take a loss for that security on your current-year tax return. However, there are some compensations: You will be able to add the amount of the loss back onto the cost basis of the replacement security, which can help with taxes later, as we'll see below. In addition, the holding period of the original security gets tacked onto to the holding period of the replacement security.

Here's an example:

Let's say you bought 100 shares of XYZ stock for $10 per share ($1,000 of stock). One year later, the stock starts dropping, so you sell your 100 shares for $8 per share—a $200 loss. Three weeks later, XYZ is trading at $6 per share, and you decide that price is too good to pass up, so you repurchase the 100 shares for $600. This triggers a wash sale.

As a result, the $200 loss is disallowed as a deduction on your current-year tax return and added to the cost basis of the repurchased stock. That bumps the cost basis of your $600 of replacement stock up to $800, so if you later sell that stock for $1,000, your taxable gains will be $200 instead of $400. And because you previously held XYZ for a year, it'll automatically be treated as a long-term capital gain, even if you sell it after just a few months.

So, it's not all bad news. A higher cost basis decreases the size of any future gains realized from the sale of the replacement security, thereby lowering your future tax obligation. If you sell the investment at a loss, the higher cost basis would actually increase the size of the loss for which you could claim a deduction.

And a potential upside of the extended holding period is that it would lower your tax obligation if you sold the replacement security less than a year after. (Normally, short-term capital gains from investments held for less than a year are taxed at the higher regular income tax rate, while longer-term capital gains are taxed at the lower capital gains rate).

Q: Which securities are covered by the wash sale rule?

Generally, if a security, such as stocks, exchange-traded funds (ETFs), and mutual funds, has a CUSIP number (a unique nine-character identifier for a security), then it's most likely subject to the wash sale rule. In addition, selling a security at a loss and then buying an option on that same security will also trigger the wash sale rule.

Q: What if I wanted to sell a losing security but didn't want to be out of the market for an entire month just to avoid the wash sale rule?

You could sell the security at a loss and then use the proceeds from that sale to purchase a similar—but not substantially identical—security that suits your asset allocation and long-term investment plan.

Unfortunately, the government hasn't provided a straightforward definition of what it considers "substantially identical." Investors have to use their best judgment to avoid the wash sale rule.

For example, let's say you took a loss on an ETF tracking the S&P 500® index (SPX). To avoid a wash sale, you could replace it with a different ETF (or several different ETFs) with similar but not identical assets, such as one tracking the Russell 1000 Index® (RUI). That would preserve your tax break and keep you in the market with about the same asset allocation.

Q: What if I sold a loser in one of my Schwab accounts and then bought it again with another account? What about my IRA?

The wash-sale rule applies across all your accounts, including those outside Schwab, as well as transactions in your IRA—and it the rule extends even to your spouse's accounts. Furthermore, it's up to you keep track of what's happening across your various accounts. IRS regulations require only that Schwab track and report wash sales on the same CUSIP number within the same account.

Q: Could I sell a security at a loss on Dec. 15 to squeeze it into the current tax year and then repurchase the security on Jan. 4 without triggering a wash sale

No, the wash sale rule is not confined to the calendar year. In this situation, your loss would be disallowed if you reacquired the security within 30 days.

The information provided here is for general informational purposes only and should not be considered an individualized recommendation or personalized investment advice. The investment strategies mentioned here may not be suitable for everyone. Each investor needs to review an investment strategy for his or her own particular situation before making any investment decision.

All expressions of opinion are subject to change without notice in reaction to shifting market conditions. Data contained herein from third-party providers is obtained from what are considered reliable sources. However, its accuracy, completeness or reliability cannot be guaranteed.

Examples provided are for illustrative purposes only and not intended to be reflective of results you can expect to achieve.

This tax information is not intended to be a substitute for specific individualized tax, legal, or investment planning advice. Where specific advice is necessary or appropriate, Schwab recommends that you consult with a qualified tax advisor, CPA, financial planner, or investment manager. Depending on the type of account you have, there are different rules for withdrawals, penalties, and distributions. Please understand these before opening your account.

Investing involves risk including loss of principal.

Indexes are unmanaged, do not incur management fees, costs and expenses, and cannot be invested in directly. For more information on indexes please see

The Schwab Center for Financial Research is a division of Charles Schwab & Co., Inc.