Wash Sale Calculator 2026 | IRS Rule | Free Tool

Calculate wash sale disallowed losses instantly! Free 2026 IRS wash sale calculator with 30-day rule, adjusted cost basis & tax impact. Plan smarter trades now.

๐Ÿ”„ Wash Sale Calculator

Calculate Disallowed Losses & Adjusted Cost Basis

IRS Wash Sale Rule | 30-Day Window | By: OmniCalculator.Space

โš ๏ธ What is a Wash Sale?

A wash sale occurs when you sell a security at a loss and buy the same or "substantially identical" security within 30 days before or after the sale. The IRS disallows the loss deduction, but it's added to the cost basis of the replacement shares.

๐Ÿ“Š Understanding the Wash Sale Rule

The wash sale calculator helps investors determine the tax impact of selling securities at a loss and repurchasing them within the IRS's 61-day wash sale window (30 days before, sale date, 30 days after) for 2026. Under IRC Section 1091, losses on wash sales are disallowed as tax deductionsโ€”but they're not lost forever. The disallowed loss gets added to your cost basis of the replacement shares, effectively deferring the deduction. Whether you're tax-loss harvesting, rebalancing your portfolio, or accidentally triggered a wash sale, this calculator shows your exact disallowed amount, adjusted cost basis, and the timing required to avoid the rule.

๐Ÿ“ How to Use the Wash Sale Calculator

  1. Enter Shares Sold: Input the number of shares you sold at a loss. This is the original lot you're selling to realize the capital loss.
  2. Enter Sale Price & Cost Basis: Input the sale price per share and your original purchase price (cost basis). The difference determines your capital loss.
  3. Enter Sale Date: The date you sold the shares. This establishes the 30-day window before and after for wash sale detection.
  4. Enter Replacement Shares: Input the number of shares you repurchased and the price paid. If you bought fewer shares than you sold, only a proportional loss is disallowed.
  5. Enter Repurchase Date: If this date is within 30 days of the sale date (before OR after), a wash sale is triggered.
  6. Click Analyze: View whether a wash sale occurred, the disallowed loss amount, your new adjusted cost basis, and the 30-day window visualization.
๐Ÿ’ก Tip: The wash sale rule also applies if your spouse or your IRA buys the same security during the 61-day window. For IRA purchases, the disallowed loss is permanently lostโ€”not added to basis!
๐Ÿงฎ Calculate Wash Sale Impact
๐Ÿ“‰ Sale at Loss (Sold Shares)
What you paid per share
๐Ÿ“ˆ Repurchase (Replacement Shares)
Within 30 days before or after sale = wash sale
โš ๏ธ
Wash Sale Triggered
Your loss is disallowed but added to replacement cost basis
Total Loss
$0
Disallowed
$0
Deductible
$0
Days Apart
0
Loss Calculation$0
Shares Sold0
Sale Proceeds$0
Original Cost Basis$0
Capital Loss-$0
Adjusted Cost Basis (Replacement)$0
Repurchase Price (ร— shares)$0
+ Disallowed Loss Added+$0
New Cost Basis$0
Per Share Adjusted Basis$0

๐Ÿ“… 30-Day Wash Sale Window

30 days before Sale Date 30 days after

๐Ÿ“ Wash Sale Formula & Calculation Method

Capital Loss Calculation

Capital Loss = (Sale Price ร— Shares Sold) โˆ’ (Cost Basis ร— Shares Sold)

The total capital loss is the difference between what you received from the sale and what you originally paid. A negative result indicates a loss; positive indicates a gain.

Disallowed Loss (Wash Sale)

Disallowed Loss = Total Loss ร— (Replacement Shares รท Shares Sold)

If you repurchase fewer shares than you sold, only the proportional loss is disallowed. For example, if you sold 100 shares but only repurchased 50, only 50% of the loss is disallowed.

Adjusted Cost Basis (Replacement Shares)

New Cost Basis = Repurchase Cost + Disallowed Loss

The disallowed loss is added to your cost basis of the replacement shares. This means when you eventually sell those shares, you'll have a higher basis, resulting in less taxable gain (or a deductible loss).

๐Ÿ“Š Wash Sale Examples

Example 1: Full Wash Sale

Scenario: Michael sells 100 shares of XYZ at a $500 loss and repurchases 100 shares 5 days later.

Inputs: Sold: 100 shares @ $45 (cost basis $50) | Repurchased: 100 shares @ $43 after 5 days

Calculation:

  • Sale Proceeds: 100 ร— $45 = $4,500
  • Original Cost: 100 ร— $50 = $5,000
  • Capital Loss: $4,500 - $5,000 = -$500
  • Days Apart: 5 (within 30-day window) โ†’ Wash Sale!
  • Disallowed: $500 ร— (100/100) = $500
  • Deductible: $0

