Principal Residence Exclusion

The principal residence exclusion is an Internal Revenue Service (IRS) rule that allows people who meet certain criteria to exclude up to $250,000 for single filers or up to $500,000 for married filing jointly in capital gains tax from the profit they make on the sale of their home.

Key Takeaways

  • To qualify for the principal residence exclusion, you must have owned and lived in the property as your primary residence for two out of the five years immediately preceding the sale.
  • The two years do not have to be consecutive.
  • Some exceptions apply for those who become disabled, die, or must relocate for reasons of health or work, among other situations.

Qualifying for the Principal Residence Exclusion

To qualify for the principal residence exclusion, you must pass the ownership and use tests. 

In order to pass the ownership test, you must have owned the property you are selling for at least 24 months out of the five years leading up to the date of sale, which the IRS defines as the closing date. If you are part of a married couple, only one spouse has to be listed as the owner of the property for both to pass the ownership test.

To pass the use test, you must have used the home as your primary residence for at least 730 days (24 months) in the five years immediately preceding the closing date of your home’s sale. If you are half of a married couple, both spouses must have individually used the property for 24 out of the last 60 months in order to qualify for the full principal residence exclusion.

Qualifying for a partial exclusion

If you don’t fully pass the ownership and use tests, and you have a valid excuse for why you couldn’t stay the two years, you can qualify for a partial exclusion with the percentage of the exclusion directly proportional to the percentage of time you were in your home. Valid excuses include moves related to health or to work, or unforeseen circumstances, according to the IRS. If, for example, your excuse is approved and you were in your home for one out of the past five years, then you have met 50% of the use requirement and can qualify for 50% of the exclusion on gains: $125,000 for single filers and $250,000 for married filing jointly.

Exceptions

Prior to 1997, individuals over the age of 55 did not have to pay capital gains taxes on their homes and other property sales. In 2022, these adults have no such privileges, but there are other exceptions to the two-out-of-five-year ownership and use tests. 

Official extended duty

If one or both of the individuals selling a home (in the case of a married couple) is on official extended duty in the Foreign Service, intelligence community, or uniformed services, they can elect to suspend the five-year ownership and use test period for up to 10 years. To meet the qualification of “official extended duty,” an individual must be at a duty station that is at least 50 miles from their main home or residing under government orders in government housing for at least 90 days.

Disability

You may qualify for the full principal residence exclusion if you become physically or mentally unable to care for yourself. You can count time spent in a care facility licensed to care for people with your condition toward your two-out-of-the-past-five-years use requirement.

Death or divorce

In the event of death or divorce, you may be able to meet certain exceptions to the ownership and use test. Widowed spouses can count the time their spouse lived in the home toward the requirement for two out of five years' residence. Divorced spouses may be able to count the time for which their spouse owned the home toward the ownership test but will still have to meet the use test themselves.

Other Ways to Reduce or Avoid Paying Capital Gains Tax

If you are unable to meet the requirements for the principal residence exclusion and you don’t qualify for any of the main exceptions, you may still be able to avoid paying capital gains tax when selling your property. 

1031 exchange

The 1031 exchange is a like-for-like exchange that allows individuals to defer paying capital gains tax on their property sale by immediately investing the proceeds in a substantially similar property. This exchange is only available if you are selling an investment property, and it is a complex process. Consult with a tax professional or a 1031 exchange company to make sure you qualify and complete the steps correctly.

Tax-loss harvesting

If you have an investment with an unrealized loss you are considering selling, you may be able to take advantage of tax-loss harvesting to offset the capital gains from the sale of your home. Keep in mind that selling an investment at a loss just to offset capital gains taxes may not be the best financial decision because the investment you are selling at a loss may rise in value more than the taxes you will be saving. 

Calculate your basis correctly

You pay capital gains tax only on your profit on the home sale, which is the sale price minus your cost basis in the property. Make sure that you correctly calculate your cost basis by including the price you paid for the home, all transaction costs associated with buying and selling the home (real estate agent commissions, title fees, and so on), and any meaningful improvements you made to the property with a useful life of more than one year.

The Bottom Line

The principal residence exclusion is one of the easiest ways to reduce or eliminate capital gains taxes when selling your home. Be sure to live in your home for 24 out of the 60 months prior to your closing date to qualify for the exclusion. As always, when working with complex IRS rules, regulations, exclusions, and exemptions, consider consulting with a tax planning professional to see what is best for your individual situation.

Article Sources
Investopedia requires writers to use primary sources to support their work. These include white papers, government data, original reporting, and interviews with industry experts. We also reference original research from other reputable publishers where appropriate. You can learn more about the standards we follow in producing accurate, unbiased content in our editorial policy.
  1. Internal Revenue Service. “Topic No. 701 Sale of Your Home.” Accessed Jan. 5, 2022. 

  2. Internal Revenue Service. “Publication 523, Selling Your Home: Eligibility Test.” Accessed Jan. 5, 2022.

  3. Internal Revenue Service. “Publication 523, Selling Your Home: Does Your Home Qualify for a Partial Exclusion of Gain?” Accessed Jan. 5, 2022. 

  4. Internal Revenue Service. “Like-Kind Exchanges Under IRC Section 1031.” Accessed Jan. 5, 2022. 

  5. Internal Revenue Service. “Publication 523, Selling Your Home: Basis Adjustments—Details and Exceptions.” Accessed Jan. 5, 2022.