This article reflects federal tax rules as of June 2026 and covers tax year 2025 (the 2026 filing season). State conformity is addressed in its own section. Tax law changes — confirm current figures with IRS.gov or a licensed professional before you file.
Quick Answer
You must wait 31 days to safely rebuy the same or a “substantially identical” security after selling it at a loss. The wash sale rule blocks the loss if you repurchase within 30 days before or after the sale — a 61-day window in total — so the first clean buy day is day 31 after you sell.
The Wait Is 31 Days — Here’s Why
To keep your tax loss, you must avoid buying the same security from 30 days before your sale through 30 days after it. The cleanest move is to wait until the 31st day after the sale date to repurchase. This is the single most important fact most investors get wrong, and getting it wrong costs you a current-year deduction.
That 61-day trap matters most at year-end, when investors rush to “harvest” losses before December 31 to lower their tax bill. The Securities and Exchange Commission warns that the rule reaches across all your accounts — including your IRA and your spouse’s accounts — so a single careless rebuy can erase the deduction you were counting on.
Here is what you will learn in this guide:
- 📅 The exact 61-day window, and why “30 days” really means a 31-day wait.
- 💰 A fully worked example showing how a disallowed loss is deferred, not destroyed.
- ⚠️ The IRA trap that can destroy a loss permanently instead of deferring it.
- ₿ Where crypto, options, and mutual funds fit (the rules differ a lot).
- 📝 How to report a wash sale on Form 8949 with code “W,” step by step.
What the Wash Sale Rule Actually Says
The wash sale rule lives in Internal Revenue Code Section 1091. In plain words, it disallows a loss deduction when you sell stock or securities at a loss and buy “substantially identical” stock or securities within a set period around that sale. The IRS explains the practical version of this rule in Publication 550, Chapter 4.
The window runs from 30 days before the sale to 30 days after the sale. Counting the sale day itself, that is a 61-day span. Because the last “bad” day is 30 days after the sale, the first safe day to rebuy is day 31.
The consequence of breaking the rule is direct: your loss is disallowed for the current year. You do not lose the loss forever in a normal taxable account — it gets added to the cost basis of your new shares. But you lose the timing benefit, which is often the whole point of selling at a loss in the first place.
A common misconception is that the rule only looks forward. It does not. Buying the replacement shares in the 30 days before you sell also triggers it, which trips up investors who add to a position and then sell their older, higher-cost lot.
What you should do about it: mark your calendar from the sale date, count 30 days forward, and treat day 31 as your earliest clean rebuy date. Keep a screenshot of your trade confirmations so you can prove the dates if the IRS asks.
What “Substantially Identical” Means
“Substantially identical” is the phrase that decides whether two investments are treated as the same thing. The same company’s common stock is clearly identical to itself. Selling Apple and rebuying Apple is a textbook wash sale.
The harder cases involve funds. The IRS has never published a bright-line list, but the widely accepted view is that two index funds tracking the same index (for example, two S&P 500 funds) are likely substantially identical, while funds tracking different indexes usually are not. Selling a total-market fund and buying a large-cap fund is generally treated as a swap into a non-identical security.
The consequence of guessing wrong is a disallowed loss you thought you had locked in. The fix is to swap into a clearly different fund — a different issuer tracking a different index — so you keep market exposure without tripping the rule. When in doubt, ask a CPA before the trade, not after.
The 61-Day Window, Counted Out
The window has three parts, and missing any one of them costs you the deduction. Counting carefully is the whole game here.
- 30 days before the sale: any purchase of identical shares in this period can be matched to your loss sale.
- The sale date: day zero, the day you realize the loss.
- 30 days after the sale: the danger zone most people forget about.
Say you sell at a loss on March 1. Count 30 days forward, and March 31 is the last “tainted” day. April 1 — day 31 — is your first clean buy day. If you buy back even one share on March 30, the rule applies.
Deferred, Not Destroyed: A Worked Example
In a normal taxable account, a wash sale does not delete your loss. Under Section 1091(d), the disallowed loss is added to the cost basis of the replacement shares, and the old holding period carries over. You get the benefit later, when you finally sell the replacement shares.
Meet Maria, a Vilnius-born U.S. investor filing for tax year 2025. She bought 100 shares of XYZ at $50 ($5,000 total). She sells all 100 on March 1 at $40 ($4,000), realizing a $1,000 loss. On March 20 — only 19 days later — she rebuys 100 shares of XYZ at $42 ($4,200).
Here is the math, step by step:
- Loss realized on the March 1 sale: $5,000 − $4,000 = $1,000.
- Because she rebought within 30 days, that $1,000 loss is disallowed for 2025.
- The $1,000 is added to the basis of her new shares: $4,200 + $1,000 = $5,200 adjusted basis.
- Her holding period from the original lot carries over to the new shares.
So Maria’s $1,000 is not gone. When she eventually sells the replacement shares, her higher $5,200 basis means a smaller future gain (or a larger future loss). She simply cannot use the loss in 2025. Had she waited until day 31 (April 1) to rebuy, she could have claimed the full $1,000 loss this year.
The IRA Trap: When the Loss Is Gone Forever
The IRA scenario is the one true “destroyed” case, and it is brutal. Publication 550 and IRS guidance treat a purchase of substantially identical shares in your traditional IRA or Roth IRA as a wash sale trigger when you sell the same security at a loss in your taxable account.
Here is why it is worse than a normal wash sale. In a taxable account, the disallowed loss moves to the basis of the replacement shares. But you have no cost basis to adjust inside an IRA the way you do in a taxable account — so the disallowed loss is simply lost. There is no later recovery.
Meet David. On June 10, 2025, he sells 200 shares of a tech ETF in his brokerage account at a $3,000 loss. On June 20, his Roth IRA auto-invests his monthly contribution into that same ETF. The wash sale rule applies, the $3,000 loss is disallowed, and because the buy happened inside the Roth, that $3,000 deduction is gone permanently.
What David should do: turn off automatic investing in retirement accounts during any 61-day window where he is harvesting losses on the same fund in a taxable account. This single habit prevents the most expensive wash sale mistake there is.
The Spouse Trap and Other Related Accounts
The rule follows your household, not just your login. If you sell at a loss and your spouse buys the same security within the window, the IRS can treat it as your wash sale. The same applies to a company you control.
Meet Priya and Sam, married filing jointly for 2025. Priya sells 500 shares of a fund at a $4,000 loss on October 5. On October 15, Sam — in his own separate brokerage account — buys 500 shares of the same fund. The loss is disallowed because they are a married couple and the purchase falls inside the 30-day window.
What they should do: coordinate harvesting trades as a household. Before either spouse sells at a loss, both should agree not to buy that security (in any account, taxable or retirement) for 31 days.
Which Situation Applies to You?
The right move depends on what you hold and where. Use this to jump to the part that fits you.
- You hold individual stocks or ETFs in a taxable account: the standard 31-day wait applies; rebuy on day 31 or swap into a non-identical fund.
- You also have an IRA or 401(k): turn off auto-invest in those accounts during the window — an IRA wash sale destroys the loss for good.
- You are married: treat the household as one — your spouse’s buys count against your loss.
- You trade cryptocurrency: as of tax year 2025, the wash sale rule does not apply to crypto — see the crypto section below.
- You trade options or sell short: Section 1091 reaches contracts and options too; the same 61-day logic applies.
Stocks, ETFs, and Mutual Funds
For individual stocks and ETFs, the rule is straightforward: same ticker, same security. Sell Coca-Cola at a loss and rebuy Coca-Cola within 30 days, and the loss is disallowed.
Mutual funds add a year-end wrinkle. Reinvested dividends and capital-gain distributions count as purchases. If your fund reinvests a distribution within 30 days of your loss sale of that same fund, even that small automatic buy can trigger a partial wash sale. Turning off automatic reinvestment during a harvesting window prevents this surprise.
The smart workaround across all three is the “swap.” You sell the losing fund and immediately buy a similar-but-not-identical fund — a different issuer tracking a different index — so your money stays invested while the 31-day clock runs. After day 31, you can switch back if you want.
Options and Short Sales
Section 1091(a) explicitly extends “stock or securities” to include contracts or options to acquire or sell them. So buying a call option on a stock you just sold at a loss can trigger the rule, because the option is treated as a way to reacquire the position.
Section 1091(e) applies similar rules to losses on closing a short sale. The same 61-day window logic applies. Active traders should be especially careful, because overlapping option and stock trades can quietly stack disallowed losses across a year.
Crypto: The Current Loophole
As of tax year 2025, the wash sale rule does not apply to cryptocurrency. The IRS classifies crypto as property, not as a “security” under Section 1091, so the 61-day window does not reach it. This is widely confirmed by tax practitioners, including coverage from Yahoo Finance on crypto wash sales.
This means a crypto holder can sell Bitcoin at a loss, claim the loss, and rebuy Bitcoin minutes later — something a stock investor cannot do. It is a genuine timing advantage that does not exist for securities.
Two important cautions. First, this is unsettled and politically contested; lawmakers have repeatedly proposed closing the gap, and it could change in a future law, so confirm the rule for the year you actually file. Second, crypto exchange-traded products (such as a spot-Bitcoin ETF) are securities, so the wash sale rule does apply to those, even though it does not apply to the coin itself.
How to Report a Wash Sale on Form 8949
When a wash sale happens, you report it on Form 8949 and carry the totals to Schedule D. Your broker usually flags the disallowed amount in Box 1g of your Form 1099-B. Here is the walkthrough:
- List the sale on Form 8949, Part I (short-term) or Part II (long-term), depending on how long you held the shares.
- Enter your proceeds in column (d) and your cost basis in column (e).
- Enter code “W” in column (f) to flag the wash sale.
- Enter the disallowed loss as a positive number in column (g), the adjustments column.
- The adjustment reduces the loss you can claim, and column (h) shows the corrected gain or loss.
The deadline is your normal return due date — April 15, 2026, for tax year 2025, or October 15, 2026, with an extension. Missing or mis-coding a wash sale can trigger an IRS notice (a CP2000) when your reported numbers do not match the 1099-B the broker sent the IRS.
If you have many trades, are an active trader, or are weighing a mark-to-market election, this is the point to hire a CPA or enrolled agent. Expect roughly $300–$800 for a return with significant trading activity, far less than the cost of a mishandled audit.
Three Common Scenarios
Scenario 1 — Rebuying too soon in the same account.
| What You Do | What Happens |
|---|---|
| Sell ABC at a $2,000 loss, rebuy ABC 10 days later | Loss disallowed for the year; $2,000 added to the new shares’ basis |
Scenario 2 — Rebuying inside your IRA.
| What You Do | What Happens |
|---|---|
| Sell ABC at a $2,000 loss in taxable, IRA buys ABC within 30 days | Loss disallowed and permanently lost — no basis to adjust |
Scenario 3 — Swapping into a non-identical fund.
| What You Do | What Happens |
|---|---|
| Sell an S&P 500 fund at a loss, buy a total-market fund from a different issuer | Loss is allowed; you keep market exposure and the deduction |
Federal vs. State: Does Your State Follow This?
| Level | How the Wash Sale Rule Is Treated |
|---|---|
| Federal | Section 1091 applies: loss disallowed in the 61-day window; basis adjusted in taxable accounts |
| Most states with income tax | Start from federal taxable income, so they generally follow the federal wash sale treatment automatically |
| No-income-tax states (e.g., Florida, Texas, Washington) | No state tax on investment gains or losses, so the wash sale rule has no state-level effect for you |
Most states that tax income begin their calculation with your federal adjusted gross income or federal taxable income, so the federal wash sale adjustment usually flows straight through to your state return. A handful of states have their own quirks and decoupling provisions, so check your state’s department of revenue if you are unsure. If you live in a state with no income tax, the wash sale rule only matters for your federal return.
Mistakes to Avoid
- Counting only forward. The window also covers 30 days before the sale; an earlier add-on purchase can taint a later loss.
- Rebuying on day 30 instead of day 31. Day 30 is still inside the window; the loss is disallowed.
- Forgetting your IRA. A retirement-account buy destroys the loss permanently instead of deferring it.
- Forgetting your spouse. A married couple is treated as one; your spouse’s buy counts against your loss.
- Leaving dividend reinvestment on. An automatic reinvested distribution is a purchase that can trigger a partial wash sale.
- Assuming two index funds are different. Two funds tracking the same index may be “substantially identical,” disallowing the loss.
- Treating a crypto ETF like crypto. The coin is exempt for 2025, but a crypto ETF is a security and is not exempt.
- Skipping code “W” on Form 8949. Mis-reporting invites an IRS CP2000 notice when broker data does not match your return.
Do’s and Don’ts
Do’s
- Do wait until day 31 to rebuy, because day 30 is still inside the disallowed window.
- Do turn off auto-invest and reinvestment during a harvesting window, because automatic buys count as purchases.
- Do swap into a non-identical fund if you want to stay invested, because that keeps both your exposure and your loss.
- Do coordinate with your spouse, because the IRS treats your household as one taxpayer for this rule.
- Do keep trade confirmations, because you may need to prove your sale and rebuy dates.
Don’ts
- Don’t rebuy in your IRA, because the loss is destroyed forever, not just deferred.
- Don’t assume crypto rules are permanent, because Congress has tried to close the gap and may succeed.
- Don’t guess on “substantially identical,” because a wrong guess silently disallows your loss.
- Don’t ignore Box 1g on your 1099-B, because that is your broker flagging a wash sale.
- Don’t harvest a loss the same week as a planned rebuy, because tight timing is what triggers the rule.
Pros and Cons of the Wash Sale Rule
Pros (for the taxpayer’s planning)
- The loss is preserved in taxable accounts, because it shifts to the new shares’ basis rather than vanishing.
- The holding period tacks on, because the old period carries to the replacement shares, helping long-term status.
- It is avoidable with planning, because a 31-day wait or a fund swap sidesteps it entirely.
- Crypto is currently exempt, because the IRS does not classify it as a security for 2025.
- Brokers track it for you, because Form 1099-B flags wash sales automatically.
Cons
- You lose the current-year deduction, because the timing benefit you wanted is deferred.
- The IRA version is permanent, because there is no basis to absorb the loss.
- It is easy to trip accidentally, because reinvested dividends and spouse trades count.
- “Substantially identical” is vague, because the IRS gives no bright-line fund list.
- It complicates active trading, because overlapping trades can stack disallowed losses.
What to Do Next
- Find your sale date and count 30 calendar days forward; circle day 31 as your earliest clean rebuy date.
- Check every account — taxable, IRA, Roth, and your spouse’s — for any buy of that security inside the window.
- Turn off auto-invest and dividend reinvestment on that security for the full 61-day period.
- If you must stay invested, swap into a similar-but-not-identical fund from a different issuer.
- Gather your 1099-B and report any wash sale on Form 8949 with code “W.”
- Call a CPA or enrolled agent if you trade heavily, hold complex positions, or get an IRS notice.
This guide is educational and is not a substitute for personalized advice from a licensed tax professional for your specific situation.
FAQs
How long do I have to wait to rebuy after a wash sale? 31 days. The disallowed window is 30 days before and 30 days after the sale, so the first safe day to repurchase the same security is the 31st day after your loss sale.
Does the 30-day rule count calendar days or trading days? Calendar days. Section 1091 counts all calendar days, including weekends and holidays — not trading days. Count 30 calendar days from the sale date and rebuy on day 31.
Is the loss gone forever after a wash sale? No. In a taxable account the disallowed loss is added to the basis of your replacement shares, so you recover it when you sell those shares. The exception is an IRA, where it is lost.
Does the wash sale rule apply to cryptocurrency? No, for tax year 2025. The IRS treats crypto as property, not a security, so the rule does not apply. But crypto ETFs are securities and the rule does apply to them.
Can I rebuy in my IRA to avoid the wash sale? No. Buying the same security in your IRA or Roth IRA still triggers the rule, and worse, the disallowed loss is permanently destroyed with no basis to recover it.
Does my spouse’s purchase trigger my wash sale? Yes. The IRS treats a married couple as one taxpayer for this rule, so your spouse buying the same security within the window disallows your loss.
Can I sell at a loss and buy a similar (not identical) fund? Yes. Swapping into a fund that tracks a different index from a different issuer is a common, legal way to keep market exposure and still claim the loss.
What is the 61-day window? It is the full danger zone: 30 days before the sale, the sale day, and 30 days after — 61 days total. Any matching purchase in that span triggers the rule.
How do I report a wash sale on my tax return? On Form 8949 with code “W.” Enter the disallowed loss as a positive number in column (g), then carry the totals to Schedule D of your Form 1040.
Does the wash sale rule apply to gains? No. The rule only disallows losses. If you sell at a gain, you owe tax on the gain and can rebuy immediately with no wash sale issue.
Do reinvested dividends cause a wash sale? Yes, they can. A reinvested dividend or capital-gain distribution is treated as a purchase, so it can trigger a partial wash sale if it lands within the 61-day window.
Does my state follow the federal wash sale rule? Usually yes. Most income-tax states start from your federal taxable income, so the federal adjustment flows through. No-income-tax states do not tax the activity at all.
Word count: approximately 2,950 words.
Related reading
- Can a Wash Sale Happen If You Rebuy Before Selling? (w/Examples) + FAQs
- Can a Wash Sale Raise Your Tax Bill? (w/Examples) + FAQs
- Does the Wash Sale Rule Apply to Gains? (w/Examples) + FAQs
- How Do You Tax-Loss Harvest Without a Wash Sale? (w/Examples) + FAQs
- What Happens If You Have a Wash Sale at Year-End? (w/Examples) + FAQs
- What’s the Penalty for a Wash Sale? (w/Examples) + FAQs
- Does a Wash Sale Make You Lose the Loss Forever? (w/Examples) + FAQs