The Tax Brief real effective rates for 111+ countries — bi-weekly, free.
TAX GUIDE

Tax-Loss Harvesting Guide 2026: Rules, Wash Sale & Worked Example

KEY INSIGHT
Tax-loss harvesting lets you sell losing investments to offset capital gains, plus up to $3,000 per year ($1,500 married filing separately) against ordinary income. Unused losses carry forward indefinitely. The wash-sale rule disallows the loss if you buy substantially identical securities within 30 days before or after the sale — the disallowed loss is added to the replacement shares' cost basis instead of lost.
At a glance

Key Facts

Ordinary Income Offset Limit
$3,000/year ($1,500 if married filing separately) after gains are fully offset
Capital Loss Carryforward
Unlimited — carries forward to future years until fully used, retaining its short-term or long-term character
Wash-Sale Window
30 days before AND 30 days after the sale (61-day window total) — buying substantially identical securities in that window disallows the loss
Disallowed Loss Treatment
Added to the cost basis of the replacement shares — not permanently lost, just deferred
Loss Netting Order
Short-term losses offset short-term gains first; long-term losses offset long-term gains first; net excess offsets the other category
Carryover Loss Order
When applying the $3,000 annual limit, short-term losses are used before long-term losses
Official Source
IRS Publication 550, Chapter 4 (Wash Sales); IRS Topic No. 409 (Capital Gains and Losses)
Introduction

Tax-loss harvesting is the practice of deliberately selling an investment at a loss to offset capital gains elsewhere in your portfolio — and, once gains are fully offset, up to $3,000 of ordinary income per year. It's one of the few tax strategies that turns a market downturn into a genuine, quantifiable tax benefit, and it's available to any investor with a taxable brokerage account (it doesn't work in tax-advantaged accounts like 401(k)s or IRAs, since gains and losses inside those accounts aren't reported to the IRS).

This guide covers exactly how tax-loss harvesting works, the $3,000 annual ordinary-income offset limit, the unlimited capital-loss carryforward rule, the 30-day wash-sale rule that can disallow your loss if you're not careful, the short-term-vs-long-term loss ordering rules, and a full worked numeric example showing the mechanics end to end.

Section 01

How Does Tax-Loss Harvesting Work?

Tax-loss harvesting follows a specific netting order defined by the IRS on Schedule D of Form 1040:

  1. Net your short-term gains and losses against each other (assets held one year or less).
  2. Net your long-term gains and losses against each other (assets held more than one year).
  3. Combine the two results. If one category shows a net gain and the other a net loss, the loss offsets the gain.
  4. If you have a total net loss after netting everything together, you can deduct up to $3,000 of that loss against ordinary income (wages, interest, etc.) — $1,500 if married filing separately.
  5. Any remaining loss carries forward to future tax years, with no expiration date, retaining its original short-term or long-term character.

Because long-term capital gains are typically taxed at lower rates (0%/15%/20%) than short-term gains (taxed as ordinary income up to 37%), the type of loss you harvest matters: a short-term loss offsetting a short-term gain saves you more per dollar than the same loss offsetting a long-term gain, since it displaces income that would otherwise be taxed at your higher marginal rate.

Section 02

How Much Can I Deduct Against Ordinary Income?

Per IRS Topic No. 409, once your capital losses have fully offset all your capital gains for the year, you can deduct the lesser of $3,000 ($1,500 if married filing separately) or your total remaining net capital loss against ordinary income like wages and interest. This limit has been fixed by statute at $3,000 since 1978 and is not adjusted for inflation.

Any loss beyond that $3,000 annual cap doesn't disappear — it carries forward indefinitely to future tax years, where it can offset future capital gains (dollar for dollar, with no annual cap on gain offsets) and, again, up to $3,000 per year against ordinary income until fully used up.

Worked Example: Full Mechanics

An investor in 2026 has: a $12,000 long-term gain from selling one stock, a $9,000 long-term loss from tax-loss harvesting a different position, and a $4,000 short-term loss from a third position held less than a year.

