Home sales often occur during or shortly after a divorce. With real estate values still at or near historical highs in many areas, the federal income tax exclusion for gains on the sale of a principal residence can help. However, divorcing individuals must plan carefully to maximize this tax break.
Gain Exclusion Basics
An unmarried person can sell a principal residence and exclude — that is, pay no federal income tax on — up to $250,000 of gain. A married couple filing jointly can exclude up to $500,000. However, homeowners must pass the following tests to qualify:
Ownership test. You must have owned the property for at least two years during the five-year period ending on the sale date.
Use test. You must have used the property as your principal residence for at least two years during the same five-year period.
Joint-filer test. To claim the larger $500,000 joint-filer gain exclusion, at least one spouse must pass the ownership test, and both spouses must pass the use test.
Important: Whether filing individually or jointly, you can't claim the exclusion if you already claimed it on another home sale within the previous two years.
Three Scenarios
Here are three scenarios to consider:
Scenario 1: You sell this year and are still married at year end. Say you're in the process of divorcing, and you sell your principal residence. If you're still legally married at the end of the year of the sale, because the divorce isn't yet final, you're considered married for the entire year for federal income tax purposes. In this scenario, you can shelter up to $500,000 of home sale gain in two different ways.
First, you and your soon-to-be ex can file jointly for the year and claim the joint-return gain exclusion of up to $500,000. Alternatively, you and your soon-to-be ex can file separately. In this case, assuming the home is owned jointly or as community property, you can each exclude up to $250,000 of the gain. To qualify for separate gain exclusions, you and your soon-to-be ex must each have 1) owned your share of the home for at least two years during the five-year period ending on the sale date, and 2) used the home as your principal residence for at least two years during that period.
Scenario 2: You sell in the year of your divorce or shortly thereafter. If you're divorced at the end of the year in which you sell your principal residence, you're considered divorced for the entire year for federal income tax purposes. In this scenario, you can't file a joint return with your former spouse for the year of the sale or (obviously) any year thereafter.
Say you wind up owning some percentage of the home after the divorce, and your ex owns the rest. When the home is eventually sold, both you and your ex can exclude up to $250,000 of your respective shares of the gain, as long as each of you 1) owned your part of the home for at least two years during the five-year period ending on the sale date, and 2) used the home as your principal residence for at least two years during that five-year period.
Alternatively, say you wind up with sole ownership of the residence after the divorce. Your maximum gain exclusion is $250,000 because you're now single. However, if you remarry and live in the home with your new spouse for at least two years before selling, the larger $500,000 joint-filer exclusion becomes available again.
Scenario 3: You continue to own the home after the divorce but don't live there. In many cases, ex-spouses continue to co-own a former marital residence for a long time after divorcing — even though only one ex still lives there. In this scenario, it can be tricky for the nonresident ex to qualify for the gain exclusion when the home is eventually sold. This is because, after three years of being out of the house, the nonresident ex will fail the two-out-of-five-years use test. So, if the home is sold later for a gain, the nonresident ex's share will be fully taxable.
Fortunately, you can solve this problem with proper planning. If you'll be the nonresident ex, negotiate into the divorce agreement a stipulation that your ex can continue to occupy the home:
- For as long as he or she wants,
- Until the kids reach a certain age,
- For a specified number of years, or
- Some other mutually agreeable period.
Once the specified date is reached, the home can either be put up for sale with the proceeds split according to the divorce agreement, or one ex can buy out the other's share.
This stipulation in the divorce agreement effectively allows you, as the nonresident ex, to receive "credit" for your ex's continued use of the property as a principal residence. So, when the home is finally sold, you'll pass the two-out-of-five-years use test and qualify for the $250,000 gain exclusion — even though you haven't lived in the home for years.
An Example
Joe and Gemma divorced in October 2025. Each party retained a 50% ownership interest in their former marital residence. As a condition of the divorce agreement, Gemma can continue to reside in the home for up to six years, until their youngest child reaches age 21. Then Gemma must either buy out Joe's 50% interest or cooperate in selling the home.
Say the home is sold in 2031. Joe still passes the use test, even though he hasn't lived in the home for six years, because the divorce agreement included the provision permitting Gemma to continue residing there. So, Joe passes both the ownership and use tests when the home is sold. Therefore, he qualifies for the $250,000 gain exclusion, which Joe can use to shelter all or part of his share of the home sale gain. Gemma also qualifies for a separate $250,000 exclusion, which she can use to shelter all or part of her share of the gain.
Magic Language
Bear in mind that, in the preceding example, Joe wouldn't qualify for any home sale gain exclusion if the "magic language" regarding Gemma staying in the home for six years wasn't included in the divorce agreement. Instead, he would've been subject to long-term capital gains tax on his entire share of the gain — a costly and avoidable result.
It's critical to negotiate the inclusion of such a provision before finalizing a divorce. Being able to do so afterward is often unlikely. Work closely with your attorney and tax advisor to handle all aspects of divorce, including the tax consequences related to the distribution of assets in your marital estate.
What About Vacation Homes? Vacation homes are generally ineligible for the federal home sale gain exclusion. (See main article.) Only principal residences qualify. So, there are no special tax breaks if you sell a vacation home because of a divorce. Although you might consider co-owning a vacation home with your ex, this is a risky and inadvisable move for most couples. More realistic options are 1) sell the place and pay the tax hit, if any, or 2) have one spouse buy out the other's share. If you choose the buyout, there are no federal tax consequences for either party if you execute it: 1) before the divorce is final, 2) within one year after the divorce is final, or 3) within six years after the divorce is final and as a condition of the divorce agreement. All that said, getting the buyout done sooner rather than later is typically best. Important: Tax-free treatment for a vacation home buyout is unavailable if your soon-to-be ex is a nonresident alien. In this case, the buyout may be treated for tax purposes as a gift or taxable purchase/sale transaction. Consult your tax advisor for more details. |