Adjusted Basis: $4,300 (repurchase) + $500 (disallowed) = $4,800 ($48/share)

Example 2: Partial Wash Sale

Scenario: Sarah sells 100 shares at a loss but only repurchases 50 shares within the window.

Inputs: Sold: 100 shares @ $30 (cost basis $40) | Repurchased: 50 shares @ $28 after 10 days

Calculation:

  • Sale Proceeds: 100 ร— $30 = $3,000
  • Original Cost: 100 ร— $40 = $4,000
  • Capital Loss: $3,000 - $4,000 = -$1,000
  • Wash Sale Ratio: 50/100 = 50%
  • Disallowed: $1,000 ร— 50% = $500
  • Deductible: $1,000 - $500 = $500

Adjusted Basis: $1,400 (repurchase) + $500 (disallowed) = $1,900 ($38/share)

Example 3: No Wash Sale (31+ Days)

Scenario: Alex sells shares at a loss and waits 35 days before repurchasing.

Inputs: Sold: 200 shares @ $25 (cost basis $35) | Repurchased: 200 shares @ $24 after 35 days

Calculation:

  • Sale Proceeds: 200 ร— $25 = $5,000
  • Original Cost: 200 ร— $35 = $7,000
  • Capital Loss: $5,000 - $7,000 = -$2,000
  • Days Apart: 35 (OUTSIDE 30-day window) โ†’ No Wash Sale!
  • Disallowed: $0
  • Deductible: $2,000 (full loss)

Replacement Basis: Simply $4,800 (200 ร— $24) โ€“ no adjustment needed

๐Ÿ“Š Wash Sale Rule Reference Table 2026

ScenarioResultTax Impact
Repurchase within 30 daysWash SaleLoss disallowed, added to new basis
Repurchase after 31+ daysNo Wash SaleFull loss is deductible
Buy identical security in IRAWash SaleLoss permanently disallowed
Spouse buys same securityWash SaleLoss disallowed

๐Ÿ’ก Important Tips for Avoiding Wash Sales

  • Wait 31 Days: The safest way to avoid a wash sale is to wait at least 31 days before repurchasing the same security. Mark your calendar!
  • Buy Similar, Not Identical: You can buy a similar but not "substantially identical" security immediately. For example, sell S&P 500 ETF (SPY) and buy total market ETF (VTI).
  • Watch Your IRA: If your IRA buys the same security during the wash sale window, the loss is permanently disallowedโ€”not added to basis. This is the worst scenario.
  • Spouse's Accounts Count: Your spouse's purchases in any account can trigger the wash sale rule. Coordinate trades at tax time.
  • Options Matter: Buying call options or selling put options on the same security during the window also triggers wash sales.
  • Track Adjusted Basis: Keep records of all wash sales so your adjusted cost basis is correct when you eventually sell the replacement shares.

๐Ÿ”— Related Calculators

โ“ Frequently Asked Questions

What triggers a wash sale?
A wash sale is triggered when you sell a security at a loss and purchase the same or substantially identical security within 30 days before or after the sale date. This 61-day window (30 days before + sale day + 30 days after) is the wash sale period.
Is the disallowed loss permanently lost?
No, the disallowed loss is added to the cost basis of the replacement shares. When you eventually sell those shares, your adjusted basis will result in a larger gain or smaller loss, effectively recovering the deduction. Exception: IRA purchases permanently lose the deduction.
Do options count for wash sales?
Yes, purchasing a call option or selling a put option on the same security during the wash sale window can trigger the wash sale rule. The IRS considers these substantially identical to the underlying stock.
What is "substantially identical" for wash sales?
The IRS hasn't precisely defined this, but same company stocks, options on the same stock, and very similar ETFs (like two S&P 500 ETFs) are considered substantially identical. Different indexes (S&P 500 vs Total Market) are generally safe.
Does the wash sale rule apply to gains?
No, the wash sale rule only applies to losses. If you sell a security at a gain, you owe taxes on that gain regardless of when you repurchase. The rule exists to prevent tax-loss harvesting abuse.
How does partial repurchase affect wash sales?
If you repurchase fewer shares than you sold, only a proportional loss is disallowed. For example, selling 100 shares but repurchasing only 50 means only 50% of the loss is disallowed; the other 50% is deductible.
How accurate is this wash sale calculator?
This calculator accurately implements the IRS wash sale rule using the standard 30-day window and proportional disallowance formula. For complex situations with multiple lots or options, consult a tax professional.
Does cryptocurrency trigger wash sales?
Currently, the wash sale rule does not apply to cryptocurrency because the IRS treats crypto as property, not securities. However, legislation is pending that may extend wash sale rules to crypto in the future.

๐Ÿ“š Official IRS Resources

Created by Omnicalculator.space โ€” Your trusted source for investment tax calculators.

Last Updated: January 2026 | IRS Wash Sale Rule (IRC Section 1091)