Capital Gains Tax Calculator – Short vs Long-Term & Total

Share:
Link copied
Capital Gains Tax Calculator – Short vs Long-Term & Total
FREE CALCULATOR - PRIVATE

Capital Gains Tax Calculator – Short vs Long-Term & Net Estimator

Estimate capital gains tax for short-term vs long-term holding, gain, federal rates 0/15/20%, NIIT 3.8%, state tax and net proceeds.

No account needed
Short vs long
0% 15% 20% + NIIT
Net proceeds
Capital Gains Details
Purchase, sale, holding, income
Purchase Price ($)
Cost basis - Example $50,000
Sale Price ($)
Proceeds before fees - Example $100,000
Holding Period
Determines rate type
Other Taxable Income ($)
For bracket placement - Example $85,000
Filing Status
For 0/15/20% thresholds
State For Tax
State tax on gain
Gain = Sale - Buy | Short = Ordinary brackets | Long = 0/15/20% + 3.8% NIIT over threshold
Your Capital Gains Tax
Enter purchase, sale and holding to see gain, federal tax, NIIT, state tax and net proceeds after tax.
Gain
Net
ESTIMATED CAPITAL GAINS TAX
$0
$50k gain - Long-Term 15%
CAPITAL GAIN
$0
Sale - Buy
FEDERAL RATE
0%
0/15/20% or ordinary
FEDERAL TAX
$0
Gain × Rate + NIIT
NET PROCEEDS
$0
Sale - Tax
Total Tax & Net
Fed + NIIT + State
$0 total
Gain Snapshot
Full math - every bit verified
Purchase & Sale & Gain0
Holding & Income0
Federal Rate Type0
Federal Tax0
NIIT 3.8%0
State Tax0
Total Tax0
Net Proceeds0
Important Disclosure: This capital gains tax calculator and information are for educational purposes only. Not tax, financial, or legal advice. Results are estimates based on inputs you provide. Capital gains brackets, NIIT thresholds, deductions and state rules change. Verify with IRS.gov Publication 550, IRS Schedule D and state revenue department. Inputs are processed in your browser and not sent to a server for this calculator component.

What Is Capital Gains Tax and Why Does Holding Period Change Your Rate?

Capital gain is sale price minus purchase price minus fees. If you bought stock at $50,000 and sold at $100,000, gain $50,000. Tax depends on how long you held. Short-term holding 12 months or less is taxed as ordinary income — same as wages — using federal brackets 10% to 37%. Long-term holding more than 12 months gets lower rates 0%, 15%, 20% based on taxable income, plus possible 3.8% Net Investment Income Tax if income over $200k single or $250k joint.

Example: $50,000 gain short-term at 22% marginal = $11,000 federal. Same $50,000 gain long-term with other income $85,000 single taxable ~$100k total taxable ~$100k + $50k gain? Actually long-term brackets stack on top — first part of gain at 15%, so $50,000×15% = $7,500 federal. Difference $3,500 just by holding over 12 months. Add state — California taxes gain as ordinary 1% to 12.3%, Texas 0%. This calculator shows short vs long, federal rate, NIIT, state and net proceeds.

How To Use This Capital Gains Tool — 4 Quick Steps

Step 1 — Enter purchase and sale price. Purchase example $50,000 cost basis including fees, sale example $100,000 proceeds after fees. Gain = $50,000.

Step 2 — Choose holding period. Short-Term ≤12 months for ordinary brackets, Long-Term >12 months for 0/15/20%. Example long-term selected.

Step 3 — Add other taxable income and filing status. Other income example $85,000 for bracket placement — long-term 0/15/20% thresholds depend on total taxable income including gain. Filing status Single, Joint, Head, Separate changes thresholds — Single 0% up to $48,350, 15% up to $533,400, 20% above.

Step 4 — Select state and calculate. State example California progressive 1% to 12.3% gain as income, Texas 0%. Hit Calculate Capital Gains Tax. See gain, federal rate type, federal tax, NIIT, state tax, total tax and net proceeds sale minus tax.

How It Calculates — Formula & Methodology

Source: IRS Publication 550, IRS Schedule D, IRS Rev Proc 2024-40 for brackets, IRS NIIT thresholds $200k single $250k joint, state revenue departments.

