Capital Gains Tax on Stocks Calculator
Selling investments triggers capital gains tax — at ordinary rates if you held less than a year, or at the preferential 0%/15%/20% long-term rates. This calculator estimates what you owe.
How this calculator works
Your gain is the sale proceeds minus your cost basis (what you paid, including reinvested dividends). Held one year or less, the gain is taxed at your ordinary income rates. Held longer, it qualifies for long-term rates: 0% up to $49,450 (single) or $98,900 (married), 20% above $545,500/$613,700, and 15% in between. Wash-sale rules and state taxes are not included.
Frequently asked questions
What is tax-loss harvesting?
Selling investments at a loss offsets your gains dollar-for-dollar, and up to $3,000 of excess losses can offset ordinary income each year, with the rest carrying forward. Harvesting losses while rebalancing is one of the few fully legal ways to reduce your tax bill.
How is cost basis calculated?
It is what you paid plus reinvested dividends and commissions, adjusted for stock splits. With specific identification or average cost methods, you can choose which shares to sell to manage the tax impact.
Does the wash-sale rule matter for me?
If you sell at a loss and buy a substantially identical security within 30 days before or after, the loss is disallowed for tax purposes. The rule applies to stocks, ETFs, and mutual funds alike.
Disclaimer: Results are estimates for general information only and do not constitute financial, tax, or legal advice. Figures reflect 2026 rules and may change. Always confirm current limits and consult a qualified professional before making decisions. Official figures: IRS.gov · 2026 limits per IRS tax inflation adjustments.