TAX RULES Must Know

Wash Sale Rule Explained

The wash sale rule can turn your tax-loss harvesting strategy into a tax nightmare. Here's how it works, what triggers it, and how to avoid costly mistakes.

The Wash Sale Rule in One Sentence

If you sell a security at a loss and buy the same or "substantially identical" security within 30 days before or after the sale, you cannot claim that loss on your taxes.

What Is the Wash Sale Rule?

The wash sale rule (IRS Section 1091) prevents investors from claiming artificial tax losses. The IRS doesn't want you selling a stock on December 30 to harvest a tax loss, then buying it back on January 2 while maintaining essentially the same investment position.

The rule creates a 61-day window around any sale at a loss: 30 days before, the sale day, and 30 days after. If you acquire a substantially identical security during this window, the loss is disallowed.

The 61-Day Window Explained

The wash sale window works like this:

  • 30 days BEFORE the sale at a loss
  • The day of the sale
  • 30 days AFTER the sale at a loss

This catches both obvious tactics (selling then immediately rebuying) and less obvious ones (buying more shares right before selling your losing position).

Example: Post-Sale Wash Sale

  • December 15: Sell Apple at $10,000 loss
  • January 5: Buy Apple back (21 days later)
  • Result: Wash sale—loss disallowed

Example: Pre-Sale Wash Sale

  • December 1: Buy more Apple shares
  • December 20: Sell original Apple shares at $10,000 loss (19 days later)
  • Result: Wash sale—loss disallowed

What Triggers a Wash Sale?

Buying the Same Stock

The most obvious trigger. Sell Tesla at a loss, buy Tesla within 30 days = wash sale.

Buying Options on the Same Stock

Options are considered substantially identical. Sell Apple stock at a loss, buy Apple call options within 30 days = wash sale.

Purchases in Any Account

The wash sale rule looks across ALL your accounts—brokerage, IRA, Roth IRA, 401(k), even your spouse's accounts. Selling Tesla at a loss in your brokerage account and buying Tesla in your IRA within 30 days = wash sale.

Dividend Reinvestment (DRIP)

Automatic dividend reinvestment counts as a purchase. If your DRIP buys shares within the 30-day window around a loss sale = wash sale. This catches many investors off-guard.

Substantially Identical Securities

The trickiest area. "Substantially identical" isn't precisely defined, but generally:

  • Same stock or bond = substantially identical
  • Options on the same stock = substantially identical
  • ETFs tracking the same index = probably substantially identical (gray area)
  • Different companies in the same sector = NOT substantially identical

What Happens When You Trigger a Wash Sale?

The loss isn't permanently lost—it's deferred. Here's what happens:

  1. Your loss is disallowed for the current tax year
  2. The disallowed loss is added to the cost basis of your replacement shares
  3. Your holding period carries over
  4. When you eventually sell the replacement shares (without triggering another wash sale), you'll recognize the deferred loss

Example: Wash Sale Basis Adjustment

  • Buy 100 shares at $50 = $5,000 cost basis
  • Sell at $40 = $4,000, creating $1,000 loss
  • Within 30 days, buy 100 shares at $42 = $4,200
  • Wash sale triggered: $1,000 loss disallowed
  • New cost basis: $4,200 + $1,000 = $5,200
  • If you later sell at $60 = $6,000, your gain is $800 (not $1,800)

The loss is eventually recovered through the higher cost basis, but you lose the immediate tax benefit.

Substantially Identical: The Gray Areas

ETFs Tracking the Same Index

Is SPY (tracks S&P 500) substantially identical to VOO (also tracks S&P 500)? The IRS hasn't explicitly ruled, but most tax professionals believe they ARE substantially identical because they track the exact same index.

Conservative approach: Treat same-index ETFs as substantially identical.

Different Index ETFs

SPY (S&P 500) vs. VTI (Total Market)? Probably NOT substantially identical because VTI includes small and mid-cap stocks that SPY doesn't. But there's significant overlap.

