Taxes & IRS

US Capital Gains Tax & 3.8% NIIT Calculator

Compute short-term vs long-term federal capital gains tax across the 0%, 15%, and 20% brackets plus the 3.8% Net Investment Income Tax (NIIT) on stocks, crypto, or real estate.

Quick Example Scenarios
Estimated Breakdown
$15,992 tax
Net gain kept $84,008 on $100,000 profit (15.99% effective federal rate)
Realized Capital Gain or Loss$100,000
Tax Rate ScheduleLong-Term (0% / 15% / 20%)
Federal Base Capital Gains Tax$15,000
3.8% Net Investment Income Tax (NIIT)$992
Effective Tax Rate on Gain15.99%
Total Estimated Federal Capital Gains Tax$15,992
Net Profit After Federal Tax$84,008
Methodology: 2026 IRS long-term capital gains brackets (0% up to $49,450 Single / $98,900 MFJ / $66,200 HoH; 15% up to $545,500 / $613,700 / $579,600; 20% above) stacked on ordinary taxable income, plus IRC Sec. 1411 3.8% NIIT above $200k/$250k MAGI

US Capital Gains Tax Calculator Quick Answer & Reference Basis

In the baseline scenario, the estimated US Capital Gains Tax Calculator result is $15,992 tax (Net gain kept $84,008 on $100,000 profit (15.99% effective federal rate)). Top computed line items: Realized Capital Gain or Loss: $100,000, Tax Rate Schedule: Long-Term (0% / 15% / 20%), Federal Base Capital Gains Tax: $15,000.

Calculation standard: 2026 IRS long-term capital gains brackets (0% up to $49,450 Single / $98,900 MFJ / $66,200 HoH; 15% up to $545,500 / $613,700 / $579,600; 20% above) stacked on ordinary taxable income, plus IRC Sec. 1411 3.8% NIIT above $200k/$250k MAGI. Verified on .

Short-Term vs Long-Term Capital Gains & 3.8% NIIT Impact

Benchmark outputs across common income, loan, or balance tiers. Adjust any input field above to recalculate your exact numbers immediately.

Scenario Primary Estimate Realized Capital Gain or Loss Total Estimated Federal Capital Gains Tax
$40k Long-Term ($55k Income, Single)$6,000 tax$40,000$6,000
$100k Long-Term ($110k Income, Single)$15,992 tax$100,000$15,992
$100k Short-Term ($150k Income, Single)$30,370 tax$100,000$30,370
$400k Long-Term ($300k Income, Married)$79,515 tax$400,000$79,515

Stacking Long-Term Capital Gains Brackets and Surviving the 3.8% NIIT

Holding an appreciated stock, ETF, cryptocurrency position, or investment property for more than one full year (one year plus at least one day from trade acquisition to sale date) unlocks preferential federal long-term capital gains rates of 0%, 15%, or 20%. Assets sold within 365 days or less generate short-term capital gains, which are stacked directly onto your regular taxable income and taxed at ordinary federal rates rising as high as 37%.

Long-term capital gains sit on top of your ordinary taxable income when determining which slice falls into each rate tier, rather than pushing your wage income into higher brackets. If a Single filer has $35,000 of ordinary taxable income in 2026 and realizes a $30,000 long-term gain, the first $14,450 of gain fills the remainder of the $49,450 zero-percent bucket at 0% federal tax, and only the remaining $15,550 spills into the 15% tier.

Under Internal Revenue Code Section 1411, higher-earning investors also owe a 3.8% Net Investment Income Tax (NIIT) on the lesser of net investment income or the amount by which Modified Adjusted Gross Income exceeds $200,000 ($250,000 for Married Filing Jointly). Because Congress never indexed those statutory $200,000 and $250,000 thresholds for inflation, effective top-bracket federal capital gains tax peaks at 23.8% plus applicable state taxes.

Careful tax-lot selection (Specific ID rather than First-In-First-Out) and strategic tax-loss harvesting let investors offset short-term gains first, up to $3,000 of ordinary income per year, and carry surplus realized losses forward indefinitely without altering core asset allocation.

Year-End Capital Gains Tax & Loss Harvesting Checklist

Federal Tax & Filing FAQ

Q. How long must I hold shares to qualify for long-term capital gains rates?

You must hold the asset for strictly more than one year, meaning at least one year plus one day from the trade purchase date to the trade sale date.

Q. Can capital losses offset my capital gains and W-2 salary?

Yes. Realized capital losses first offset capital gains dollar for dollar. If total losses exceed total gains, you can deduct up to $3,000 ($1,500 if Married Filing Separately) against ordinary income each year and carry unused losses forward indefinitely.

Q. Does selling a primary home face the same tax calculation?

Under IRC Section 121, homeowners who lived in and owned their primary residence for at least 2 of the last 5 years can exclude up to $250,000 of profit ($500,000 for Married Filing Jointly) before capital gains tax applies. Only taxable gain above that exclusion enters long-term capital gains and NIIT calculations, while non-deductible home improvements verified by receipts raise your cost basis.

Q. Does the 30-day wash-sale rule apply to cryptocurrency losses?

Traditional stocks, ETFs, and mutual funds are strictly governed by the 30-day IRS wash-sale rule across taxable and IRA accounts, whereas taxpayers trading spot digital assets should check current-year IRS reporting Form 1099-DA and Wash Sale legislation updates with a CPA.

Related US Tax & Finance Calculators