Gain = Sale - Purchase
Short-Term Fed = Gain × Ordinary Marginal Rate from brackets on (OtherIncome + Gain)
Long-Term Rate: 0% up to $48,350 single $96,700 joint, 15% up to $533,400 single $600,050 joint, 20% above
Federal Tax = Gain × LongTermRate
NIIT = Gain × 3.8% if MAGI > $200k single / $250k joint (portion over threshold)
State Tax = Gain × StateRate (flat or progressive on gain)
Total Tax = Federal + NIIT + State
Net Proceeds = Sale - Total Tax

Verification with $50k gain long-term single other income $85k Texas:

  • Purchase $50k Sale $100k Gain $50k long-term
  • Other taxable $85k plus gain $50k total $135k taxable income for threshold placement
  • Long-term rate: Single taxable $135k total falls in 15% bracket (0% up to $48,350, 15% up to $533,400) → 15%
  • Federal tax $50k×15%=$7,500
  • NIIT: MAGI $85k other + $50k gain = $135k under $200k single threshold → $0 NIIT
  • State Texas 0% → $0 state
  • Total tax $7,500 Net proceeds $100k-$7,500=$92,500 gain after tax $42,500
  • Short-term same gain other $85k ordinary brackets: $85k other taxable + $50k gain total $135k marginal 22% bracket → federal approx $50k×22%=$11,000 total $11,000 net $89,000

Guards: gain floor 0 (loss → $0 tax), purchase/sale floor 0, NIIT 3.8% only on portion over threshold, state 0-13 capped, non-finite→0.

What Results Mean — Only Necessary Details

Capital Gain: Sale minus purchase. Example $100k-$50k=$50k gain. Loss shows $0 tax.

Federal Rate: For short-term, ordinary marginal rate from brackets on total income. Example 22% at $85k other + $50k gain single. For long-term, 0/15/20% rate based on total taxable income. Example 15% at $135k total single.

Federal Tax: Gain × federal rate. Short-term $50k×22%=$11k, long-term $50k×15%=$7,500.

NIIT 3.8%: Net Investment Income Tax 3.8% on gain if MAGI over $200k single $250k joint. Example MAGI $135k → $0, MAGI $210k single $10k over → $10k×3.8%=$380 NIIT on portion over.

State Tax: Gain × state rate. Texas 0%, Illinois flat 4.95% $50k×4.95%=$2,475, California progressive 9.3% at $85k income $50k×9.3%=$4,650.

Total Tax & Net Proceeds: Total = Federal + NIIT + State. Example long-term Texas $7,500 total net $92,500 proceeds, gain after tax $42,500. Short-term same Texas $11,000 total net $89,000.

Example — Varied Comparisons

Base: Buy $50k Sell $100k Gain $50k Long-Term Single Other $85k Texas → Gain $50k Rate 15% Fed $7,500 NIIT $0 State $0 Total $7,500 Net $92,500.

Short-Term vs Long-Term same $50k gain $85k other single Texas: Short-Term ordinary 22% Fed $11,000 Total $11,000 Net $89,000 vs Long-Term 15% Fed $7,500 Total $7,500 Net $92,500 — long-term saves $3,500.

California vs Texas $50k gain long-term: CA 9.3% marginal state $50k×9.3%=$4,650 Fed $7,500 Total $12,150 Net $87,850 vs Texas Total $7,500 Net $92,500 difference $4,650 due to state.

Higher other income $200k single vs $85k $50k gain long-term: Other $85k total $135k 15% Fed $7,500 NIIT $0 vs Other $200k total $250k 15% still? Actually at $200k other + $50k gain = $250k total still 15% but MAGI $250k single over $200k threshold $50k over → NIIT $50k×3.8%=$1,900 additional total $9,400 vs $7,500.

Loss scenario $40k sale $50k buy: Gain -$10k loss → $0 federal $0 state total $0 net $40k proceeds loss no tax — loss may offset other gains per IRS rules not modeled here.

Common Mistakes

  1. Forgetting holding period: ≤12 months short-term ordinary up to 37% vs >12 months long-term 0/15/20%. Holding 11 months vs 13 months changes tax $3,500 on $50k gain at 22% vs 15%.
  2. Ignoring other income for long-term thresholds: 0/15/20% depends on total taxable income including gain. Other income $85k + gain $50k total $135k → 15%, not 0%.
  3. Missing NIIT 3.8%: Over $200k single MAGI additional 3.8% on gain portion over threshold. Example $210k MAGI $10k over $50k gain → $10k×3.8%=$380 extra.
  4. Using purchase without fees: Cost basis should include broker fees and commissions, sale price after fees. Using gross sale inflates gain and tax.
  5. Forgetting state taxes gain as ordinary: California taxes capital gain as ordinary income 1% to 12.3%, not lower 15%. Texas 0% vs California 9.3% difference $4,650 on $50k gain.