This is where tax-loss harvesting gets creative. Swap between different-but-similar investments to harvest losses while maintaining market exposure.

Mutual Fund vs. ETF of Same Index

VFIAX (S&P 500 mutual fund) vs. VOO (S&P 500 ETF)? Same index, different structure. Most experts consider these substantially identical.

Individual Stocks vs. Sector ETFs

Selling Apple at a loss and buying XLK (Technology Select Sector ETF that includes Apple)? This is a gray area. Conservative view: might trigger wash sale because Apple is a component. Aggressive view: probably okay because XLK holds many other stocks.

How to Avoid Wash Sales

Wait 31 Days

The simplest approach. Sell at a loss, wait 31 days, then buy back if you still want the position. Risk: the stock could move significantly during this time.

Buy Similar But Not Identical Securities

Instead of waiting, immediately buy a similar investment that isn't substantially identical:

  • Sell individual stock → Buy sector ETF (excluding that stock)
  • Sell S&P 500 ETF → Buy Total Market ETF
  • Sell one growth fund → Buy different growth fund with different holdings
  • Sell Apple → Buy Microsoft (different company, same sector)

Turn Off DRIP Before Selling

Before selling a losing position, disable dividend reinvestment for that security. Otherwise, a dividend paid within 30 days could trigger a wash sale through automatic reinvestment.

Coordinate Across Accounts

Remember that purchases in ANY account (including IRAs and spouse's accounts) can trigger wash sales. If you're selling Tesla at a loss in your brokerage, make sure your IRA isn't buying Tesla and your spouse isn't buying Tesla either.

Wash Sales and IRAs: A Special Problem

Here's a particularly nasty scenario: You sell a stock at a loss in your taxable brokerage account, and within 30 days, you (or your IRA) buy the same stock.

The wash sale rule applies, but here's the problem: when the replacement purchase is in an IRA, you can NEVER recover the disallowed loss. The basis adjustment goes into the IRA, where basis doesn't matter for tax purposes.

This is effectively a permanent loss of the tax benefit. Be especially careful about this scenario.

How Brokers Report Wash Sales

Your broker tracks wash sales within that broker and reports them on your 1099-B. However, brokers typically can't track wash sales across different brokers or between spouses' accounts.

You're responsible for tracking cross-account and cross-broker wash sales yourself. If you don't, and the IRS catches it, you could face penalties and interest.

Wash Sales and Cryptocurrency

As of 2025, the wash sale rule technically applies only to securities (stocks, bonds, ETFs). Cryptocurrency is treated as property, not a security, so the wash sale rule historically didn't apply to crypto.

However, this is changing. Recent legislation and IRS guidance may extend wash sale rules to crypto. Check current rules before assuming crypto is exempt.

Tax-Loss Harvesting Done Right

Despite wash sale complexity, tax-loss harvesting remains valuable. Here's the right approach:

  1. Identify positions with unrealized losses
  2. Turn off DRIP for those positions
  3. Sell to realize the loss
  4. Immediately buy a similar-but-not-identical replacement
  5. Wait 31 days if you want the original security back
  6. Track across all accounts including spouse's
  7. File proper tax forms

The Bottom Line

The wash sale rule exists to prevent gaming the tax system, but it creates real complexity for investors trying to manage taxes legitimately. The key points:

  • 61-day window: 30 days before, sale day, 30 days after
  • Applies across ALL accounts including IRAs and spouse's accounts
  • Disallowed loss isn't gone—it's added to replacement cost basis
  • BUT: if replacement is in IRA, loss may be permanently lost
  • Avoid by waiting 31 days or buying similar-but-not-identical securities
  • Turn off DRIP before harvesting losses

When in doubt, consult a tax professional. The wash sale rule has nuances that can cost thousands in unexpected taxes.

Learn More About Tax Strategies

Tax-loss harvesting can save you thousands when done right.

Tax-Loss Harvesting Guide →