Avoiding the Wash-Sale Rule
Avoiding the Wash-Sale Rule
The wash-sale rule is the single biggest obstacle to tax-loss harvesting. It prevents investors from claiming a loss and then immediately repurchasing the same investment. Violate it, and the IRS disallows your loss and increases your cost basis in the repurchased security—an outcome far worse than taking no action. Understanding the rule's mechanics and avoiding pitfalls is essential for long-term investors who want to harvest losses systematically.
Quick definition: The wash-sale rule (IRC Section 1091) disallows a capital loss if you sell a security at a loss and purchase the same or a "substantially identical" security within 30 days before or after the sale. The loss is not eliminated; it's deferred by increasing your cost basis in the replacement security until you sell it without repurchasing.
Key Takeaways
- The wash-sale rule applies for 61 calendar days total: 30 days before the sale, the sale date itself, and 30 days after.
- Selling on December 28 and buying on January 5 triggers wash-sale; you must wait until January 30 (or later) to repurchase.
- "Substantially identical" is vague by design, but different securities tracking the same market index are generally acceptable alternatives.
- The loss is not lost; it's deferred. Your cost basis in the replacement security increases, pushing the tax benefit to a future sale.
- Spouses and investment accounts they control are treated as a single taxpayer; your spouse cannot buy the same security within 30 days of your sale without triggering wash-sale for you.
- Careful position documentation and a calendar of harvesting dates prevent costly violations.
The 61-Day Window
The wash-sale rule applies 30 days before the sale date, the sale date itself, and 30 days after the sale date—a total of 61 calendar days. The rule is symmetric around the sale.
If you sell a security on January 15:
- 30 days before: December 16–January 14 (no purchases allowed).
- Sale date: January 15.
- 30 days after: January 16–February 14 (no purchases allowed).
To safely repurchase, you must wait until February 15. Many investors add a week of buffer and repurchase on February 22 to avoid any ambiguity.
The rule applies to the same or substantially identical security. It does not matter if you sell in a taxable account and buy in an IRA, or vice versa—the rule covers all of your accounts. It also does not matter if the purchase is automatic (e.g., dividends reinvested) or manual.
Example: Automated Dividend Reinvestment
You own VTI in a taxable account with dividends set to reinvest automatically. On January 15, you sell VTI at a loss. Your January dividend payment is automatically reinvested in VTI on January 22. This automatic reinvestment triggers wash-sale, disallowing your loss.
To harvest safely with dividends: turn off automatic reinvestment before selling, wait the 30-day window, then reinvest or resume automatic reinvestment.
What Is "Substantially Identical"?
The IRS intentionally keeps this definition vague to maintain enforcement flexibility. However, decades of IRS guidance and case law establish boundaries:
Clearly NOT substantially identical:
- VTI (Vanguard Total Stock Market) vs. VTSAX (Vanguard Total Stock Market mutual fund) — different funds tracking the same index.
- SWTSX (Schwab U.S. Total Stock Market) vs. VTI — different providers, same index.
- US total-market index vs. US large-cap index — different sectors of the market.
- US stocks vs. international stocks — different markets.
- Individual stock vs. sector ETF — different concentration.
- Calls or puts on a stock vs. the stock itself — different instruments.
Clearly ARE substantially identical:
- VTI (at any price) vs. VTI — same security.
- VTI Class A vs. VTI Class B — same fund, different share classes (varies by broker context).
- A single stock (XYZ) vs. XYZ — same security.
Murky gray areas:
- VTI (US total market) vs. a US total-market fund from another provider — generally accepted as non-identical, but tax-aggressive investors might avoid the risk.
- Leveraged index funds (3x VTI) vs. regular VTI — technically different, but the IRS might claim they're substantially identical in economic substance.
To be conservative, harvest VTI and replace with SWTSX or VTSAX (different funds, same index). The IRS has never successfully claimed that different mutual funds tracking the same index are substantially identical.
Spouse and Household Coordination
The wash-sale rule treats you and your spouse as a single taxpayer for purposes of the rule. If you sell a security at a loss and your spouse purchases the same security within the 30-day window, you trigger wash-sale.
This applies even if you file separately and maintain separate accounts. The IRS views a married household as an economic unit for wash-sale purposes.
Implication: In a married household, before harvesting, inform your spouse of the 30-day window. If you sell VTI on January 15, your spouse cannot purchase VTI until February 15 or later in any account—taxable, IRA, 401(k), or otherwise.
This is why many married couples maintain a shared spreadsheet of harvest dates. Mutual funds, ETFs, and brokers increasingly provide wash-sale tracking, but not perfectly—relying on software alone invites errors.
The Mechanics of Deferred Loss (Cost Basis Adjustment)
If you violate wash-sale, the loss is not eliminated. Instead, the IRS disallows the deduction on your current-year tax return and increases your cost basis in the replacement security.
Example:
- Buy VTI on Jan 1 at $100 per share (1,000 shares, $100,000 cost basis).
- Sell on Dec 15 at $85 per share ($85,000 proceeds, $15,000 loss).
- Buy VTI again on Dec 27 (violates wash-sale, being within 30 days).
IRS treatment:
- Your loss of $15,000 is disallowed this year.
- Your new cost basis in the VTI purchased on Dec 27 becomes $100 per share (the original cost basis) plus the $15,000 loss = $100 per share adjusted.
- This is economically equivalent to never harvesting, but with added complexity: you now have two cost bases to track.
If you later sell the replacement VTI at $90:
- Your gain or loss is calculated from the adjusted cost basis ($100), not the actual purchase price ($85).
- Selling at $90 produces a $10 loss (from the $100 adjusted basis).
- You've deferred the original $15,000 loss until this future sale.
This is why violating wash-sale is worse than taking no action: you incur administrative burden and your loss is delayed rather than eliminated.
Documenting Harvests and Preventing Violations
The best defense against wash-sale violations is a documented plan:
-
Maintain a harvest calendar. Record the date of each loss harvest, the security sold, the loss amount, and the date when repurchase is allowed (sale date + 31 days). Many brokers now provide wash-sale tracking in their tax-loss-harvesting reports, but verify independently.
-
Choose replacement securities in advance. Know which security you'll buy as a replacement before you sell at a loss. For example, plan to sell VTI and buy SWTSX (Schwab's equivalent). This prevents impulsive repurchases.
-
Use automated harvesting platforms. Some robo-advisors and tax software (like Betterment, Wealthfront, or TurboTax) track wash-sale automatically. However, they only manage their own accounts; if you have multiple brokers, you must coordinate manually.
-
Freeze automatic dividend reinvestment. Before harvesting, turn off automatic reinvestment of dividends. Resume it after the 30-day window closes or reinvest manually in a different security.
-
Communicate with household members. In a household with multiple investors or a financial advisor, ensure everyone knows which securities are in the harvest window. A spouse's automated 401(k) rebalance can trigger wash-sale if it touches the same security.
Strategies for the Wash-Sale Window
Once you've harvested a loss, you have several options during the 30-day window:
Option 1: Hold Cash Sell at a loss and hold the proceeds in cash or a money-market fund for 31 days. This is simple and eliminates wash-sale risk entirely, but you're out of the market for a month, which can be costly in a rising market.
Option 2: Switch to a Similar but Different Security Sell VTI and immediately buy VTSAX, SWTSX, or another US total-market fund. This maintains market exposure while avoiding wash-sale. This is the standard approach for active investors.
Option 3: Buy a Broader or Narrower Index Sell US total-market (VTI) and buy US large-cap (VOO), or vice versa. This is economically different enough to avoid wash-sale while remaining in equity markets.
Option 4: Use a Sector Rotation Sell US large-cap and buy US small-cap, or US domestic and buy international. Each represents different economic exposure, so wash-sale does not apply.
Option 5: Use Complementary Assets Sell stocks and buy bonds or vice versa. This is more dramatic but eliminates wash-sale risk. However, you've changed your portfolio's risk profile, so rebalance after the 30-day window to restore your intended allocation.
Most investors use Option 2 (switching to a similar but different fund) for equity positions, as it preserves market exposure while harvesting the loss.
Real-World Examples
Scenario 1: Year-End Harvest Avoids Wash-Sale
On December 15, the market falls sharply. An investor reviews their portfolio and identifies $20,000 of losses:
- VTI down 10% from $120 to $108 (2,000 shares, $12,000 loss).
- BND down 8% from $80 to $74 (250 shares, $1,500 loss).
- Emerging market fund down 15% (7,000 loss).
The investor:
- Sells VTI on Dec 20, buys SWTSX on the same day. Not wash-sale (SWTSX is a different fund).
- Sells BND on Dec 20, buys VBTLX on the same day. Not wash-sale (different fund).
- Sells the emerging-market fund on Dec 20, buys a different emerging-market fund.
- Total loss harvested: $20,000. Tax benefit in 24% bracket: $4,800.
Because all sales and repurchases occur in December, with no later repurchases within 30 days, no wash-sale applies. The investor captures the full loss and invests the proceeds immediately.
Scenario 2: Wash-Sale Violation During Rebalancing
On January 10, a portfolio manager harvests a $10,000 loss in VXUS (international) and immediately reinvests in IEMG (another international fund).
On January 20, the portfolio needs rebalancing due to new contributions. The manager, not remembering the harvest, buys VXUS directly to top up the international position.
The second purchase of VXUS on January 20 triggers wash-sale (within 30 days of the January 10 sale). The IRS disallows the $10,000 loss and increases the cost basis of the VXUS bought on January 20 by $10,000.
Had the manager documented the harvest on a calendar or spreadsheet, this violation would have been caught. This error costs $2,400 (at 24% bracket) in taxes now, plus the administrative burden of tracking the deferred loss.
Scenario 3: Coordinating Across Accounts
A married couple both invest in their taxable accounts. On November 1, the wife sells VTI at a loss in her account and buys SWTSX.
On November 15, the husband automatically receives a dividend reinvestment in his VTI position (within 30 days of the wife's sale). This reinvestment triggers wash-sale for the wife's harvest, disallowing her loss, because the household is treated as a single unit.
To avoid this, the couple should have coordinated: the wife notifies the husband of her harvest, and he temporarily disables dividend reinvestment or reinvests in a different fund.
Common Mistakes
1. Forgetting that spouses' actions trigger your wash-sale. The household is a unit. Your spouse's purchase nullifies your harvest.
2. Repurchasing the same security "just a few days early." If you harvest on January 15 and repurchase on January 30 (thinking 14 days is safe), you're still within the 30-day window. Wait until February 15 or later.
3. Assuming different share classes are not substantially identical. VTI Class A and VTI Class B might be treated as the same for wash-sale purposes. To be safe, switch to a different fund entirely.
4. Harvesting and forgetting the window. You harvest a loss on December 20, then rebalance on January 10 and automatically rebuy the same security. Document harvests in a calendar; set reminders.
5. Using sector rotation as wash-sale avoidance without understanding the economic difference. Selling US large-cap and buying US small-cap avoids wash-sale, but your portfolio now has different risk characteristics. Only use this strategy if the rotation aligns with your intended allocation.
FAQ
Q: Can I buy a mutual fund and an ETF tracking the same index without wash-sale? A: Almost certainly yes. VTI (ETF) and VTSAX (mutual fund) both track the US total stock market but are different securities. The IRS has never successfully challenged a harvest where the investor switched between different funds of the same index. To be conservative, some advisors wait the 30-day window anyway, but most practitioners accept the switch as safe.
Q: Does wash-sale apply to bond positions? A: Yes, fully. If you sell a bond at a loss and buy a bond of the same issuer within 30 days, wash-sale applies. However, buying a bond from a different issuer or different maturity generally avoids wash-sale.
Q: Can I harvest a loss in my taxable account and repurchase in my IRA within 30 days? A: No. The wash-sale rule applies across all accounts. Your taxable account sale triggers wash-sale if you (or your spouse) repurchase the same security in an IRA, 401(k), or any account within 30 days.
Q: If I violate wash-sale, can I recover the loss by selling the replacement security later? A: The loss is deferred, not eliminated. When you sell the replacement security, your cost basis is adjusted upward by the original loss. If you sell at a gain or loss, the adjusted basis is used. The original loss is captured at that future sale, not immediately.
Q: Does wash-sale apply to foreign stocks or international funds? A: Yes. Selling an international fund or foreign stock at a loss and repurchasing a substantially similar fund or stock within 30 days triggers wash-sale.
Q: How do I track wash-sale compliance across multiple brokers? A: Most brokers separately report wash-sale losses on your tax documents. However, if you have accounts at multiple brokers, you must manually track and coordinate. Spreadsheets or tax software can help. Better yet, consolidate accounts to a single broker if possible.
Related Concepts
- Capital loss: A loss realized from selling a security for less than its cost basis; can offset gains or ordinary income.
- Cost basis: The original purchase price of a security, adjusted for wash-sale deferrals or other IRS adjustments.
- Substantially identical: Securities that are economically the same or very similar from an IRS perspective; repurchasing substantially identical securities triggers wash-sale.
- Tax-loss harvesting: The practice of selling losing positions to capture deductible losses while maintaining market exposure through different securities.
- Holding period: The time a security is held, which determines whether gains are long-term (held >1 year, favorably taxed) or short-term (taxed as ordinary income).
Summary
The wash-sale rule is a critical constraint on tax-loss harvesting, but it is manageable with discipline and planning. The 30-day window (61 days total including 30 before and 30 after the sale) requires either waiting before repurchasing or switching to a substantially different security.
The key to success is documentation: maintain a harvest calendar, choose replacement securities in advance, and coordinate with household members. Different mutual funds tracking the same index are generally safe replacements, avoiding wash-sale while maintaining market exposure.
Violations are costly not because the loss is eliminated, but because it is deferred. Your cost basis is adjusted upward, delaying the tax benefit to a future sale and creating administrative complexity. Plan carefully to avoid this outcome.
For long-term investors harvesting systematically over decades, respecting the wash-sale rule is a small price for tax savings that compound into substantial wealth accumulation.
Next
Read the next article: Tax-Gain Harvesting