From Dream Home to Tax Trap: Why Planning Matters When Cashing in on Real Estate Gains

Brian Uribe, CPA

Sr. Tax Associate

Summary

Learn the key rules behind the home sale gain exclusion and how proper planning can help avoid surprise tax bills.

A family talking with a real-estate agent

Owning a home is one of the fundamental principles of the American dream. It is typically done with the intention of long-term ownership and the expectation of value appreciation. According to 2025 statistics from the National Association of Realtors, the average home price has increased by 75% for the median sales since 2007, with 35% of homes now priced at $500,000 or more. This leaves room for the possibility that capital gains have accumulated since the purchase of these homes. Without proper planning, taxpayers could face a large tax bill.  

The Revenue Act of 1964 introduced Section 121 – exclusion of gain from sale of principal residence. At the time, it allowed a one-time exclusion of $62,500 ($125,000 for married couples filing jointly) from the gain on the sale of their primary residence. However, this was only applicable to those age 55 or older. Those who did not meet the age requirement followed Section 1034, which allowed gain deferral only if purchasing another property of equal or greater value.  

The modern version of Section 121 was enacted in May of 1997 and replaced both the previous rule and Section 1034. It allows taxpayers to exclude up to $250,000 ($500,000 for married couples filing jointly) from the gain on the sale of their principal residence. For example, if a married couple purchased their home for $500,000 and later sold it for $1 million, they could potentially pay no capital gains tax on the sale.  

To qualify for the exclusion: 

  1. Ownership: Must have owned the property for at least 24 months during the five-year lookback period from the date of the sale.   
  2. Use: Must have lived in the property for at least 24 months during the same five-year lookback period.  
  3. Frequency: The exclusion can be used once every two years.  

The 24-month requirement under both ownership and use does not need to be continuous. Months can be nonconsecutive, as long as the total adds up to two years. If the two-year requirement is not met, a partial exclusion may apply due to a change in job location, health issues or other unforeseen qualifying events. The calculation is based on the number of months the taxpayer met the ownership and use test, divided by 24 months, multiplied by the allowable exclusion ($500,000 joint/$250,000 single).  

Additionally, an unmarried widow or widower may qualify for the $500,000 exclusion if the requirements are met and the home is sold within two years of the spouse’s death. Also, citizenship is not a requirement for the Section 121 exclusion. 

Are there phaseouts?

While there are no income-based phaseouts for the exclusion, there are other important caveats: 

  • The Housing and Economic Recovery Act of 2008 limits the exclusion for those who rented the property before making it their primary residence. The depreciation taken during its rental non-qualified period cannot be excluded from the gain and may need to be recaptured and taxed at the taxpayer’s marginal rate, capped at 25%. 
  • Taxpayers who enjoyed the economic benefit of home office depreciation by using the regular method will also reduce their section 121 exclusion by the amount of deduction taken up to the sale. The depreciation taken must be recaptured at a max rate of 25%. Contrary to the regular method, the simplified method uses a flat $5 deduction for every square foot of your office, up to $1,500 per year (or 300 square feet). This method does not incur a depreciation expense, and it is often preferable to prevent the recapture when the home is later sold. 
Tips 

  1. Keep track of home improvements. Capital improvements can increase the home’s basis and reduce taxable gain. 
  2. Properly document purchase dates, move in and out dates, depreciation taken on the property or home office, and purchase and selling documents.
  3. Homeowners considering a sale should allow enough time for proper planning before December 31. 
  4. Taxpayers contemplating the home office deduction should consider using the simplified method to avoid future issues when claiming the section 121 exclusion.  
  5. If the gain is expected to exceed the exclusion amount, homeowners may also need to account for an additional 3.8% net investment income tax (NIIT).

Conclusion

Although the current exemption amounts have not been updated for inflation since 1997, they still offer significant tax benefits to those who qualify. Tax planning is crucial, as many taxpayers are caught off guard by unexpected tax bills. If you’re thinking about selling your home, contact your wealth advisor to discuss a tax strategy. Mercer Advisors’ tax team will work with your advisor to develop a strategy for you. If you’re not a client and have questions, let’s talk. 

United States Congress, “The Exclusion of Capital Gains for Owner Occupied Housing” Accessed Sept 25, 2025 https://www.congress.gov/crs-product/RL32978?q=%7B%22search%22%3A%22RL32978%22%7D&s=2&r=1

TaxNotes.Com, “Section 121 Legislative History – P.L. 105-34” Accessed Sept 25, 2025 https://www.taxnotes.com/research/federal/usc26/121/legislative-history/105-34 

IRS.GOV, “Topic no. 409, Capital gains and losses” Accessed Sept 25, 2025 https://www.irs.gov/taxtopics/tc409#:~:text=The%20taxable%20part%20of%20a,at%20a%20maximum%2025%25%20rate. 

The Tax Adviser “ Converting a rental or vacation home into a primary residence” Accessed Sept 25, 2025 https://www.thetaxadviser.com/issues/2024/aug/converting-a-rental-or-vacation-home-into-a-primary-residence/ 

Mercer Advisors Inc. is a parent company of Mercer Global Advisors Inc. and is not involved with investment services. Mercer Global Advisors Inc. (“Mercer Advisors”) is registered as an investment advisor with the SEC. The firm only transacts business in states where it is properly registered or is excluded or exempted from registration requirements.

All expressions of opinion reflect the judgment of the author as of the date of publication and are subject to change. Some of the research and ratings shown in this presentation come from third parties that are not affiliated with Mercer Advisors. The information is believed to be accurate but is not guaranteed or warranted by Mercer Advisors. Content, research, tools and stock or option symbols are for educational and illustrative purposes only and do not imply a recommendation or solicitation to buy or sell a particular security or to engage in any particular investment strategy. Hypothetical examples are for illustrative purposes only. For financial planning advice specific to your circumstances, talk to a qualified professional at Mercer Advisors.

Ready to learn more?