Capital Gains Tax Calculator
Estimate the taxes you owe on the sale of investments like stocks, crypto, or real estate.
Long-term — preferential 0/15/20% rates apply
Used to determine LTCG bracket & NIIT ($200k/$250k threshold)
TX/FL/NV = 0%, CA = 13.3%, NY = 10.9%
Net Profit After Tax
Gain & Tax Breakdown
Long-term gains stack on top of ordinary income to determine the applicable 0/15/20% bracket. NIIT (3.8%) applies to the lesser of net investment income or MAGI above $200K single / $250K MFJ.
| Item | Amount | Notes |
|---|---|---|
| 1 Purchase Price | $10,000 | - |
| 2 Selling Price | $15,000 | - |
| 3 Capital Gain | $5,000 | Long-Term (≥12 mo) |
| 4 Federal LTCG Tax | -$750 | 15.0% effective federal |
| 5 State Tax | -$250 | 5% |
| 6 Total Tax | -$1,000 | Effective rate: 20.0% |
| 7 Net Profit (After Tax) | $4,000 | 40.0% ROI |
What Is Capital Gains Tax?
Capital Gains Tax (CGT) is the federal tax you owe on the profit you realize when you sell a capital asset—stocks, ETFs, mutual funds, real estate, cryptocurrency, or collectibles—for more than you paid for it. You only owe CGT when you *sell* (a "realization event"); simply owning an appreciated asset creates no tax liability.How gain is calculated: > Capital Gain = Selling Price − Cost Basis − Selling Expenses
Your *cost basis* is what you originally paid, plus any commissions, fees, or improvements (for real estate). Selling expenses include broker commissions and transfer taxes.
---
📈 Short-Term vs Long-Term: The Most Important Distinction
The single biggest factor in your CGT bill is how long you held the asset.
Short-Term Capital Gains (held ≤ 365 days) Taxed as ordinary income—the same brackets as your salary. For 2026, federal rates range from 10% to 37%. If you're in the 32% bracket, a short-term gain is taxed at 32%. There is no discount for short-term gains.
Long-Term Capital Gains (held > 365 days) Taxed at preferential federal rates of 0%, 15%, or 20% depending on your taxable income. For most middle-income Americans, the rate is 15%—less than half the typical ordinary income rate.
2026 Long-Term Capital Gains Tax Brackets (Federal)
| Filing Status | 0% Rate | 15% Rate | 20% Rate | |---|---|---|---| | Single | Up to $47,025 | $47,026 – $518,900 | Over $518,900 | | Married Filing Jointly | Up to $94,050 | $94,051 – $583,750 | Over $583,750 | | Head of Household | Up to $63,000 | $63,001 – $551,350 | Over $551,350 |
*Note: These thresholds apply to your total taxable income, not just the gain itself.*
---
The Net Investment Income Tax (NIIT): The Hidden 3.8%
High-income taxpayers face an additional 3.8% surtax on top of regular CGT rates. This Net Investment Income Tax applies to the *lesser* of your net investment income or the amount by which your modified AGI exceeds:
- $200,000 for single filers
- $250,000 for married filing jointly
---
Asset-Specific Rules
Stocks & ETFs Standard short/long-term rules apply. Qualified dividends receive long-term rates regardless of holding period. Wash sale rules (see below) prevent you from claiming a loss if you repurchase within 30 days.
Real Estate Your primary residence qualifies for the Section 121 exclusion: up to $250,000 of gain ($500,000 for married couples) is tax-free if you've lived in the home for 2 of the last 5 years. Gains above the exclusion are taxed at long-term rates if held over a year. Depreciation recapture on rental property is taxed at a maximum of 25%.
Collectibles (Art, Coins, Antiques) Long-term gains on collectibles are taxed at a flat 28% maximum federal rate—higher than the standard 20% cap.
Cryptocurrency The IRS classifies crypto as property. Every sale, trade, or spend triggers a gain/loss calculation. See our Crypto Tax Calculator for crypto-specific detail.
---
Strategy 1: Tax-Loss Harvesting
If you hold investments at a loss, you can sell them to realize the loss**, then use that loss to offset your gains dollar-for-dollar. After exhausting gains, you can deduct up to **$3,000 of losses against ordinary income per year. Excess losses carry forward indefinitely to future tax years.
The Wash Sale Rule (critical):** You cannot repurchase the *same or substantially identical* security within 30 days before or after the sale for loss. Doing so disallows the loss. This rule applies to stocks and mutual funds—**not currently to cryptocurrency under IRS rules, though this may change legislatively.
---
Strategy 2: Hold for Long-Term Status
The simplest, most powerful CGT strategy: hold assets for at least 366 days before selling. For someone in the 24% ordinary income bracket, this transforms a 24% short-term rate into a 15% long-term rate—a 9-percentage-point saving. On a $50,000 gain, that's $4,500 preserved by waiting a few months.
---
Strategy 3: Timing Gains Across Tax Years
If you're selling near year-end, consider whether recognizing the gain in the *current* year vs. *next* year affects your bracket. A large gain in December might push you into the 20% long-term bracket; waiting until January could keep you at 15%. Similarly, if you expect lower income next year (job transition, early retirement), deferring a sale may mean 0% CGT on long-term gains.
---
How to Report Capital Gains
Capital gains are reported on IRS Form 8949** (each individual transaction) and summarized on **Schedule D** of your Form 1040. Your broker issues a **Form 1099-B each year summarizing all sales, including cost basis for most transactions.
Key deadlines:
- If your gains push your estimated annual tax liability over $1,000, you may need to make quarterly estimated tax payments (Form 1040-ES) to avoid underpayment penalties. Due dates: April 15, June 16, September 15, January 15.
State Capital Gains Taxes
Federal CGT is only part of the picture. Most states tax capital gains as ordinary income at their regular rates:
| State | Long-Term CGT Rate | |---|---| | California | Up to 13.3% (no preferential rate) | | New York | Up to 10.9% | | Oregon | Up to 9.9% | | Texas, Florida, Nevada | 0% (no state income tax) | | Washington | 7% (on gains over $270,000) |
For high earners in California, combined federal + state + NIIT can reach 37.1% on long-term gains.
Frequently Asked Questions
Q: What is the capital gains tax rate for 2026?
A: For 2026, long-term capital gains (assets held over 1 year) are taxed at 0%, 15%, or 20% federally depending on your total taxable income. Single filers with income under $47,025 pay 0%; most middle-income earners pay 15%; those earning over $518,900 pay 20%. Short-term gains (held 1 year or less) are taxed at your ordinary income tax rate, which ranges from 10% to 37%.
Q: Do I owe capital gains tax if I don't sell?
A: No. Capital gains tax is only triggered when you sell (or trade) an asset for a profit—this is called a "realization event." Unrealized gains on assets you still hold are not taxed. You only owe tax in the year you actually sell.
Q: Can I use investment losses to reduce my taxes?
A: Yes. Capital losses can offset capital gains dollar-for-dollar. If your losses exceed your gains, you can deduct up to $3,000 against ordinary income per year. Any remaining losses carry forward to future tax years indefinitely. Be aware of the wash sale rule: you cannot repurchase the same security within 30 days before or after a loss sale or the loss is disallowed.
Q: Is there a capital gains tax on my home sale?
A: If you've lived in your primary residence for at least 2 of the last 5 years, up to $250,000 of profit is excluded from tax ($500,000 for married couples filing jointly) under the Section 121 exclusion. Gains above these thresholds are taxed at long-term capital gains rates if you owned the home for more than a year.
Q: How do I avoid capital gains tax legally?
A: Key legal strategies include: (1) Hold assets over 1 year to qualify for lower long-term rates. (2) Use tax-loss harvesting to offset gains with losses. (3) Max out tax-advantaged accounts (401k, IRA, HSA) where gains grow tax-free or tax-deferred. (4) If selling a home, use the Section 121 exclusion. (5) If in the 0% long-term bracket, consider realizing gains in low-income years. (6) For real estate investment, a 1031 exchange defers gains into the next property.
Example Scenarios
Saves so much time when rebalancing my portfolio. The split between short and long term is essential.
Great for a quick estimate of my tax liability before the end of the fiscal year.
The NIIT section finally explained why my effective rate was higher than I expected. Very thorough.
Official Sources & Authority References
Important Disclaimer
This calculator provides estimates for informational purposes only and does not constitute tax, legal, or financial advice. Tax laws change annually — verify figures with IRS.gov or consult a qualified tax professional before making financial decisions.
Explore More Tools
View All Tools →LLC Filing & Registration Cost Calculator
Estimate the total cost to form and maintain an LLC in any US state, including filing fees and annual taxes.
UK Take Home Pay Calculator 2026/27
Calculate your net salary after Income Tax, National Insurance, and Student Loan repayments.
Mortgage Affordability Calculator
Find out how much home you can afford based on your income, debts, and down payment.