Capital Gains Tax Calculator
Estimate your 2026 federal capital gains tax on stocks, crypto, real estate, or any investment — long-term or short-term — including the 3.8% Net Investment Income Tax and your state’s rate. See your total tax and net after-tax profit.
A single filer with $100,000 of other taxable income who sells a long-term asset at a $50,000 gain owes about $7,500 in federal capital gains tax (the 15% rate) — plus any state tax. Held one year or less, that same gain is short-term, taxed as ordinary income at a 24% marginal rate — roughly $11,900. Holding for one more day is often the single most valuable tax decision an investor makes.
2026 Capital Gains Tax Calculator
Your sale
Educational estimate using 2026 IRS figures. Federal + NIIT + a flat state estimate. Excludes losses/carryforwards, the qualified-dividend interaction, AMT, depreciation recapture, and state-specific rules. Not tax advice.
Your 2026 estimate
Long-term · Single| Rate band | Gain taxed here | Tax |
|---|
Because this is a long-term gain and stacks above your other income, it’s taxed at the preferential 15% federal rate rather than your ordinary bracket — a meaningful saving over a short-term sale.
What this calculator does
A capital gains tax calculator estimates what you’ll owe when you sell an investment for a profit. This one uses the 2026 federal figures from IRS Revenue Procedure 2025-32. It takes your gain, how long you held the asset, your filing status, your other taxable income, and your state rate, then returns four numbers that matter: your federal capital gains tax, any Net Investment Income Tax, your estimated state tax, and your net profit after tax.
Capital gains are different from wages in one crucial way: long-term gains get their own, lower set of rates. Understanding whether your sale is long-term or short-term — and how the gain stacks on top of your income — is the difference between paying 0%, 15%, 20%, or your full ordinary rate.
Who should use it
Investors selling stock or crypto, founders and employees with vesting RSUs or exercised options, real-estate investors modeling a sale, and anyone doing year-end tax planning who wants to see the after-tax result before they click “sell.”
This models federal tax on a single realized gain plus NIIT and a flat state estimate. It does not net capital losses or carryforwards, handle depreciation recapture on real estate (taxed up to 25%), the qualified-dividend interaction, collectibles (28%), Section 1202 QSBS exclusions, or every state’s specific rules. For a complex sale, work with a CPA.
Long-term vs. short-term — the distinction that drives everything
If you held the asset more than one year, your gain is long-term and taxed at the preferential rates of 0%, 15%, or 20%. If you held it one year or less, it’s short-term and taxed as ordinary income — the same brackets as your salary, up to 37%.
The one-year clock starts the day after you acquire the asset and ends on the day you sell. Crossing that line can cut the federal rate on a $50,000 gain from 24% (ordinary) to 15% — a swing of thousands of dollars for a single day of patience.
Long-term rates aren’t a flat percentage on the whole gain, either. Your gain stacks on top of your other taxable income, and each slice that lands in the 0%, 15%, or 20% band is taxed at that band’s rate. Someone with modest income can have part of a gain taxed at 0% and the rest at 15%.
The formula
The calculator fills each long-term band in order, exactly the way the IRS worksheet does, then adds NIIT and state tax to show your true total and your net after-tax gain.
2026 long-term capital gains rates
Long-term rates are set by your total taxable income including the gain. Official 2026 breakpoints from IRS Rev. Proc. 2025-32:
| Rate | Single | Married Filing Jointly | Head of Household |
|---|---|---|---|
| 0% | $0 – $49,450 | $0 – $98,900 | $0 – $66,200 |
| 15% | $49,451 – $545,500 | $98,901 – $613,700 | $66,201 – $579,600 |
| 20% | $545,501+ | $613,701+ | $579,601+ |
Married filing separately: 15% starts at $49,450 and 20% at $306,850. Short-term gains use the ordinary 2026 brackets (10%–37%) instead of the table above.
The 3.8% Net Investment Income Tax
On top of the rates above, high earners pay an extra 3.8% surtax on investment income. It applies once your modified adjusted gross income exceeds $200,000 (single) or $250,000 (married filing jointly), and it’s charged on the lesser of your net investment income or the amount you’re over the threshold. These thresholds are set by statute and are not adjusted for inflation, so more taxpayers cross them each year.
Worked examples
Example 1 — Long-term stock sale, California ($50,000 gain)
Single, $100,000 other taxable income, 9.3% state rate.
The gain stacks from $100,000 to $150,000 — entirely inside the 15% long-term band — so federal tax is $50,000 × 15% = $7,500. MAGI is under $200,000, so no NIIT. California taxes gains as ordinary income at roughly 9.3%, adding about $4,650. Total tax ≈ $12,150, leaving a net gain near $37,850. The same sale in Texas or Florida would keep the full $42,500.
Example 2 — Short-term crypto flip, Texas ($50,000 gain)
Single, $100,000 other taxable income, no state income tax.
Held under a year, this is ordinary income. Adding $50,000 to $100,000 pushes through the 22% and 24% brackets, producing about $11,900 in federal tax — roughly $4,400 more than if the same position had been held one more day to qualify for long-term treatment. That gap is the pure cost of impatience.
Example 3 — Low-income year, long-term sale ($30,000 gain)
Single, $30,000 other taxable income, no state tax.
Stacking from $30,000, the first $19,450 of the gain fills the 0% band (up to $49,450) and is taxed at nothing; the remaining $10,550 is taxed at 15% = $1,583. Total federal tax is just $1,583 — an effective rate of 5.3%. This is why selling appreciated assets in a low-income year (a sabbatical, early retirement, a gap year) is one of the most powerful moves in tax planning.
How to interpret your results
Effective rate vs. the headline rate
Your effective rate is total tax divided by the gain. For a pure long-term sale it will land at or below your top band; when part of the gain sits in the 0% or 15% band, it can be far lower. If NIIT or a high state rate applies, it climbs. The effective rate is the honest number to compare a “sell now” decision against.
Timing. Pushing a sale from short-term to long-term, or into a lower-income year, routinely saves more than any other lever. On a $50,000 gain, the long-term vs. short-term choice alone is often worth $4,000–$6,000 — for doing nothing but waiting.
Watch the NIIT and bracket cliffs
A large gain can push your MAGI past the $200k/$250k NIIT threshold, adding 3.8% to the investment income above it, and can spill into the 20% long-term band. Spreading a big sale across two tax years, or pairing it with tax-loss harvesting, can keep you under those lines.
Investor & business uses
Founders, RSUs & stock options
Equity compensation is where the long-term/short-term line bites hardest. RSUs are taxed as ordinary income when they vest; any further gain after vesting is capital gain, long-term only if you hold the shares more than a year. For ISOs, holding long enough for a qualifying disposition converts the entire spread to long-term rates — but watch the AMT interaction.
Real estate investors
A rental sale mixes long-term capital gain with depreciation recapture taxed up to 25% — this tool covers the gain portion; model recapture separately. A 1031 exchange can defer the tax entirely, and the primary-residence exclusion shields up to $250,000 (single) / $500,000 (married) of gain.
Crypto traders
Every disposal — selling, swapping one token for another, or spending crypto — is a taxable event. Frequent trading generates short-term gains at ordinary rates. This calculator lets you see the after-tax reality of a flip before you make it.
Common mistakes
- Miscounting the one-year holding period. It must be more than one year — a sale on the exact anniversary is still short-term. The clock starts the day after purchase.
- Assuming long-term rates are flat. A gain can straddle the 0%, 15%, and 20% bands depending on your income. Only the slice in each band is taxed at that rate.
- Forgetting the 3.8% NIIT. High earners owe it on top of the capital gains rate — it’s easy to overlook and turns a 20% rate into 23.8%.
- Ignoring state tax. Most states tax gains as ordinary income; California and New York add close to 10%+. A few (TX, FL, WA, NV, TN) add nothing.
- Not harvesting losses. Capital losses offset capital gains dollar-for-dollar, and up to $3,000 of net loss offsets ordinary income each year, with the rest carried forward.
- Using the wrong cost basis. Reinvested dividends and wash-sale adjustments change your basis. Getting basis wrong overstates or understates the gain.
Best practices
Hold winners past the one-year mark whenever practical · Harvest losses before year-end to offset gains · Sell in low-income years to capture the 0%/15% bands · Spread very large gains across two tax years to dodge the NIIT and the 20% band · Track cost basis meticulously, including reinvested dividends · Consider donating appreciated long-term assets to charity — you skip the gain entirely and deduct fair market value · Use tax-advantaged accounts (IRA, 401(k), HSA) where gains grow untaxed.
Frequently asked questions
What are the 2026 long-term capital gains tax rates?
What’s the difference between long-term and short-term capital gains?
What is the 3.8% Net Investment Income Tax?
How can I pay 0% on capital gains?
Do I owe state tax on capital gains?
Can capital losses reduce my tax?
How are gains on my home taxed?
How is cryptocurrency taxed?
Does this include depreciation recapture on real estate?
What is the cost basis and why does it matter?
Should I hold just to get the long-term rate?
Is this a substitute for tax advice?
Keep exploring
