Skip to main content
capitalgaintaxcalc.com

Stocks & ETFs Capital Gains Tax Calculator 2025

Calculate estimated tax on stock and ETF sales using federal LTCG/STCG brackets, NIIT when applicable, and your state’s capital gains treatment.

Capital Gains Calculator

Federal · NIIT · All 50 states

2026 ratesIRS verified

Follow the three steps, save the sale, then calculate. Required fields are marked with *.

Your tax profile

These apply to every sale in this estimate.

What you sold

Prices and quantity for this lot. Give it a name if you will add more than one sale.

Asset type

When you bought and sold

The IRS uses these dates to decide short-term vs long-term rates.

Next: Save this sale to the order log, then click Calculate now. Tax results do not update until you calculate.

Order log

Sales included in this tax estimate.

Please fill in the details to see your results. Follow the three steps on the left, then save a sale here.

How stock and ETF capital gains are taxed

When you sell shares of stock, ETFs, or mutual funds for more than your adjusted cost basis, the profit is generally a capital gain. The IRS taxes that gain based primarily on how long you held the shares and your taxable income. Commissions and fees typically reduce proceeds or increase basis; reinvested dividends increase your basis if they were previously taxed.

Shares held more than one year usually qualify for long-term capital gains rates of 0%, 15%, or 20%. Shares held one year or less produce short-term gains taxed as ordinary income at rates up to 37%. Large gains can also trigger the 3.8% Net Investment Income Tax when MAGI exceeds the threshold for your filing status.

The wash-sale rule is critical for securities. If you sell at a loss and buy the same or a substantially identical security within 30 days before or after the sale, the loss may be disallowed and added to the basis of the replacement shares. Mutual fund capital gain distributions reported on Form 1099-DIV are generally taxable even when reinvested — this calculator focuses on sale of shares rather than fund distributions.

State tax layers on top of federal tax. Zero-income-tax states show $0 state capital gains tax in our model, while graduated and flat-rate states apply their published frameworks. Use the calculator with your filing status and state selected, then cross-check our methodology and official IRS Topic 409 guidance before filing.

Also see

Other calculators, how we model the numbers, and IRS Topic 409.

FAQ

Frequently asked questions

What is the wash-sale rule?

If you sell a security at a loss and buy the same or substantially identical security within 30 days before or after the sale, the loss may be disallowed and added to the basis of the new shares.

Are mutual fund capital gain distributions taxable?

Yes — taxable distributions reported on Form 1099-DIV are generally taxable even if reinvested. This calculator estimates tax on sales of shares; distribution reporting still belongs on your return.

Do ETFs use the same capital gains rates as individual stocks?

Yes for most equity ETFs held in taxable accounts. The short-term vs long-term holding-period rules and federal rate structure are the same as for individual stocks.

How do I find my cost basis?

Brokerages typically report basis on Form 1099-B for covered shares. For older positions, check statements, dividend reinvestment records, and corporate action adjustments. Incorrect basis is a common source of overpaid tax.

Guides