The net investment income tax (NIIT) is a 3.8% U.S. federal tax that can apply to investment income when your modified adjusted gross income (MAGI) exceeds the threshold for your filing status. The rate applies to the smaller of your net investment income and the amount your MAGI is over the threshold. The tax is in addition to regular federal income tax. (IRS Topic 559)
A single filer can earn less than $200,000 in wages and still owe NIIT after selling stock. The taxable gain can increase both the investment income subject to the tax and the total income used to test the threshold.
Who pays the net investment income tax in 2026?
You owe NIIT when you have positive net investment income and MAGI above the threshold for your filing status. The individual thresholds are fixed in federal law and apply for tax year 2026.
| Filing status | 2026 MAGI threshold |
|---|---|
| Single | $200,000 |
| Head of household | $200,000 |
| Married filing jointly | $250,000 |
| Married filing separately | $125,000 |
| Qualifying surviving spouse | $250,000 |
Estates and trusts use a separate calculation based on their undistributed net investment income and the point where their highest income tax bracket begins.
How to find your MAGI for NIIT
Start with adjusted gross income (AGI) on Form 1040. It includes items such as taxable wages, interest, dividends, capital gains, and taxable retirement withdrawals. AGI already reflects eligible adjustments to income and is calculated before the standard deduction or itemized deductions.
If you’re projecting wages from a pay stub, use the federal taxable wages figure. See the difference between gross pay and take-home pay when reading your pay stub.
For most filers, the AGI on Form 1040 is also their MAGI for NIIT. If you claimed the foreign earned income exclusion or have interests in certain foreign corporations or funds, use the MAGI worksheet. (IRS instructions for Form 8960)
What counts as net investment income?
Start with taxable investment income and gains. Then account for applicable losses and deductions that federal rules allow and that you can allocate to that income. Form 8960, for example, allows certain deductible investment interest expenses.
| Income source | How NIIT treats it |
|---|---|
| Taxable bank interest, CDs, and corporate bond interest | Generally included. |
| Stock and fund dividends, including qualified dividends | Generally included, even when you reinvest the dividend. |
| Taxable gains from stocks, funds, and investment property | Generally included. Both short- and long-term gains can count. |
| Passive business income, rents, and royalties | Generally included. The trade or business rules can change the treatment. |
| Nonqualified annuities | Taxable earnings generally count. |
| Wages and bonuses | Excluded from investment income. Taxable amounts can increase MAGI. |
| Traditional IRA and 401(k) distributions | Excluded from investment income. Taxable amounts can increase MAGI. |
| Federally tax-exempt municipal bond interest | Generally excluded from both net investment income and NIIT MAGI. |
What if you own a rental or a business?
Passive rental and business income generally counts. For a rental that qualifies as a trade or business, whether the activity is passive to you can change the result. A business trading financial instruments or commodities has its own inclusion rule. Earnings already subject to Medicare self-employment tax are excluded from NIIT. If you receive a Schedule K-1 or claim real estate professional status, check the activity-specific rules before classifying the income.
How to calculate the net investment income tax
- Find your MAGI excess. Subtract your filing-status threshold from your MAGI. Use $0 if the result is below zero.
- Find your net investment income. Use the amount after allowable losses and properly allocable deductions. Use $0 for the estimate if you have a net investment loss.
- Multiply the smaller amount by 0.038. A zero in either step makes the tax $0.

