Divorce Deep DiveAdvanced6 min read

Capital gains when you sell the house in a divorce

The home-sale tax exclusion is worth up to $500,000 for couples but only $250,000 for singles. Timing the sale around the divorce can save — or cost — tens of thousands.

When you sell your primary home for more than you paid, the profit is a capital gain — and the tax code lets you shield a big chunk of it. A married couple filing jointly can exclude up to $500,000 of gain; a single filer can exclude only $250,000. In a divorce, that gap is not a footnote. Sell the house while still married, or in the same tax year, and you may keep the full $500,000 shield. Sell it two years later as two single people who no longer live there, and half the exclusion — and one spouse's entire exclusion — can quietly disappear.

How the exclusion works

  • To claim the exclusion you generally must have owned and lived in the home as your main residence for at least two of the last five years.
  • A couple filing jointly excludes up to $500,000 of gain; each single filer excludes up to $250,000.
  • Gain is your sale price minus selling costs minus your cost basis — the original price plus the cost of qualifying improvements.
  • Gain above the exclusion is taxed at long-term capital gains rates, which depend on income.

Why timing is everything

Imagine a couple bought their home for $300,000, poured $50,000 into improvements, and can now sell for $900,000. After roughly $60,000 in selling costs, the gain is about $490,000. Sell while married filing jointly and the entire $490,000 is excluded — zero tax. Now suppose they divorce, one spouse keeps the house and sells three years later as a single filer with the same $490,000 gain: only $250,000 is excluded, leaving $240,000 taxable. At a 15% capital gains rate that is roughly $36,000 in federal tax, plus any state tax — a five-figure penalty for the timing of the sale.

$500,000
Joint exclusion
Married filing jointly
$250,000
Single exclusion
Per single filer
2 of 5 yrs
Ownership and use test
Main residence

The move-out problem

The exclusion requires you to have lived in the home two of the last five years. The spouse who moves out at separation starts a clock. If they are off the deed and out of the house for more than three years before it sells, they can lose their $250,000 exclusion entirely — because they no longer meet the use test. The fix is often a divorce or separation agreement that explicitly grants the out-spouse continued 'use' of the home for tax purposes while the in-spouse lives there, preserving both exclusions until the sale. This is a known planning tool, and it belongs in the settlement, not in a scramble at closing.

Keep every improvement receipt
Cost basis includes qualifying capital improvements — a new roof, an addition, a kitchen remodel — but not routine repairs. Every dollar of documented basis is a dollar of gain you never have to shield or tax. Couples who kept a folder of improvement receipts often find their taxable gain is far smaller than they feared. Reconstruct it before you sell, not after.

The bottom line

The home-sale exclusion is one of the largest tax breaks most families ever use, and divorce is exactly when it gets fumbled. If a sale is coming and the gain approaches or exceeds $250,000 per person, model whether selling while married, selling in the divorce year, or writing continued-use language into the agreement preserves the full shield. The difference can be tens of thousands of dollars. This is general education, not tax advice — a CPA should run your actual basis and gain before you list.

Check your understanding

1 of 3
A couple has a $490,000 gain on their home. They sell while still married filing jointly. How much of the gain is federally taxable?

Not quite — try again.

The Worth letter

Get smarter about money every week

One email, no spam — practical guides and Worth updates. Unsubscribe anytime.

Put this into practice

Worth tracks your accounts, budgets, and goals — so the concepts in this article aren't just theory.

Start free trial