How to Avoid Violating Wash Sale Rules When Realizing Tax Losses

Tax-loss selling is an investment strategy that can help an investor reduce their taxable income for a given tax year. Tax-loss selling involves selling a security that has experienced a capital loss in order to report it as a capital loss when filing yearly income taxes, and thus lower or eliminate any capital gain that may be realized by other investments.

To successfully realize the loss for tax purposes, you must liquidate the position during the tax year. Any unrealized loss on an investment cannot be deducted from your income taxes.

Sometimes an investor will decide to replace that security with a similar security, allowing them to maintain a consistent, optimal asset allocation and achieve their desired returns. If you take this approach, it is important to be mindful that you do not accidentally trigger a wash sale in your investment account.

Key Takeaways

  • Wash-sale rules prohibit investors from selling a security at a loss, buying the same security again, and then realizing those tax losses through a reduction in capital gains taxes.
  • The wash-sale period occurs within 30 days of the transaction—30 days prior to the sale and 30 days after.
  • Tax-loss selling is an investment strategy that can help an investor reduce their taxable income for a given tax year; investors may be able to claim up to $3,000 in capital losses per year in order to offset their taxable income (if they are married filing jointly).
  • A common strategy for avoiding violating the wash-sale rule is to sell an investment and buy something with similar exposure.
  • Wash sale rules apply to the investor even if they hold different investment accounts.

What Is a Wash Sale?

A wash sale occurs when you sell or trade a stock or securities at a loss and within 30 days of the sale (either before or after), you purchase the same—or a "substantially identical"—investment. The wash-sale rule is a regulation established by the Internal Revenue Service (IRS) to prevent taxpayers from claiming artificial losses to maximize their tax benefits.

When a wash sale occurs in a non-qualified account, the transaction is flagged and the loss is added to the cost basis of the new, "substantially identical" investment you purchased. If you continue to trade the same investment, the loss gets carried forward with each transaction until the position has been fully liquidated for more than 30 days.

Wash sales must be reported on IRS Form 8949 when the federal return is filed.

The same rules apply if the spouse of the individual that sells the security, or a company controlled by that individual, purchases the same or substantially equivalent securities within the 30-day timeframe.

In addition, your holding period for the new stock or securities (for designating whether or not the investment will represent a short- or long-term capital gain) includes the holding period of the stock or securities that were previously sold.

Investments Subject to Wash Sale Rules

The wash-sale rule applies to stocks or securities in non-qualified brokerage accounts and individual retirement accounts (IRAs). The sale of options at a loss and the reacquisition of identical options within a 30-day timeframe would also violate the wash-sale rule.

IRS Publication 550 provides guidelines about what is considered a "substantially identical" investment and what may trigger a wash-sale violation. A substantially identical investment can include new and old securities issued by a corporation that has undergone reorganization or convertible securities and common stock of the same company.

When an investor holds several different investment accounts, wash-sale rules apply to the investor, rather than a specific account. The IRS requires that brokers track and report any sales of the same CUSIP number in the same non-qualified account. However, investors are responsible for tracking and reporting any sales that occur in all other accounts they control, including any accounts belonging to their spouse.

Offset Capital Gains Through Tax-Loss Selling

While some investors turn their attention to tax-loss selling towards the end of the calendar year, it is possible to use this strategy throughout the year to capture tax losses through rebalancing or replacing positions in your portfolio. Capital losses are used first to offset capital gains. After this, up to $3,000 per year can be used to offset other taxable income for an individual filer or married couple filing jointly (up to $1,500 for married filing individually).

For example, an investor realizes $2,000 in short-term capital gains and $5,000 in short-term capital losses for the same tax year. At the time they file their income taxes, they can offset the full amount of capital gains and $3,000 from their ordinary income. Depending on their state of residence, the investor may also be eligible for a reduction in their state taxes. Any remaining capital losses can be carried forward to future tax years. Unfortunately, losses cannot be transferred at death.

Strategies for Avoiding Wash Sales

There are strategies for avoiding wash sales while still taking advantage of taxable gains and losses. If you own an individual stock that experienced a loss, you can avoid a wash sale by making an additional purchase of the stock and then waiting 31 days to sell those shares that have a loss. A potential drawback of this strategy is that it can increase your market exposure to a given sector and could potentially increase your risk.

In this same situation, an investor may decide to liquidate the holding, recognize the loss, and then immediately buy a similar investment that will also satisfy their investment goals or portfolio allocation. For example, an investor may decide to sell their stock of The Coca-Cola Company (KO) and then immediately purchase a similar investment of PepsiCo, Inc. (PEP).

Similarly, an investor may decide to sell their shares of the Vanguard 500 Index Fund (VFIAX) and replace them by purchasing shares of the Vanguard Total Stock Market ETF (VTI).

How Do Traders Avoid Wash Sales?

A wash sale occurs when a stock or security is sold at a loss and another identical or like-kind stock of security is purchased within 30 days, before and after the sale. To avoid a wash sale, the investor can wait more than 30 days from the sale to purchase an identical or substantially-identical investment or invest in exchange-traded or mutual funds with similar investments to the one sold. Another method for avoiding wash sales includes purchasing shares of the targeted investment and waiting more than 30 days to sell the ones that incurred losses.

How Long Do You Have to Wait to Avoid a Wash Sale?

The wash-sale period is 61 days, 30 days prior to and 30 days after an investment is sold at a loss and replaced with an identical asset. To avoid a wash sale, the transaction should occur outside of this period. For example, if the purchase of a security occurs 45 days after the sale of an identical or considerably identical security at a loss, a wash sale has not occurred.

Are Wash Sales Gone Forever?

Losses from wash sales may not be forgone forever. The initial loss is added to the cost basis of the new investment. When that investment is eventually sold or traded, gains or losses will be determined from the modified cost basis. However, when a non-retirement account is sold at a loss and identical shares are purchased in an IRA within 30 days, losses cannot be deferred. In other words, the loss is gone.

Article Sources
Investopedia requires writers to use primary sources to support their work. These include white papers, government data, original reporting, and interviews with industry experts. We also reference original research from other reputable publishers where appropriate. You can learn more about the standards we follow in producing accurate, unbiased content in our editorial policy.
  1. Internal Revenue Service. "Publication 550: Investment Income and Expenses," Pages 43 and 66.

  2. Internal Revenue Service. "Publication 550: Investment Income and Expenses," Pages 56-57.

  3. Internal Revenue Service. "Instructions for Form 1099-B: Proceeds from Broker and Barter Exchange Transactions," Page 10.

  4. Internal Revenue Service. "Topic No. 409: Capital Gains and Losses."

  5. Internal Revenue Service. "Publication 559: Survivors, Executors, and Administrators," Page 7.