How to invest home sale proceeds in index funds tax efficiently

Closed on my house last month and after paying off the mortgage I'm sitting on a decent chunk of cash. My plan is to put most of it into broad index funds — total market, maybe some international. But I'm trying to figure out how to invest home sale proceeds in index funds tax efficiently before I just dump it all into a taxable brokerage. I did live in the house for over 4 years so I think the exclusion covers my gain, but I got a Form 1099-S at closing and I'm not sure what that means for my return. Beyond that, I don't know if lump sum vs. dollar cost averaging changes anything tax-wise, or whether I should be thinking about which account types to put what funds in. Already maxed my 401k for the year. Using TurboTax and it's asking about the home sale but I'm confused on the exclusion piece.

35 comments

The 1099-S piece trips a lot of people up. Even if your entire gain is excluded under the ownership and use tests, receiving a Form 1099-S means you have to report the sale on Form 8949. You'd put it in Part II (long-term), check box F, enter code H in column (f), and put the excluded gain as a negative number in column (g) so the taxable gain comes out to zero. Without the 1099-S you wouldn't have to report it at all if no gain is taxable. TurboTax should walk you through this if you tell it you got a 1099-S.

Hannah D.

Author

That explains why TurboTax keeps pushing me to that section even though I expected zero tax. So I do need to fill it out, it just washes to zero on Schedule D?

Exactly. The gain flows to Schedule D but the column (g) adjustment zeroes it out. Your taxable gain is zero, it just has to be shown.

Worth double-checking you actually clear the eligibility test before assuming the full exclusion applies. You need 24 months of ownership AND 24 months of use as your main home in the 5 years before the sale — the two periods don't have to overlap perfectly but both have to be met. For a married couple filing jointly the ownership threshold only needs one spouse but residence needs both. Publication 523 on irs.gov has the full eligibility steps. If you're single and owned and lived there 4+ years you should be fine.

I sold my place two years ago and had the same 1099-S situation. I uploaded my closing disclosure, the 1099-S, and my prior year return to taxr.ai and it mapped out exactly which lines on Form 8949 and Schedule D were affected and flagged that my cost basis needed to include the capital improvements I'd done. Ended up with a higher basis, lower gain on paper (still excluded, but good to have right). That improvement-tracking piece is easy to miss when you're focused on where to put the proceeds.

Hannah D.

Author

I hadn't thought about capital improvements at all. I replaced the roof and redid the kitchen. Those add to basis?

Yes — permanent improvements that add value or extend the life of the home increase your adjusted basis. Keeps your gain number accurate even if it's excluded. Keep all the receipts either way.

Correct on the improvements. Publication 551 covers basis of assets and Publication 523's Worksheet 2 specifically lists the basis adjustments for a home sale. Normal repairs don't count, only improvements.

On the actual investing side once the tax piece is sorted — asset location matters more than most people realize. Index funds that are already tax-efficient (total market, S&P 500 trackers) are fine in a taxable brokerage because they distribute very little in the way of short-term gains. If you're also investing in bond funds or REITs, those belong in tax-advantaged accounts like your 401k or an IRA because their income gets taxed as ordinary income in a taxable account.

Lump sum vs. dollar cost averaging is mostly a returns question, not a tax question. Either way your cost basis in the index fund shares is what you paid per share on each purchase date. The tax difference only shows up later when you sell — which lots you sell and whether gains are short or long-term. Holding more than a year before selling any lot is the main lever on the tax rate side.

Hannah D.

Author

So from a pure tax standpoint there's no difference between putting it all in now vs. spreading it over 12 months?

The basis is established lot by lot at purchase regardless. The only tax timing difference is if you're straddling a year end and have dividend distributions land differently, but that's minor.

I'd also look at whether you have room in a Roth IRA before piling everything into taxable. If your income is in range (the IRS instructions for Form 5498 and Publication 590-A have the figures), Roth contributions grow and come out tax-free. Total market index funds in a Roth are about as tax-efficient as it gets because you never pay tax on the gains at all.

Worth noting Roth contributions have annual limits and income phase-outs — the exact numbers change by year so check the current Publication 590-A rather than anything posted here.

Fair point, I should have said that. The limits and phase-outs are in the publication, not something to take from a forum post.

One thing I'd think about in a taxable brokerage: pick index funds with low or zero turnover and ones that don't distribute a lot of capital gains. ETF versions of index funds tend to be more tax-efficient than their mutual fund equivalents for this reason — the creation/redemption mechanism keeps embedded gains lower. Vanguard's patented share class structure is an exception but most of the big total-market ETFs are solid on this.

