A complete guide to understanding the 30-day restriction on tax-loss harvesting, how cost basis adjustments work, and how the rule differs globally.
Key points
- Selling a security at a loss and buying a substantially identical one within 30 days triggers the wash sale rule.
- Disallowed losses are not lost forever; they are added to the cost basis of your replacement shares.
- The restriction applies across all your brokerage accounts and IRAs, making manual tracking essential.
- Investors can avoid restrictions by waiting 31 days or buying similar yet non-identical funds.
When you sell an investment for less than you paid for it, the tax code usually lets you use that loss to offset capital gains. However, tax authorities established the wash sale rule to prevent investors from selling assets purely on paper to lower their tax bills while immediately buying them back. Understanding this regulation is essential for anyone practicing tax-loss harvesting in a taxable brokerage account.
How the 30-Day Window Works
The restriction creates a 61-day window around the date of your sale: 30 days before, the day of the sale, and 30 days after. If you sell a security at a loss and purchase that same security—or a “substantially identical” one—within this timeframe, your capital loss is disallowed by the IRS for current tax reporting.
Crucially, the rule applies if you buy the replacement asset before selling the losing position, as well as after. The restriction also sweeps across all accounts you own, including traditional and Roth IRAs, meaning you cannot sell a stock at a loss in a brokerage account and buy it back inside an individual retirement account within the window.
What Happens to Disallowed Losses
A disallowed loss is not permanently erased from your financial life. Instead, the disallowed loss amount is added to the cost basis of your newly purchased replacement shares. This adjustment increases your cost foundation, which ultimately reduces your future capital gains (or increases your future capital losses) when you eventually sell those new shares.
While this preserves the economic value of your loss, it delays your tax benefit. Investors looking for immediate tax deductions in the current year must be careful not to inadvertently trigger this adjustment near the end of December.
Step-by-Step Ways to Avoid Violations
Investors can structure their portfolios to harvest losses without running afoul of regulatory limits. Here are the standard methods:
- Wait 31 days: Sell your losing position and wait a full 31 days before repurchasing the exact same security. Note that market prices can move significantly during this month-long gap.
- Buy a similar asset: Sell an exchange-traded fund (ETF) that tracks a specific index and immediately buy a different fund that tracks a broad, comparable index but is managed by a different provider or follows a different benchmark.
- Double-check all accounts: Review spousal accounts and separate brokerages to ensure automatic dividend reinvestment plans are not quietly purchasing identical shares inside the 30-day window.
International Perspectives on Tax-Loss Selling
While the United States enforces strict 30-day guidelines through tax codes, rules vary globally. For instance, India does not have an explicit statutory wash sale rule written into its income tax act. However, Indian tax authorities actively scrutinize artificial transactions, cyclical trades, and obvious loss-harvesting round-trips designed solely to manipulate tax liabilities under general anti-avoidance principles.
Frequently asked questions
Does the rule apply to cryptocurrency? As tax enforcement evolves, regulatory bodies treat various digital assets differently. In the US, traditional securities rules have historically applied to equities and mutual funds, but taxpayers should consult current guidance regarding digital property classifications.
What defines a ‘substantially identical’ security? Buying shares of the exact same company or a nearly identical option contract triggers the rule. Buying a stock from an entirely different company in the same industry generally does not.
Are automated dividend reinvestments risky? Yes. If a dividend automatically buys more shares of a declining stock within 30 days of a manual sale of that same stock, it can trigger a partial wash sale.
This article is for general education and is not investment, tax or financial advice. Rules and figures change — check the official source or a licensed adviser before acting.
Official information: https://www.irs.gov
This explainer is published by the MoneyPuran desk for general awareness. Rules, limits and rates change over time — please confirm with the official source. Corrections: corrections@moneypuran.com