Four examples of the 3.8% calculation
Each row uses the full tax year’s MAGI and net investment income after applicable adjustments.
| Filing status | MAGI | Net investment income | MAGI above threshold | NIIT |
|---|---|---|---|---|
| Single | $208,000 | $25,000 | $8,000 | $304 |
| Married filing jointly | $310,000 | $18,000 | $60,000 | $684 |
| Single | $200,000 | $12,000 | $0 | $0 |
| Single | $275,000 | $0 | $75,000 | $0 |
In the first case, $183,000 of taxable wages plus a $25,000 stock gain puts the filer $8,000 over the $200,000 threshold. Multiplying $8,000 by 3.8% gives $304 of NIIT.
In the second case, suppose the couple’s MAGI includes $20,000 of taxable interest. The couple also has a $2,000 allowable itemized deduction for investment interest expense that is fully allocable to that income. Their net investment income falls to $18,000. Because $18,000 is less than their $60,000 MAGI excess, the tax is $684.
Does NIIT apply to capital gains?
Yes, taxable net capital gains from investments can be subject to NIIT as well as regular federal capital gains tax. For example, the part of a long-term gain taxed at 15% and also subject to the full 3.8% NIIT carries a combined federal rate of 18.8% across those two taxes. How much of the gain faces NIIT depends on the smaller-amount calculation. If you’re new to investing, see the tax basics for beginner investors.
What happens when you sell your home?
The part of a main-home gain you can exclude from regular federal income tax is also excluded from NIIT. Eligible filers can exclude up to $250,000 of gain, or up to $500,000 if married filing jointly and they meet the joint exclusion requirements. To estimate the gain, subtract your adjusted basis from the sale proceeds after eligible selling expenses. Your adjusted basis can reflect items such as capital improvements and prior depreciation. (IRS Publication 523)
Suppose you’re single and your main-home sale brings in $700,000 after selling expenses. Your adjusted basis is $400,000, so your gain is $300,000. If you qualify for the full $250,000 exclusion, $50,000 of gain is taxable. Add that to $175,000 of other MAGI and you get $225,000. Assuming the taxable home gain is your only net investment income, NIIT is $25,000 × 3.8% = $950.
Can a Roth conversion or IRA withdrawal trigger NIIT?
Yes, indirectly. A taxable traditional IRA withdrawal or Roth conversion can raise MAGI and make existing taxable dividends, interest, or gains subject to NIIT. The withdrawal or conversion itself is excluded from net investment income. Qualified Roth IRA withdrawals are generally tax-free and outside both figures. (Treasury regulations on retirement plan distributions)
For the two-step funding strategy, see our backdoor Roth IRA guide. It explains how nondeductible basis and the pro-rata rule affect the taxable conversion amount.
Say you’re single and your MAGI is $190,000, including $12,000 of taxable dividends that make up all your net investment income. A fully taxable $20,000 Roth conversion raises your MAGI to $210,000. You’re now $10,000 over the threshold, so $10,000 of your dividends is subject to NIIT. The result is $380 of NIIT, plus any regular income tax due on the conversion. To see how your after-tax income and monthly spending affect withdrawals over time, start with this guide to estimating how long retirement savings will last.

How to report NIIT on Form 8960
Gather Forms 1099-INT for interest, 1099-DIV for dividends, and 1099-B for brokerage sales as applicable. Keep your cost-basis records. Form 1099-DIV box 1a already includes the qualified dividends shown in box 1b.
- Part I lists investment income and adjustments, including reportable gains and applicable rental or pass-through income.
- Part II applies allowable investment expenses and other adjustments to get net investment income.
- Part III calculates the tax. Carry it to Schedule 2 (Form 1040) and attach Form 8960 to your return.
Use the final form and instructions for the year you’re filing. On the final 2025 forms, the amount goes from Form 8960 line 17 to Schedule 2 line 12. (IRS Form 8960 and instructions)
How to plan for a large gain before you sell
- Estimate the tax for each feasible sale year. Include the proposed gain, other realized gains and losses, and any bonuses or taxable withdrawals you expect. Compare the full after-tax proceeds of each scenario.
- Check which capital losses can offset your gain. If you buy substantially identical stock or securities within 30 days before or after selling at a loss, the wash-sale rule can disallow the current deduction. (IRS Publication 550)
- Include NIIT when you review withholding or estimated payments. A late-year gain can leave projected federal payments short. For uneven income, see the annualized income installment method in IRS Publication 505.
Frequently asked questions
Do unrealized gains count toward NIIT?
For ordinary buy-and-hold investments, an increase in market value while you hold the asset generally stays outside the calculation. A later taxable sale can create a gain. Taxable dividends or a fund’s capital gain distributions can count while you still hold the shares.
Does NIIT apply to crypto gains?
A taxable gain from selling or exchanging crypto you held as an investment can count toward NIIT. Your overall liability still depends on net investment income and MAGI.
Can you owe NIIT and the Additional Medicare Tax in the same year?
Yes. The 0.9% Additional Medicare Tax applies to certain Medicare wages, self-employment income, and railroad retirement compensation above applicable thresholds. A filer with enough eligible earned and investment income can owe both taxes.








Comments 2