Practical Tip

Hold over 12 months for long-term rates if you can — saves ordinary vs 15% often 7% to 22% difference. Harvest losses — sell losing positions same year to offset gains per IRS wash sale rules. If near NIIT threshold $200k single, defer gain to next year or use installment sale to spread gain below threshold. Check state — move from California to Texas before sale saves state tax but residency rules apply.

Important Limitations

This tool provides estimates for educational purposes only. Not tax, financial, or legal advice. Results depend on inputs you provide. Capital gains brackets, NIIT thresholds, standard deduction, state rates and rules change. Does not include qualified dividends, collectibles 28% rate, unrecaptured Section 1250 25% rate, wash sale, loss carryforward, QBI, AMT, or detailed Schedule D calculations. NIIT calculation simplified to portion over threshold. Verify with IRS Publication 550, Schedule D and state revenue department. Inputs are processed in your browser and not sent to a server for this calculator component.

Frequently Asked Questions

How is capital gains tax calculated?

Gain = sale price minus purchase price minus fees. Short-term holding 12 months or less taxed as ordinary income using federal brackets 10% to 37%. Long-term holding over 12 months taxed at 0%, 15%, 20% based on taxable income plus 3.8% NIIT if income over $200k single or $250k joint.

What is difference between short and long-term?

Short-term is asset held 12 months or less, taxed as ordinary income. Long-term is held more than 12 months, taxed at lower 0/15/20% rates. Example $50k gain short-term at 22% marginal = $11k federal, long-term at 15% = $7,500.

What are long-term rates 0/15/20%?

Long-term rates depend on taxable income. Single: 0% up to about $48,350, 15% up to $533,400, 20% above. Joint: 0% up to $96,700, 15% up to $600,050, 20% above. Thresholds adjust annually per IRS.

What is NIIT 3.8%?

Net Investment Income Tax 3.8% applies to capital gains if modified AGI over $200k single, $250k joint, $125k married separate. Example $50k long-term gain with MAGI $210k single adds $1,900 NIIT on top of 15%.

Is state tax included?

State tax uses selected state model. No-tax states 0%, flat states like Illinois 4.95% times gain, progressive states like California tax gain as ordinary income 1% to 12.3%.

Does this include fees?

Enter sale price after broker fees and purchase price including fees. Use net gain for accurate tax. This calculator uses gain you enter.

Does this calculator save data?

No. Calculation runs in your browser. Inputs are not sent to a server for this calculator component. Closing tab clears values.

MM Ahmed - FinProUSA Editorial Team

Written and reviewed by MM Ahmed — FinProUSA Editorial Team

Senior Finance Writer | Content reviewed for Accuracy and Compliance, 10 years experience | Editorial Methodology

U.S. personal-finance calculator content prepared for educational purposes using publicly available authoritative sources, documented calculations, and page-specific methodologies. Results are estimates based on the information and assumptions entered and do not constitute financial, tax, legal, or investment advice.

Last reviewed: October 10, 2026 | Fact-checked for calculations, IRS 2026 brackets, and methodology | Reviewed for content, calculations, sources, and methodology.
Sources: IRS.gov, CFPB, SSA.gov, FHFA — linked on each applicable page.
FinProUSA is an independent educational website and is not affiliated with or endorsed by any lender, bank, issuer, government agency, or other organization referenced on this page.

Where applicable, calculator results are generated in your browser. Calculator values are not sent to FinProUSA's server for calculation. Figures are generally presented in U.S. dollars unless otherwise stated.

Sources and methodology may vary by calculator and are provided on the applicable page. See our Editorial Policy and Disclaimer. For personalized financial, tax, legal, or investment advice, consult an appropriately qualified professional.

Customize Cookie Preferences

Manage your consent preferences. Necessary cookies are always enabled for site functionality.

Necessary (Always Active)
Analytics (Google Analytics)
Advertising (AdSense)
Personalization