Wash Sale Loss Adjustment Calculator

JJ Ben-Joseph headshot JJ Ben-Joseph

What is the wash sale rule?

The IRS wash sale rule is designed to prevent investors from creating artificial tax losses. If you sell a stock, ETF, or other security at a loss and buy the same or a substantially identical security within 30 days before or after the sale, the loss is generally disallowed for current tax purposes. Instead, the disallowed loss is added to the cost basis of the new shares.

This calculator is intended to help you estimate two key values in a simple, single-lot scenario:

Always confirm your calculations against IRS guidance and, where appropriate, with a qualified tax professional before filing a return.

Core formulas used in wash-sale loss adjustment

For a basic case where you sell a single lot of shares at a loss and repurchase some or all of those shares within the 61-day window (30 days before, the day of sale, and 30 days after), the key concepts are:

Let:

Then the core formulas are:

Realized\ Loss = Qs ร— ( Ps โˆ’ B ) Disallowed\ Loss = Qr Qs ร— Realized\ Loss Allowed\ Loss = Realized\ Loss โˆ’ Disallowed\ Loss Adjusted\ Basis\ per\ Replacement\ Share = Pr + Disallowed\ Loss Qr

Your total adjusted basis in the replacement shares is:

Adjusted total basis = Qr ร— Adjusted basis per replacement share

How to interpret the calculator results

When you run the wash sale loss adjustment calculator, you will typically see outputs similar to:

Higher disallowed losses mean you will usually have a smaller current deduction but a higher basis going forward, which can reduce future taxable gains or increase future losses when you sell the replacement shares.

Worked example of a wash sale adjustment

Suppose you have the following situation:

Step 1: Calculate realized loss on the sale.

Step 2: Determine the disallowed loss.

Step 3: Allowed loss this year.

Step 4: Adjust basis of replacement shares.

When you later sell the 60 replacement shares, you will use $52 per share as your cost basis for gain/loss calculations, reflecting the deferred portion of the original loss.

Comparison: with vs. without the wash sale rule

The table below contrasts how the same transaction looks with and without the wash sale rule, using the worked example above.

Item Without wash sale rule With wash sale rule applied
Total realized loss on sale โˆ’$1,000 (fully deductible now) โˆ’$1,000 (economic loss is the same)
Disallowed loss $0 $600 disallowed currently
Allowed current-year loss โˆ’$1,000 โˆ’$400
Basis in replacement shares 60 ร— $42 = $2,520 60 ร— $52 = $3,120 (includes deferred loss)
Future tax impact Higher gain / smaller loss when you sell the 60 shares Lower gain / larger loss when you sell the 60 shares

This illustrates that the wash sale rule does not make the loss disappear. Instead, it delays the deduction by embedding the disallowed portion into the basis of your replacement shares.

Assumptions, limitations, and important notes

Disclaimer: This explanation is for general informational purposes only and does not constitute tax, legal, or investment advice. Your specific situation may involve additional rules or exceptions. Consult a qualified tax professional or financial advisor before making decisions that affect your tax filings.

Using this calculator effectively

For the most useful results, gather the following information before using a wash sale loss adjustment calculator:

Enter consistent, accurate numbers, then review both the dollar amounts and the narrative explanation of the outputs. When in doubt, compare the results with your brokerโ€™s tax documents or seek professional guidance.

Disclaimer: This calculator provides educational estimates only and does not constitute professional advice. Consult with qualified professionals for your specific situation.

Embed this calculator

Copy and paste the HTML below to add the Wash Sale Loss Adjustment Calculator to your website.