How to use the capital gains tax calculator
- Enter the Purchase price (cost basis) and the Sale price. Add buying fees to the basis and take selling fees off the sale price.
- Choose More than 1 year or 1 year or less for how long you owned it.
- Pick your Filing status and enter your Other 2026 income, before deductions. Add Itemized deductions only if they beat the standard deduction.
- Read the tax, your profit after tax and the long-term versus short-term comparison.
How the tax is worked out
A long-term gain is not taxed at one flat rate. It sits on top of your other taxable income and fills three bands: 0% up to $49,450 of total taxable income for single filers ($66,200 head of household), 15% up to $545,500 ($579,600 head of household) and 20% above that. Joint limits are in the questions below. A short-term gain is simply added to your income and taxed at the ordinary 10% to 37% brackets. Higher earners can also owe the 3.8% net investment income tax on top of either. The 2026 thresholds come from IRS Revenue Procedure 2025-32.
Worked example with the default inputs
You bought for $10,000 and sold for $25,000 after more than a year, single, with $60,000 of other income. The gain is $15,000. After the $16,100 standard deduction your other taxable income is $43,900, so the first $5,550 of the gain fits under the $49,450 limit and is taxed at 0%. The other $9,450 is taxed at 15%, which is $1,417.50. Your income of $75,000 is under $200,000, so there is no net investment income tax. Profit after tax is $13,582.50, an effective rate of 9.45%. Sold within a year, the tax would be $2,650, so waiting saves $1,232.50.
Limits and edge cases
- Collectibles such as coins and art are taxed at up to 28%, and depreciation recapture on rental property at up to 25%. Treat results for those as a floor.
- Selling your main home? Up to $250,000 of gain ($500,000 for couples) can be excluded if you meet the ownership and use tests. To model it, lower the sale price by the amount you can exclude.
- State income tax is not included. To find the gain on a trade, use the stock profit calculator or the crypto profit calculator, and see your wider tax picture in the 2026 tax bracket calculator.
Capital gains tax questions
What is the capital gains tax rate for 2026?
Long-term gains are taxed at 0%, 15% or 20%. For single filers the 0% rate covers taxable income up to $49,450 and 15% covers income up to $545,500. For married couples filing jointly the limits are $98,900 and $613,700. Short-term gains are taxed at your ordinary rate, from 10% to 37%.
How long do I have to hold an investment for the long-term rate?
More than one year. The holding period starts the day after you buy and includes the day you sell, so an asset bought on March 10, 2025 qualifies if sold on March 11, 2026 or later.
Do I owe the 3.8% net investment income tax?
Only if your modified adjusted gross income is over $200,000 single, $250,000 married filing jointly or $125,000 married filing separately. The tax is 3.8% of the smaller of your net investment income or the amount over the limit. These limits are not adjusted for inflation.
Can capital losses reduce my taxes?
Yes. Losses first cancel out capital gains. Up to $3,000 of any net loss left over ($1,500 if married filing separately) can be deducted from other income each year, and the rest carries forward.
Do I pay capital gains tax inside a 401(k) or IRA?
No. Sales inside a retirement account are not taxed when they happen. Withdrawals from a traditional 401(k) or IRA are taxed as ordinary income, and qualified Roth withdrawals are tax free.
Sources: IRS Rev. Proc. 2025-32 (2026 brackets, capital gains thresholds, standard deduction), IRS Topic 409 (holding period, loss limit, 25% and 28% gains), IRS net investment income tax. Figures checked September 2026. This is an estimate, not tax advice.