Capital Gains Tax Calculator 2026 - Long-Term vs Short-Term Rates on Investment Sales
Every time you sell an investment for more than you paid for it, you realize a capital gain. Capital Gains Tax = Realized Gain x Applicable Rate (0%, 15%, or 20%). The rate depends critically on how long you held the investment.
Short-Term vs Long-Term Capital Gains
Hold an asset for one year or less: short-term gain, taxed as ordinary income at your marginal rate (up to 37 percent). Hold more than one year: long-term gain, taxed at preferential 0, 15, or 20 percent rates. For a high-income investor selling $100,000 in appreciated stock, the difference between short-term and long-term treatment can be $17,000 in tax.
The Formula Explained
Capital Gain: Sale Price - Cost Basis - Selling Expenses.
2026 projected long-term capital gains rates: 0% on income up to $49,150 (single) / $98,300 (MFJ). 15% from $49,151-$492,450 (single) / $553,850 (MFJ). 20% above those thresholds. NIIT: 3.8% additional on investment income for AGI above $200,000 (single) / $250,000 (MFJ).
Worked example: Rachel (single) has $70,000 W-2 income. Sells stock held 3 years for $45,000 (basis $22,000). Long-term gain: $23,000. Ordinary taxable income $54,250 exceeds 0% threshold ($49,150), so all $23,000 is taxed at 15%. Capital gains tax: $3,450.
| Holding Period | Gain Amount | Single Filer Income | Rate Applied | Tax Owed |
|---|---|---|---|---|
| Short-term | $20,000 | $65,000 taxable | 22% ordinary | $4,400 |
| Long-term | $20,000 | $65,000 taxable | 15% preferential | $3,000 |
| Long-term | $20,000 | $30,000 taxable | 0% rate zone | $0 |
| Long-term + NIIT | $50,000 | $300,000 taxable | 15% + 3.8% | $9,400 |
How to Use This Calculator on CalcAdvisor.com
Estimate your capital gains tax before making any investment sale at https://www.calcadvisor.com/calculators/capital-gains-tax-calculator.
3 Real-World Examples
Example 1: David, Middle-Income Investor, Deciding Whether to Wait for Long-Term Treatment
David bought $18,000 in tech stock 11 months ago. Now worth $31,000 - a $13,000 gain. 1 month from long-term threshold. Short-term: $2,860 tax (22%). Long-term: $1,950 tax (15%). Tax saving from waiting: $910. He waits the month.
Example 2: Patricia, Retiree, Harvesting Long-Term Gains in the 0% Rate Zone
Patricia has $42,000 taxable income. 0% threshold: $49,150. Remaining 0% capacity: $7,150. She realizes exactly $7,150 in long-term gains tax-free, then repurchases the same fund to step up her basis - $0 tax.
Example 3: Robert and Elena, High-Income, Real Estate Sale
Sale: $620,000. Basis: $280,000. Improvements: $45,000. Selling costs: $37,000. Gain: $258,000. Depreciation recapture ($144,000 at 25%): $36,000. Standard capital gain ($114,000 at 20%): $22,800. NIIT (3.8%): $9,804. Total federal tax on sale: $68,604.
Common Mistakes to Avoid
- Selling appreciated assets 1-2 months before qualifying for long-term treatment.
- Ignoring cost basis tracking for purchased investments.
- Forgetting about state capital gains taxes.
- Missing the stepped-up basis for inherited assets.
- Not using capital loss harvesting to offset gains.
- Confusing the holding period start date.
- Not planning large real estate sales for depreciation recapture.
Final Thoughts
Estimate your capital gains tax before making any investment sale at https://www.calcadvisor.com/calculators/capital-gains-tax-calculator.