StepCalculationResult
Net long-term (gain − loss)$12,000 − $9,000+$3,000 net long-term gain
Net short-termNo short-term gains to offset−$4,000 net short-term loss
Combine both categories$3,000 − $4,000−$1,000 total net capital loss
Deduct against ordinary incomeFull $1,000 is under the $3,000 cap$1,000 deducted from wages/other income
Carryforward to 2027Nothing left to carry forward$0

In this example, the investor completely eliminated tax on their $12,000 long-term gain (which otherwise would have been taxed at 15% or 20%) and additionally reduced their ordinary taxable income by $1,000 — all from proactively harvesting a $9,000 loss and a $4,000 loss before year-end.

Section 03

What Is the Wash-Sale Rule?

The wash-sale rule, under IRC §1091 and detailed in IRS Publication 550, prevents you from claiming a tax loss if you buy "substantially identical" stock or securities within a 61-day window: 30 days before the sale through 30 days after the sale. This applies whether you buy the replacement shares outright, acquire them in a fully taxable trade, acquire an option or contract to buy them, or buy them inside an IRA or Roth IRA.

If your loss is disallowed under the wash-sale rule, it isn't permanently lost — per IRS Publication 550, you add the disallowed loss to the cost basis of the new (replacement) shares, and the replacement shares inherit the holding period of the original shares. This defers the loss until you eventually sell the replacement shares, rather than eliminating it.

Worked Wash-Sale Example

You buy 100 shares of Stock X for $1,000. You sell those shares for $750 (a $250 loss) and, within 30 days of the sale, buy 100 shares of the same stock again for $800. Because you repurchased substantially identical stock inside the 30-day window, you cannot deduct the $250 loss on your 2026 return. Instead, the $250 disallowed loss is added to your new stock's $800 cost, giving you a basis of $1,050 in the replacement shares — the loss is preserved, just deferred until you eventually sell those shares.

The wash-sale rule applies to stocks and securities (including options and futures contracts on them) but does not apply to commodity futures contracts, foreign currencies, or — as of 2026 — cryptocurrency, which the IRS classifies as property rather than a security. Congress has periodically proposed extending wash-sale treatment to crypto, so this carve-out could change in future tax years.

Section 04

Short-Term vs. Long-Term Loss Ordering Rules

When you carry a capital loss forward to a future year, it retains its original character: a long-term loss stays long-term, and a short-term loss stays short-term. Per IRS Publication 550, a long-term capital loss carried forward reduces the following year's long-term capital gains before it reduces that year's short-term capital gains, and vice versa for short-term carryforward losses.

Additionally, when you're figuring how much of your loss counts against the $3,000 annual limit, the IRS requires you to use your short-term capital losses first, even if you incurred them after a long-term loss during the same year. If you haven't reached the $3,000 limit after applying short-term losses, you then apply long-term losses until you hit the cap.

Section 05

Practical Tax-Loss Harvesting Considerations for 2026

A few things to keep in mind when harvesting losses in a taxable account: settlement dates, not just trade dates, can matter for precise wash-sale timing, so leave a buffer around the 30-day window rather than trading right at the edge. ETFs tracking similar (but not identical) indexes — for example, selling one S&P 500 ETF at a loss and buying a different provider's S&P 500 ETF — are generally not considered "substantially identical" under current IRS guidance, giving investors a way to maintain market exposure while banking the loss, though this remains a facts-and-circumstances test rather than a bright-line safe harbor.

Also remember that tax-loss harvesting only applies to taxable brokerage accounts — losses inside a 401(k), traditional IRA, or Roth IRA are not reported to the IRS and cannot be harvested for a tax benefit, since gains and losses inside those accounts aren't taxed as they occur in the first place.

💡

CountryTaxCalc.com is reader-supported. When you use our partner links, we may earn a commission at no cost to you. This helps us provide free tax calculators and comparison tools. Learn more about our affiliate partnerships

Best for Most People

Wise

★ 4.3 Trustpilot  ·  287,413 reviews

