How to Calculate Long-Term Capital Gains Tax (2026)
What counts as a long-term capital gain?
A capital gain is long-term when you sell an asset you have held for more than one year. This applies to stocks, mutual funds, ETFs, real estate, crypto, and most other investment assets. The IRS measures the holding period from the day after you acquired the asset to the day you sold it.
Long-term treatment matters because Congress has deliberately set preferential rates for patient investors. Qualifying means you could pay as little as 0% instead of up to 37% for the same dollar of gain.
2026 Long-Term Capital Gains Rate Brackets
Long-term gains are taxed at one of three rates based on your taxable income (not your gross income). For 2026 (IRS Rev. Proc. 2025-32):
| Rate | Single Filers | Married Filing Jointly | Head of Household |
|---|---|---|---|
| 0% | Up to $49,450 | Up to $98,900 | Up to $66,200 |
| 15% | $49,451 – $545,500 | $98,901 – $613,700 | $66,201 – $579,600 |
| 20% | Over $545,500 | Over $613,700 | Over $579,600 |
Most people — including those with significant gains — pay the 15% rate. The 0% rate is available for lower-income earners, including retirees living off investments.
Step-by-step formula
- Calculate your capital gain: Sale price − Cost basis (purchase price + commissions + improvements)
- Determine your taxable income: Gross income − standard or itemized deductions
- Stack your gain on top of ordinary income: Long-term gains sit above your ordinary income in the tax brackets
- Find your rate: Use the brackets above based on your filing status and the income level where your gain falls
- Apply the rate to your gain: Capital gain × rate = federal tax owed
The 3.8% Net Investment Income Tax (NIIT)
High earners may owe an additional 3.8% NIIT on top of their capital gains rate. It applies to the lesser of your net investment income or the amount your modified adjusted gross income (MAGI) exceeds:
- $200,000 — Single filers
- $250,000 — Married filing jointly
- $125,000 — Married filing separately
This can push the effective top rate to 23.8% on long-term gains (20% + 3.8%). The NIIT is calculated on IRS Form 8960.
Worked example
Suppose you are single with $80,000 in ordinary taxable income and you sell stock for a $55,000 long-term gain.
- Your total income for bracket purposes: $80,000 + $55,000 = $135,000
- The first $49,450 of combined income is in the 0% bracket — but your ordinary income already fills that entirely. So your entire gain falls in the 15% bracket.
- Federal long-term capital gains tax: $55,000 × 15% = $8,250
- No NIIT applies (income is under the $200,000 threshold)
Don't forget state capital gains tax
Most states add their own capital gains tax on top of the federal rates above. Rates range from 0% in Florida, Texas, and Nevada, to over 13% in California. Make sure to account for both when estimating your total bill.
Common strategies to reduce long-term capital gains tax
- Tax-loss harvesting: Offset gains with losses from other investments sold in the same tax year.
- 0% bracket planning: If your income allows, realize gains in years when you fall under the $49,450 (single) threshold.
- Opportunity Zones: Reinvesting gains into a Qualified Opportunity Fund can defer or reduce tax on the original gain and potentially exclude gains on the new investment.
- Charitable giving: Donating appreciated stock directly to charity avoids capital gains tax entirely while generating a deduction.
- Spousal income shifting: Married couples can sometimes structure income to stay in the 0% bracket for part or all of a gain.
These strategies involve complex rules and individual circumstances. Consult a qualified CPA or tax advisor before acting.