Capital Gains Tax Calculator
Estimate federal capital gains tax on investments, real estate, and other assets.
Capital Gain
—
Estimated Tax
—
Net Proceeds
—
Guide
How it works
Use this calculator to estimate federal capital gains tax on investments, real estate, and other assets. Essential for planning the after-tax proceeds of a sale, understanding the difference between short-term and long-term capital gains rates, and timing asset sales tax-efficiently.
What this calculator does
The capital gains tax calculator helps you estimate federal capital gains tax owed on the sale of an investment or asset.
It uses:
- cost basis
- sale price
- holding period
- filing status and income level
This gives you the capital gain amount and the estimated federal capital gains tax — the figures needed to plan net proceeds, evaluate sale timing, and compare investment outcomes after tax.
Capital Gains Tax Formula
Capital Gain = Sale Price − Cost Basis
Capital Gains Tax = Capital Gain × Applicable Rate
Where:
- Cost Basis = original purchase price plus eligible costs
- Sale Price = amount received from the sale
- Capital Gain = profit on the sale (loss if negative)
- Applicable Rate = short-term (ordinary income rates) or long-term (0%, 15%, or 20%) based on holding period and income
Example calculation
If:
- Cost basis = 20,000
- Sale price = 30,000
- Holding period = 18 months (long-term)
- Long-term capital gains rate = 15%
Then:
- Capital gain = 30,000 − 20,000 = 10,000
- Capital gains tax = 10,000 × 0.15 = 1,500
- Net proceeds after tax = 30,000 − 1,500 = 28,500
The investment produces a 10,000 gain and incurs 1,500 in federal capital gains tax, leaving 28,500 after tax.
What is capital gains tax?
Capital gains tax is federal tax on the profit from selling an asset for more than its cost basis. Common taxable assets include stocks, bonds, real estate, mutual funds, and businesses. The rate depends on how long the asset was held — short-term gains (held one year or less) are taxed at ordinary income rates, while long-term gains (held more than one year) are taxed at preferential rates of 0%, 15%, or 20% depending on income.
Why capital gains tax matters
Understanding capital gains tax helps you:
- estimate net proceeds before deciding to sell an asset
- time sales to qualify for long-term rates and reduce tax owed
- evaluate the after-tax return of different investments
- plan offsetting strategies using capital losses or tax-advantaged accounts
When to use this calculator
Use this calculator when you want to:
- estimate federal tax on the sale of stocks, real estate, or other investments
- compare after-tax returns at short-term versus long-term holding periods
- model the tax impact of selling appreciated assets in different income years
- plan tax-loss harvesting to offset capital gains within the same tax year
Common mistakes when calculating capital gains tax
Common mistakes include:
- forgetting to include eligible costs (commissions, improvements, transaction fees) in the cost basis
- applying short-term rates to assets held exactly 12 months — long-term treatment requires more than one year
- ignoring state capital gains tax, which is separate and varies significantly by state
- failing to apply capital losses against gains, which can substantially reduce or eliminate tax owed
Short-term vs long-term capital gains
The holding period determines which rate applies and is the most consequential factor in capital gains planning.
- Short-term capital gains — assets held one year or less, taxed at ordinary federal income tax rates (10% to 37%)
- Long-term capital gains — assets held more than one year, taxed at preferential rates of 0%, 15%, or 20% depending on taxable income
The difference can be substantial — a high earner might pay 37% on a short-term gain but only 20% on a long-term gain on the same profit.
FAQs
What is capital gains tax?
Capital gains tax is federal tax on the profit from selling an asset for more than its cost basis. It applies to stocks, real estate, bonds, mutual funds, businesses, and other investments. The rate depends on the holding period and the seller's income level.
How do you calculate capital gains tax?
Subtract the cost basis from the sale price to find the gain, then multiply by the applicable rate. For a 10,000 long-term gain at a 15% rate, the tax owed is 1,500.
What is a good way to reduce capital gains tax?
Common strategies include holding assets for more than one year to qualify for long-term rates, offsetting gains with capital losses (tax-loss harvesting), using tax-advantaged accounts like IRAs and 401(k)s, and timing sales for years with lower taxable income.
What is the difference between short-term and long-term capital gains?
Short-term gains apply to assets held one year or less and are taxed at ordinary income rates (10% to 37%). Long-term gains apply to assets held more than one year and are taxed at preferential rates of 0%, 15%, or 20% depending on income.
Explore more
More calculators in this topic
Continue exploring
Related calculators
Explore the next calculations most relevant to this topic.
tax-compliance
Income Tax Bracket Calculator
Estimate federal income tax across US progressive tax brackets.
tax-compliance
US Federal Tax Calculator
Estimate US federal income tax from taxable income and filing status.
property-investment
Property Tax Calculator
Calculate property tax for property investment analysis.