Send money internationally at the real mid-market rate. Free to open. 14.8M customers worldwide. 4.3★ / 287,000+ Trustpilot reviews.

⚠ For currency exchange only — not a bank account replacement.

Send Money Internationally →
Best Full-Service CPA

Greenback Expat Tax Services

★ 4.8 Trustpilot  ·  1,625 reviews

Moving abroad from the US? Greenback's CPAs specialise in FEIE, foreign tax credits and FBAR. Dedicated CPA, flat fee from $565, no surprises. 71,000+ expat returns filed. 4.8★ / 1,625 Trustpilot reviews.

⚠ Not the cheapest option — best for complex situations and expats who want a dedicated CPA.

Get Expert US Expat Tax Help →
FAQ

Frequently Asked Questions

How much can I deduct from tax-loss harvesting each year?

You can use capital losses to offset capital gains dollar-for-dollar with no limit. Once gains are fully offset, you can additionally deduct up to $3,000 of remaining net capital loss against ordinary income per year ($1,500 if married filing separately). Any loss beyond that carries forward to future years.

What is the wash-sale rule?

The wash-sale rule disallows a tax loss if you buy substantially identical stock or securities within 30 days before or 30 days after the sale that generated the loss — a 61-day window total. The disallowed loss is added to the cost basis of the replacement shares rather than being permanently lost.

Does the wash-sale rule apply to cryptocurrency?

As of 2026, no. The IRS classifies cryptocurrency as property, not a security, so the wash-sale rule under IRC Section 1091 does not currently apply to crypto trades. Congress has periodically proposed legislation to extend wash-sale treatment to digital assets, so this could change in a future tax year.

Can I carry forward capital losses indefinitely?

Yes. Unlike the $3,000 annual limit on offsetting ordinary income, there is no expiration date on capital loss carryforwards for individuals — losses carry forward year after year, retaining their short-term or long-term character, until fully used against future gains or ordinary income.

What happens if my capital loss is disallowed by the wash-sale rule?

The disallowed loss is not permanently lost. Per IRS Publication 550, you add the disallowed amount to the cost basis of the replacement shares you purchased, and your holding period for those replacement shares includes the holding period of the shares you sold — effectively deferring the loss until you sell the new position.

Can I harvest losses inside my 401(k) or IRA?

No. Tax-loss harvesting only works in taxable brokerage accounts, because gains and losses inside tax-advantaged accounts like 401(k)s and IRAs are never reported to the IRS as they occur — there's no annual capital gain or loss to offset in the first place.

Does it matter if my loss is short-term or long-term?

Yes. Short-term losses first offset short-term gains (which are taxed at higher ordinary rates), and long-term losses first offset long-term gains (taxed at the lower 0/15/20% rates). When applying the $3,000 annual ordinary-income offset, the IRS requires you to use short-term losses before long-term losses.

Can I buy back the same stock after 31 days without triggering the wash-sale rule?

Yes. The wash-sale rule only applies within the 30-day window before or after the sale. If you wait at least 31 days before repurchasing substantially identical stock or securities, the wash-sale rule does not apply and your original loss remains fully deductible.

Can my spouse buy the same stock I just sold at a loss?

No — this still triggers a wash sale. Per IRS Publication 550, if you sell stock at a loss and your spouse (or a corporation you control) buys substantially identical stock within the 30-day window, the wash-sale rule applies just as if you had made the purchase yourself.

Is there a limit on how much I can deduct against capital gains?

No. There is no dollar limit on using capital losses to offset capital gains — only the $3,000/year limit applies to using leftover losses against ordinary income after gains are fully offset.
Disclaimer:This guide provides general educational information about federal tax-loss harvesting rules for 2026, based on IRS Publication 550 and IRS Topic No. 409. It is not tax, legal, or investment advice. The wash-sale rule, loss-netting order, and carryforward calculations involve many individual factors specific to your portfolio and filing status. Consult a qualified tax professional or financial advisor before executing a tax-loss harvesting strategy.
Keep reading

Related Guides