Tree-lined residential street in fall colours

Guides · Home and rental

1031 vs Section 121: Which Rule to Use on a Home That Was Also a Rental

Section 121 excludes gain only for home years; section 1031 defers all of it but forbids moving in early. Order of use decides which rule to use, or both.

By Breakwater Exchange · Reviewed by our 1031 advisory team · Last reviewed

The short answer

Use section 121 when the property was your home first and you sell within the window it allows; use section 1031 when the property was a rental first or the gain is larger than the exclusion, and use both on one sale when the facts fit. The direction of travel matters most. Home-then-rental keeps the full $250,000 or $500,000 exclusion until the 2-of-5 test fails. Rental-then-home, and especially a 1031 replacement you later move into, gets a five-year wait and an exclusion cut down by every rental year after 2008. Run your own numbers with your CPA before you list.

At a glance

Exclusion cap$250,000, or $500,000 for most joint filers
Use testOwned and lived in as your main home for 2 of the 5 years before the sale
DepreciationNever excluded by section 121; taxable unless a 1031 defers it
Rental years firstRental use after 2008 before you move in shrinks the exclusion pro rata
Exchanged propertyNo exclusion if sold within 5 years of acquiring it in a 1031
Holding a replacementRev. Proc. 2008-16 safe harbor: 24 months, rented 14+ days a year at fair rent
One sale, both rulesAllowed under Rev. Proc. 2005-14: section 121 first, then 1031

The two rules answer different questions, so the property's history picks the rule

Section 121 is an exclusion: gain on a main home is removed from income for good, up to $250,000, or $500,000 for a joint return where either spouse owned it and both lived in it, provided you owned and used it as your main home for periods totaling two years in the five years before the sale. The text is in 26 U.S.C. section 121(a) and (b). You can use it once every two years.

Section 1031 is a deferral: no cap, but the gain rides into the replacement's basis and comes back when you sell for cash. It only covers property held for investment or business use, and the Publication 523 discussion of like-kind exchanges says a main home cannot be exchanged.

So the first question is not which rule saves more. It is which way the property moved: home to rental, or rental to home. The two directions are treated very differently, and most expensive mistakes come from assuming the rules are symmetrical.

Home first, rental second: the exclusion survives about three years after you move out

When you live in the home and then rent it, the clock on the 2-of-5 test runs from your move-out date. Rental years after you leave are not 'nonqualified use', because section 121(b)(5)(C)(ii)(I) excludes any part of the five-year window after the last day you used the property as your home. The Taylor example in Publication 523 shows a home rented for almost two years before sale with the whole remaining gain excluded.

What section 121 never covers is depreciation. Section 121(d)(6) carves out gain equal to depreciation adjustments after May 6, 1997, and that slice is taxed as unrecaptured section 1250 gain at up to 25% unless an exchange defers it.

This is the direction where you may not need to choose at all. Rev. Proc. 2005-14 lets one sale use both: section 121 excludes first, section 1031 defers the remainder including the depreciation slice. The full mechanics and a worked example are on our former home turned rental guide; this page covers the decisions around it.

Rental first, home second: every rental year after 2008 is carved out of the exclusion

Moving into a former rental does not reset it into a fully excludable home. Section 121(b)(5) allocates gain to 'periods of nonqualified use', meaning any time after 2008 when neither you nor your spouse used the property as a main home, in proportion to total ownership. That share cannot be excluded, however long you live there afterward.

The depreciation slice comes out first. Section 121(b)(5)(D) applies the allocation only to gain left after the section 121(d)(6) depreciation carve-out, which is how Worksheet 3 in Publication 523 runs it.

If the property came to you in a 1031 exchange, a second rule applies. Section 121(d)(10) denies the exclusion entirely on a sale within five years of the date you acquired the property in the exchange, and the same bar follows anyone whose basis is carried over from you, such as a donee.

A worked model: moving into a 1031 replacement shelters only the home years

Hypothetical round numbers. A married couple acquires a rental house in a 1031 exchange in March 2020, rents it for four years, moves in in March 2024 and sells in March 2026. They owned it six years, more than the five section 121(d)(10) requires, and lived in it for two. The sale produces $600,000 of gain, of which $60,000 is depreciation adjustments, including depreciation carried in from the property they exchanged, since section 1250(b)(3) counts deductions 'whether in respect of the same or other property'.

Step one: the $60,000 depreciation slice is not excludable. Step two: the remaining $540,000 is split by time; four of six years were nonqualified use, so $360,000 is taxable and $180,000 is excludable, well under the $500,000 cap. Step three: $420,000 of the $600,000 is taxed, roughly 70%.

Had they stayed renters and exchanged again, all $600,000 would remain deferred. Had they lived there four years of six, only $180,000 plus the $60,000 slice would be taxed. The lesson is not that moving in is wrong; it is that section 121 on a former rental pays for home years only. Run your own numbers with your CPA.