Hannah D.

Author

Is there a tax form difference between holding an ETF vs. a mutual fund in a taxable account?

Both generate a 1099-B when you sell and a 1099-DIV for distributions. The tax forms are the same, the difference is what shows up in the boxes — ETFs tend to have lower capital gain distributions so less unexpected taxable income during the year.

Dealt with a similar reinvestment situation after my sale and had a decent amount in taxable after the exclusion covered my gain. I gave Taxr my brokerage statements and 1099-DIV from the first partial year and it built out a worksheet showing which distributions were qualified vs. ordinary, and what my blended rate on the account looked like. Helped me decide to shift bond allocations to my IRA instead of the taxable side. Really concrete breakdown of what was actually getting taxed at what rate.

Hannah D.

Author

That's exactly what I need to figure out — how to split between taxable and IRA going forward. Good to know that kind of breakdown is possible without hiring someone full-time.

Don't overlook tax-loss harvesting once you're invested. If the market dips and your index fund lots are underwater, you can sell at a loss and immediately buy a similar but not substantially identical fund to capture the loss on Form 8949 while staying invested. The wash sale rule blocks you from buying back the same fund within 30 days before or after the sale at a loss, so you need to swap to a genuinely different index.

The substantially identical standard is what matters — selling a Vanguard total market ETF and buying a Schwab total market ETF probably doesn't pass that test so you'd likely be fine, but selling one S&P 500 fund and buying another S&P 500 fund tracking the same index is closer to the line. No definitive IRS ruling covers every ETF pair so it's a judgment call.

Right, and the disallowed loss under the wash sale rule gets added to the cost basis of the replacement shares, it doesn't disappear — it just defers. So you're not losing it forever, it shifts.

If your capital losses in a year exceed your capital gains, you can deduct the net loss against other income up to the limit listed in Topic 409 on irs.gov, with the rest carrying forward. So even if tax-loss harvesting produces more loss than you can use this year it doesn't go to waste.

Hannah D.

Author

Good to know the carryforward exists. I was worried that if I over-harvested losses they'd just be stuck.

Came back to this after reading further up — just want to flag that if the home sale happened to involve a section 1031 exchange at any point in the past 5 years, the main home exclusion isn't available. Probably not relevant here but worth a check if anyone reading this thread has a more complicated history with the property.

Publication 523 specifically covers this — a home acquired through a 1031 like-kind exchange within the prior 5 years doesn't qualify for the exclusion. Good catch.

I'd also think about your overall tax bracket before deciding how aggressively to harvest gains vs. defer them. If you end up in a year with lower income — maybe a gap between jobs or a sabbatical — that might be a good time to realize long-term gains at a lower rate. The rate that applies depends on your taxable income that year; Topic 409 covers the breakpoints without you having to guess.

Worth separating two questions: how to report the home sale (the 8949/Schedule D piece) and how to invest the proceeds going forward (the asset location/account type piece). The first has a right answer tied to what's on the 1099-S and your basis. The second is more personal finance than tax, though tax efficiency is a real input. Sounds like you've got enough here to handle both.

Hannah D.

Author

This is a helpful reframe. The 1099-S reporting piece feels clearer now. The investing structure I'll probably map out more carefully once the return is filed.

Qualified dividends from broad index funds are taxed at long-term capital gains rates rather than ordinary income rates, which is another reason total-market equity ETFs in a taxable brokerage aren't as bad as people think. The ordinary income treatment hits bonds and REITs harder, which is what makes the asset location conversation worth having before you allocate.

Circling back to the Form 8949 mechanics since a few people mentioned it: the instructions at irs.gov/instructions/i8949 spell out exactly how to handle a home sale where you got a 1099-S and are claiming the exclusion. Part II, box F, code H, excluded gain as a negative in column (g). Your Schedule D picks it up with no taxable amount flowing through. The form itself isn't complicated once you know which boxes apply.

Hannah D.

Author

Bookmarked that instructions page. I think I can handle it in TurboTax now — it was just the 1099-S plus exclusion combination that had me confused about whether anything was actually reportable.

TurboTax will generate the 8949 automatically once you enter the 1099-S details and confirm you meet the exclusion tests. Just make sure your basis includes improvements so the numbers on the form are accurate.

Last practical note: once you're in index funds in a taxable account, keep records of every purchase lot — date, number of shares, price per share. When you eventually sell, you can specify which lots to sell (highest basis first to minimize gains, or lowest basis if you want to harvest a loss). Your broker tracks this but it's worth understanding the specific identification method vs. FIFO before you need it.