Capital Gains Tax Calculator
Estimate your 2025 federal tax on investment gains. Compare short-term vs long-term rates and see potential savings.
Short-Term vs Long-Term Capital Gains
The IRS taxes investment gains differently depending on how long you held the asset. Short-term gains (held 1 year or less) are taxed as ordinary income โ the same rates as your wages, up to 37%. Long-term gains (held more than 1 year) qualify for preferential rates: 0%, 15%, or 20% depending on your income.
This difference can be enormous. A single filer with $100,000 income selling a stock for a $50,000 gain would pay roughly $11,000 in federal tax if long-term, versus $17,000 if short-term โ a difference of $6,000 just by waiting a few extra months.
Net Investment Income Tax (NIIT)
High earners pay an additional 3.8% Medicare surtax called the Net Investment Income Tax (NIIT) on investment income โ including capital gains, dividends, and interest. The threshold is $200,000 for single filers and $250,000 for married filing jointly. This means the top effective federal rate on long-term capital gains is 23.8% (20% + 3.8%), not 20%.
Wash Sale Rule
If you sell a stock at a loss to harvest the tax loss, you cannot buy the same or "substantially identical" security within 30 days before or after the sale. Violating this rule disallows the loss for tax purposes. This applies to the same stock, options on the same stock, and ETFs that track the same index.
Tax-Loss Harvesting
Tax-loss harvesting means deliberately selling investments at a loss to offset capital gains. Capital losses offset capital gains dollar-for-dollar. If your losses exceed your gains, you can deduct up to $3,000 of net capital losses against ordinary income each year, with the remainder carried forward indefinitely.
Roth Conversion Considerations
If you have years with lower taxable income โ such as early retirement before Social Security begins โ consider converting traditional IRA assets to a Roth IRA. Roth accounts grow tax-free, and qualified withdrawals (including any gains) are never taxed. The optimal strategy is to fill the 0% long-term capital gains bracket and the 12% ordinary income bracket with conversions before reaching higher brackets.