So let’s talk about a tax that most people have never heard of until the year it costs them tens of thousands of dollars. It’s called the Net Investment Income Tax, or NIIT, and if you’ve owned your Bay Area home for twenty or thirty years and you’re starting to think about selling, this one has your name on it. I bring it up with nearly every longtime homeowner I sit down with, and the reaction is almost always the same: a long pause, and then some version of “wait, there’s another one?”
Yes, there’s another one. The good news is that the NIIT is one of the more manageable taxes in the stack if you see it coming. The bad news is that almost nobody sees it coming, because for most of your life it simply doesn’t apply to you, and then in one single year, the year you sell the house, it shows up with its hand out. Let’s walk through what it is, who it hits, why it exists in the first place, and what you can actually do about it.
What Is the Net Investment Income Tax?
The Net Investment Income Tax is a 3.8% federal surtax on investment income, created under Section 1411 of the Internal Revenue Code. It sits on top of your regular capital gains tax; it doesn’t replace anything, it just stacks. Think of it as a toll booth that only appears on the road once your income crosses a certain line.
Here’s the mechanical part, and it’s worth understanding because the mechanics are where the planning opportunities live. The NIIT applies to the lesser of two numbers: your net investment income for the year, or the amount by which your modified adjusted gross income (MAGI) exceeds a threshold. That threshold is $200,000 for single filers and $250,000 for married couples filing jointly. Whichever of those two numbers is smaller, you pay 3.8% of it.
And what counts as investment income? More than you’d think. Interest, dividends, capital gains, rental income, royalties, annuity income, and passive business income all land in the bucket. What doesn’t count is just as important: wages, Social Security benefits, self-employment income from a business you actively run, and distributions from retirement accounts like your 401(k) or IRA. Keep that last one in mind, though, because there’s a wrinkle. Retirement account distributions aren’t investment income themselves, but they do raise your MAGI, which can push you over the threshold and expose your other investment income to the tax. It’s a bit like a teammate who never scores but keeps setting up the other team; you have to watch him anyway.
Who Does the NIIT Impact?
On paper, the NIIT is a tax on high earners. A $250,000 threshold for a married couple sounds like it’s aimed at somebody else. In practice, here in Silicon Valley, it’s aimed at two groups: households with strong dual incomes, who bump into it every April, and, more importantly for our purposes, ordinary longtime homeowners who cross the threshold exactly once in their lives, in the year they sell the family home.
Here’s why. When you sell a home you’ve held for decades in Los Gatos or Cupertino or San Jose, the taxable gain from that one transaction gets added to your income for the year. A retired couple living comfortably on $90,000 a year can suddenly have a seven-figure MAGI, and for that one tax year, the IRS treats them exactly like the highest earners in the country. Sadly, there’s no carve-out for “we only look rich this year.”
And there’s a detail that makes this worse every single year: the NIIT thresholds are not indexed for inflation. Congress set $200,000 and $250,000 back when the tax took effect in 2013, and they haven’t moved since. If that sounds familiar, it should. It’s the same story as the Section 121 home sale exclusion, frozen at $250,000 and $500,000 since 1997 while Bay Area home values multiplied several times over. Every year these fixed numbers stand still, inflation drags more ordinary households across the line without anyone in Washington lifting a finger. A tax that was sold as a tax on the wealthy has become, for homeowners in high-cost markets, a tax on staying put for thirty years.
One more group worth mentioning: trusts and estates get hit at a dramatically lower threshold, one that kicks in around the top trust tax bracket, which is a tiny fraction of the individual thresholds. Most families holding a home in a standard revocable living trust don’t need to worry, since those are taxed to you as an individual while you’re living. But if there’s an irrevocable trust in your family picture, or you’re settling an estate, this is a conversation to have with your tax professional sooner rather than later.
Why Does the NIIT Exist?
The NIIT was born in 2010 as part of the legislation that accompanied the Affordable Care Act, and it took effect on January 1, 2013. You’ll sometimes hear it called the “Medicare surtax,” and the nickname tells you the story Congress was telling at the time. Wage earners pay Medicare taxes on every paycheck, but investment income, the kind of income that tends to flow to wealthier households, contributed nothing toward Medicare. The 3.8% rate wasn’t pulled out of a hat; it matches the combined Medicare tax rate on wages, including the additional Medicare tax high earners pay. The idea was to make a dollar of dividends carry the same load as a dollar of salary.
Whether it worked out that way is a fair question. Technically, NIIT revenue goes to the general fund rather than into the Medicare trust fund, so the “Medicare tax” label is more branding than plumbing. And because Congress never indexed the thresholds, the tax reaches further down the income ladder every year, catching households the original drafters probably never pictured, including retired schoolteachers in Willow Glen whose only crime was buying a house in 1985 and taking good care of it.
I’ll leave the politics to others. What matters for you is simpler: the tax exists, it isn’t going anywhere on its own, and the year you sell your home is very likely the year it finds you.
What the NIIT Looks Like When You Sell Your Home
Let’s put real numbers on it, because 3.8% sounds small until you see what it’s 3.8% of.
Say you and your spouse bought your home in 1988 for $300,000 and you sell it this year for $2.5 million. Your gain is $2.2 million. The Section 121 exclusion knocks out $500,000, leaving $1.7 million of taxable gain (we’ll set aside basis adjustments for the moment, though as I’ll explain in a minute, you shouldn’t). Your MAGI for the year is now far beyond the $250,000 threshold, so the NIIT applies to the full $1.7 million of investment income. That’s 3.8% of $1.7 million, or about $64,600, stacked on top of the 20% federal capital gains rate and California’s ordinary income treatment, which runs as high as 13.3%. The NIIT alone, a tax you may never have heard of before this article, costs more than many people’s first house.
That’s the blindside. Now let’s talk about the playbook.
How Can You Avoid or Reduce the NIIT?
The first move is to shrink the gain itself, because every dollar you remove from taxable gain escapes the NIIT, the federal capital gains tax, and California’s tax all at once. That starts with rebuilding your cost basis. Every capital improvement you’ve made over the decades, the roof, the addition, the kitchen, the sewer lateral, the retrofit, adds to your basis and comes straight off the gain. Families who do the paperwork archaeology, and I’ve watched them do it, routinely document hundreds of thousands of dollars in improvements. At a combined tax rate that can approach 37%, finding $300,000 of basis in the garage file cabinet is worth over $100,000 in real money. Nobody gets paid better per hour than the person who finds the 2003 remodel receipts.
The second move is to manage the threshold side of the equation, and this is where timing earns its keep. Remember, the NIIT only applies once your MAGI crosses the line, and it applies to the lesser of your investment income or the amount over the line. Selling in a year when your other income is low, say, the gap years after you stop working but before Social Security and required minimum distributions begin, keeps more room under the threshold. For the same reason, be careful about stacking a big IRA withdrawal, a Roth conversion, and a home sale into the same tax year. Those retirement distributions aren’t investment income, but they inflate your MAGI and expose more of your gain to the surtax. Spreading the events across tax years can save real money for the price of a calendar.
The third move, for larger gains, is to spread or redirect the gain itself. An installment sale, where you carry financing for the buyer and receive payments over a period of years, spreads the gain across multiple tax years, and in each of those years the threshold test starts fresh. A charitable remainder trust can convert a highly appreciated home into a lifetime income stream while removing the gain from the year of sale, which suits families with charitable intentions anyway. And if the property is a rental rather than your residence, a 1031 exchange defers the gain, and the NIIT along with it, entirely. These are sophisticated tools with real tradeoffs, which is exactly why the five-years-out conversation beats the five-weeks-out conversation every time.
The Bottom Line
The Net Investment Income Tax is a 3.8% surtax that was designed for the wealthy and, thanks to frozen thresholds and Bay Area appreciation, now waits at the finish line for almost every longtime homeowner who sells. You can’t repeal it, but you can plan around it: rebuild your basis, watch your MAGI in the year of sale, and put the calendar to work spreading or timing the gain. The families who pay the most are almost never the ones with the biggest gains; they’re the ones who found out about the tax in escrow.
Senior Friendly Homes in Silicon Valley South
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25


