Skip to main content
Investment Basics

U.S. Tax-Loss Harvesting: Wash Sales, IRA Repurchases and Worked Examples

Calculate usable capital losses, distinguish taxable-account basis adjustments from IRA repurchases.

U.S. Tax-Loss Harvesting: Wash Sales, IRA Repurchases and Worked Examples
Illustration of the article topic; not a photograph of an actual investor or trading result.

A realized loss is only the starting point

This guide covers U.S. federal tax on an individual’s taxable stock and fund holdings. It does not apply the U.S. wash-sale rule to Japanese tax returns or claim that selling inside an IRA creates a deductible capital loss. The useful calculation is the current deduction after netting, the future basis effect, and the cost of changing investments.

Under IRS Topic 409, capital losses interact with capital gains first. A remaining net loss can generally offset up to $3,000 of other income per year ($1,500 for married filing separately), with unused loss potentially carried forward. A $20,000 loss therefore does not automatically cut tax by $20,000 multiplied by the ordinary-income rate.

Calculate the current benefit and the unused loss

Hypothetical example: a taxpayer who is not married filing separately has $15,000 of long-term gains and $20,000 of deductible long-term losses, no other capital transactions or carryovers, sufficient taxable income, a 15% rate on the gains and a 24% rate across the ordinary-income deduction. Fees, state taxes and other tax interactions are excluded.

CalculationAmount
Net capital result: $15,000 − $20,000−$5,000
Current deduction against other income$3,000
Illustrative carryforward$2,000
Federal tax reduction: $15,000 × 15% + $3,000 × 24%$2,970

The comparison assumes the $15,000 gains would otherwise remain taxable. Short- and long-term amounts must be netted in the required order, not allocated to whichever rate gives the largest saving. The carryover worksheet matters if income is insufficient to use the full deduction.

Check the 61-day window across accounts

Publication 550, Wash Sales covers purchases of substantially identical stock or securities within 30 days before or after a loss sale. Contracts, options, automatic reinvestment and relevant spouse transactions also need attention. Moving the purchase to another broker does not remove the issue.

Replacement purchaseLoss treatmentRecord to check
Substantially identical shares in a taxable accountDisallowed loss generally adjusts replacement-share basisMatched shares, adjusted basis and holding period
Substantially identical shares in the owner’s IRA or Roth IRALoss disallowed; IRA basis is not increasedTaxable sale and IRA purchase together
Different fund or issuerRequires a facts-based identity assessmentBenchmark, holdings, rights and structure

The IRA exception is the holding of IRS Revenue Ruling 2008-5, page 4. It means the loss is not simply preserved for a future deduction through higher IRA basis. For an illustrative $10,000 basis sold for $7,000, an equivalent taxable-account replacement at $7,000 can receive a $3,000 basis adjustment; the same IRA repurchase does not receive that adjustment.

An example selling 100 shares and repurchasing only 30

When sale and repurchase quantities differ, identify the matched shares instead of assuming the entire loss is disallowed. Publication 550, “More or less stock bought than sold,” explains matching purchases to sold shares in purchase order. This example assumes an individual holds only 100 shares with the same acquisition cost, with no other relevant transactions, fees or spouse purchases.

Selling all 100 shares bought for $100 each at $70 each produces a $3,000 loss. Suppose the taxpayer repurchases 30 identical shares the next day in a taxable account for $70 each. The loss is $30 per sold share, so $900 matching the 30 repurchased shares is disallowed. The $2,100 loss on the remaining 70 shares is not disallowed by this repurchase.

Share-matching calculationHypothetical amount
Sale loss: 100 shares × $30$3,000
Disallowed loss matching 30 shares$900
Loss on remaining 70 shares$2,100
Adjusted basis of replacement 30 shares: $2,100 + $900$3,000

The $2,100 is not an immediate refund of that amount. Netting, holding periods, current income and carryovers determine the tax effect. Record the replacement shares’ adjusted basis rather than continuing to report only the $2,100 purchase price. If several acquisition lots have different bases, an average loss across the entire sale cannot automatically be allocated to every repurchase.

If the same 30 shares are instead repurchased by the owner’s IRA, the matching $900 loss is disallowed but, under the Revenue Ruling discussed above, IRA basis does not increase. Do not copy the taxable-account example’s $3,000 adjusted basis into the IRA. Further automatic reinvestments during the following month can also change the analysis, so do not stop at the first repurchase.

Keep one record per transaction showing sale date, lot, shares sold, repurchase date, shares bought, matched loss and adjusted basis. An annual loss total alone cannot explain why $900 is unavailable currently. Transaction-level records also make differences between a broker’s display and the return’s adjustments traceable.

A different ticker is not an IRS safe harbor

Publication 550 evaluates whether securities are substantially identical from the facts and circumstances. It does not approve a named pair of S&P 500 funds as a safe swap. Changing fund managers while retaining the same benchmark is not sufficient evidence of a permitted deduction. Neither this guide nor a broker’s omission of a wash-sale flag establishes an exemption.

Record the proposed replacement’s benchmark, investment mandate, holdings and legal rights alongside the asset sold. A meaningfully different exposure can also change investment risk. Waiting until day 31 after a sale does not cure a purchase that already occurred within the preceding 30 days; review the full window.

Current tax reduction can mean later taxable gains

Separate from a disallowed wash sale, consider a permitted loss sale and a genuinely different replacement. Assume $10,000 original basis, sale and replacement cost of $7,000, followed by a later replacement sale for $15,000. The original $3,000 loss is realized now, but the later gain is $8,000. Holding the original investment until $15,000 would instead produce a $5,000 gain. This is an editorial comparison assuming identical later sale proceeds; it does not predict that two securities perform alike.

The lifetime tax difference depends on rates, timing and whether the loss is usable. Price moves while out of the market, spreads, fees and tracking differences can outweigh a current tax reduction. There is no universal minimum dollar loss or guaranteed annual return boost that makes harvesting worthwhile.

Keep a transaction-level review sheet

  1. Identify acquisition dates, basis, quantities and short- or long-term status for the lots sold.
  2. Check purchases during the whole window, including automatic buys, spouse accounts and the owner’s IRAs.
  3. Document why any replacement differs; obtain tax review if identity is unclear.
  4. Reconcile Form 1099-B with all accounts, adjust Form 8949 where required, and carry results to Schedule D.
  5. Compare the current deduction with future basis, transaction costs and portfolio changes before relying on the estimated saving.

Sources checked September 10, 2026; added examples and explanation reviewed September 12, 2026. General U.S. federal tax information, not individual advice or an instruction to sell. Investment disclaimer.

References

3

This article is for general information only and does not recommend buying or selling any financial product. Details may change after publication. Please review the disclaimer before making decisions.