Tax & Investment Disclaimer: This tool models IRS Schedule D capital gains netting, IRS § 1211(b) ordinary income deductions, and § 1091 wash sale rules for educational analysis. Consult a certified CPA or tax attorney for complex tax filings.
IRS Tax Code Studio Capital Gains Netting • $3k Income Offset • Wash Sale Matrix

Tax-Loss Harvesting & Wash-Sale Optimizer

Calculate tax alpha savings, short/long-term capital gains offsets, $3,000 ordinary income write-offs, and 30-year reinvestment compounding.

1. Capital Losses & Gains (Schedule D)

Current Tax Year
$
$
Taxed at Ordinary Rate
$
Taxed at 15%–20% + NIIT

2. Income & Tax Filing Status

Marginal Rates
$

3. Reinvestment Compounding Horizon

8.0% S&P 500 CAGR
Investment Compounding Years: 20 Years
5 Years 15 Years 25 Years 35 Years
Estimated Immediate Tax Cash Saved This Year

$3,750.00

100% LOSS HARVESTED
Short-Term Offset

$6,000

@ 30.0% Fed+State
Long-Term Offset

$4,000

@ 21.0% LTCG+State
$3k Income Offset

$3,000

IRS § 1211(b) Max
Loss Carryforward

$2,000

Future Tax Years
Reinvested Tax Savings Value in 20 Years:

Assuming 8.0% annual CAGR compounding without tax drag

$17,478.62

Compounded Wealth Trajectory of Harvested Tax Savings

Reinvested in S&P 500 (8.0% CAGR)

IRS 30-Day Wash-Sale Rule: Safe Proxy ETF Substitution Matrix

To claim the tax loss without triggering IRS § 1091 disallowance, swap into a non-"substantially identical" correlated asset to maintain market exposure.

61-Day Rule Safe Pairs
Sold Asset (Harvest Loss) Underlying Index Safe Replacement Proxy Replacement Index Wash-Sale Status
VOO / SPY / IVV S&P 500 Index VTI / SCHB / ITOT Total US Stock Market (CRSP / Dow Jones) 100% Safe (Different Index)
QQQ Nasdaq-100 Index VGT / XLK / IYW MSCI US Tech / S&P Technology Select 100% Safe (Sector Focus)
VXUS FTSE Global All Cap ex US IXUS / VEU MSCI ACWI ex USA / FTSE All-World 100% Safe (Different Index)
VNQ MSCI US REIT Index SCHH / XLRE Dow Jones US Select REIT / Real Estate Select 100% Safe (Different Index)
Individual Stock (e.g. NVDA) Single Company Equity SMH / SOXX / AMD VanEck Semiconductor ETF / Competitor 100% Safe (Basket / Competitor)
AI Tax Alpha & Year-End Harvesting Strategist 100% Private AI

Click "Run AI Tax Alpha Audit" to evaluate optimal year-end harvest timing, analyze your 3.8% Net Investment Income Tax (NIIT) exposure, and construct safe ETF proxy rotation pairs. processed entirely on your device.

Zero Data Access: Financial amounts and income parameters execute 100% locally on your device. Processed on-device

What This Calculator Does

Designed for investors navigating year-end portfolio optimization, this calculator helps you quantify the financial impact of selling securities at a loss to offset capital gains and ordinary income. By inputting your realized gains, unrealized losses, and income profile, the tool determines your immediate tax savings and potential loss carryforward.

It specifically highlights how the IRS ordinary income deduction limit applies to your scenario and models the long-term wealth effect of reinvesting those tax savings. Whether you are rebalancing a taxable brokerage account or exploring 401(k) Match strategies, this tool provides a clear, quantitative view of your net tax alpha.

How the Math Works

The underlying logic strictly follows the capital gains netting rules established in Internal Revenue Code (IRC) Section 1222 and Section 1211(b), as reported on IRS Form 1040, Schedule D. First, the calculator offsets short-term losses against short-term gains, and long-term losses against long-term gains. If a net loss remains in one category and a net gain in the other, they are netted against each other.

If you have an overall net capital loss for the 2026 tax year, the calculator applies up to $3,000 against your ordinary income, which directly reduces your top marginal federal and state tax liability. Any remaining loss beyond this $3,000 threshold is automatically tabulated as a capital loss carryforward for future tax years. For more details on these statutory mechanisms, consult IRS Publication 550.

Worked Example

Consider an investor who earns $185,000 annually (placing them in the 24% federal marginal bracket) and lives in a state with a 6% income tax. They have realized $6,000 in short-term gains and $4,000 in long-term gains. If they decide to harvest $15,000 in unrealized losses, the calculator performs the netting process.

The $15,000 loss entirely eliminates the $6,000 short-term gain (saving $1,800 in taxes at a 30% combined rate) and the $4,000 long-term gain (saving $840 at a 21% combined rate). The remaining $5,000 loss is then used to offset $3,000 of ordinary income (saving $900), leaving a $2,000 loss carryforward for next year. In total, this strategy yields $3,540 in immediate tax savings, which can be reinvested alongside HSA Wealth contributions to compound over time.

Frequently Asked Questions

How does Tax-Loss Harvesting (TLH) reduce my taxes?

Tax-loss harvesting involves selling investments at an unrealized loss to offset realized capital gains dollar-for-dollar on IRS Schedule D. If your losses exceed total capital gains, you can deduct up to $3,000 ($1,500 if married filing separately) against ordinary W-2 or business income, with any remaining balance carrying forward indefinitely to future tax years.

What is the IRS 30-Day Wash Sale Rule?

Under IRS Section 1091, a wash sale occurs if you sell a security at a loss and purchase a 'substantially identical' security within a 61-day window (30 days before the sale, the day of the sale, or 30 days after the sale). When triggered, the loss deduction is disallowed and added to the cost basis of the newly acquired security.

What are safe ETF proxy pairs for tax-loss harvesting without triggering a wash sale?

Investors frequently swap between ETFs tracking different underlying indices. For example, selling Vanguard S&P 500 (VOO, tracking S&P 500) and immediately purchasing Vanguard Total Stock Market (VTI, tracking CRSP US Total Market) or Schwab US Large-Cap (SCHX, tracking Dow Jones US Large-Cap) maintains market exposure while avoiding IRS wash sale disallowance.

What happens if a wash sale occurs in a Roth IRA?

Under IRS Revenue Ruling 2008-5, if you sell a stock at a loss in a taxable brokerage account and repurchase the same stock within 30 days in an IRA or Roth IRA, the tax loss is permanently eliminated and cannot be added to the IRA basis, resulting in a total loss of the tax deduction.

Related Tools

Disclaimer: This tool is for educational and scenario-analysis purposes only. It does not constitute tax, legal, or investment advice. Always consult a licensed CPA or tax advisor for your specific situation. Figures reflect 2026 statutory limits and may change.

Built and verified by The Core-AI Engineering Desk — last reviewed August 31, 2026. Calibrated strictly to 2026 statutory figures.