Timing decides most outcomes: three dates to check before you sign a listing

First, the move-out date on a former home. Once the 2-of-5 window closes, section 121 is gone and the depreciation and appreciation can only be deferred through a 1031. If you are near the edge, a closing date a few weeks earlier can be worth the whole exclusion.

Second, the acquisition date of any exchanged property. Before the five-year mark, section 121 is unavailable, and moving in too early also puts the original exchange at risk because the replacement must be held for investment. The IRS safe harbor in Rev. Proc. 2008-16 protects a dwelling held 24 months right after the exchange if, in each of the two 12-month periods, you rent it at fair rent for 14 days or more and your personal use does not exceed the greater of 14 days or 10% of the days rented. Our answer on how long to rent before moving in covers that test.

Third, your last exclusion. Section 121(b)(3) blocks a second exclusion within two years of the first, so a couple selling a current home and a former home in the same stretch should sequence the sales.

  • Former home, gain under the cap, inside the window: section 121 alone, and pay or exchange the depreciation slice.
  • Former home, gain over the cap, inside the window: both rules on one sale under Rev. Proc. 2005-14.
  • Former home, window closed: section 1031 only.
  • Rental you plan to retire into: exchange into it, hold to the safe harbor and the five-year mark, then live there long enough that home years dominate. See 1031 into a future retirement home.
  • Rental you will never live in: section 1031, or a sale.

When the rental stays a rental, a passive replacement keeps the 1031 lane open

Many owners in the rental-first column decide they do not want to live in the property or manage it. Exchanging into a Delaware Statutory Trust interest keeps the full gain deferred, including the depreciation section 121 can never touch, and Publication 544 and the Form 8824 instructions govern the reporting the same way as any other exchange. A trust interest cannot become your home later, so it fits owners who have settled the residence question.

If the property is a house you used to live in, the former home rental page lays out the replacement options, and traditional DST solutions describes the passive route.

Related questions

Does renting out my old home after I move out reduce my exclusion?

Not by itself. Section 121(b)(5)(C)(ii)(I) says time in the five-year window after your last day of home use is not nonqualified use, so the cap stays whole as long as you sell inside the 2-of-5 window. Depreciation claimed during the rental is still taxed or must be exchanged.

I moved into a rental in 2015. Is my rental time before 2009 counted against me?

No. The nonqualified use definition in section 121(b)(5)(C)(i) leaves out any portion of a period before January 1, 2009. Only rental years from 2009 on reduce the exclusion.

Can I move into my 1031 replacement right after closing?

That risks the exchange, because section 1031 requires the replacement to be held for investment or business use. Rev. Proc. 2008-16 gives a safe harbor if you hold it 24 months with real rental use, and section 121 then stays unavailable until five years after you acquired it.

Is the five-year rule five years of living there?

No. Section 121(d)(10) counts five years from the date you acquired the property in the exchange, whatever you used it for. You still need two years of use as a main home within the five years before the sale to claim any exclusion.

Which rule handles the depreciation I took?

Only section 1031. Section 121(d)(6) excludes no gain equal to depreciation after May 6, 1997, so on a straight home sale it is taxed at up to 25%. Our page on how much recapture you owe shows the calculation.

Sources

Checked against these publications on September 30, 2026. Rules and figures change; confirm the current version with your CPA or attorney before you act. This page is general information, not tax or legal advice.

  1. 26 U.S.C. section 121, exclusion of gain from sale of principal residence
  2. 26 U.S.C. section 1031, like-kind exchanges
  3. 26 U.S.C. section 1250, depreciation adjustments
  4. IRS Publication 523, Selling Your Home
  5. IRS Publication 544, Sales and Other Dispositions of Assets
  6. Rev. Proc. 2005-14, sections 121 and 1031 on one property
  7. Rev. Proc. 2008-16, safe harbor for dwelling units
  8. IRS Instructions for Form 8824

Map the dates before you choose the rule

Send us the purchase, move-in and move-out dates and the depreciation taken, and we will show what an exchange into DST replacement property would keep deferred.

Free 1031 proposal

Access Investment Offerings Other Brokers Can’t Provide

Breakwater Exchange’s expert guidance helps you maximize returns while minimizing tax exposure, so you can invest with clarity and confidence.

years of experience
20+
in DST transactions
$1B+
states licensed
50
vetted national sponsors
8

Tell us about your exchange

Share the basics and an advisor will reach out with next steps.

Are you an accredited investor?

Generally, net worth over $1 million excluding your primary residence, or income over $200,000 ($300,000 with a spouse) in each of the last two years.

No obligation. A Breakwater Exchange advisor reviews every request personally.

Get My Free ProposalFree ProposalBook a Free ConsultationFree Consultation