What Is a Disqualified Sale and How Is It Taxed?

A “disqualified sale” is informal shorthand for a home sale where part of your profit falls outside the capital gains exclusion because the property had a period of “nonqualified use” — the actual term the tax code uses. Under Section 121 of the Internal Revenue Code, a single filer can normally exclude up to $250,000 of gain on the sale of a primary residence, and married joint filers up to $500,000. But if the home spent time as a rental or an investment property after 2008 before you moved in, the disqualified sale rules for the capital gains exclusion reduce that shelter proportionally, and any depreciation you claimed comes back as a separate tax bill on top.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence

How the Section 121 Exclusion Works

To qualify for any exclusion at all, you must have owned the home and used it as your primary residence for at least two of the five years ending on the sale date.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence Meet that test and you can exclude up to $250,000 of gain as a single filer, or up to $500,000 on a joint return if both spouses meet the use requirement and at least one meets the ownership requirement. You also can’t use the exclusion if you already excluded gain from a different home sale within the prior two years.2Internal Revenue Service. Sale of Your Home

Passing the ownership and use tests gets you into the exclusion. The nonqualified use rules then decide how much of it you actually get to keep.

What Nonqualified Use Actually Means

A period of nonqualified use is any stretch of time after January 1, 2009, during which neither you nor your spouse (or former spouse) used the property as a primary residence.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence Congress created the rule in the Housing Assistance Tax Act of 2008, so anything before that cutoff date is ignored no matter how the home was used.

The classic setup is a rental turned residence. Someone buys a property, rents it out for a few years, then moves in and stays long enough to satisfy the two-out-of-five-year test. Those pre-move-in rental years are nonqualified use, and they reduce the exclusion. The same treatment applies if you held the property vacant as an investment before moving in.

Order matters. Rental time before you move in counts against you. Rental time after you move out generally does not, thanks to a specific carve-out described below. Track your move-in and move-out dates precisely: the IRS formula counts days, not years, so lease agreements, utility records, and change-of-address confirmations are worth keeping.

Time That Doesn’t Count Against You

Several periods are protected from the nonqualified use label even when you weren’t living in the home.

Renting the Home After You Move Out

Any portion of the five-year lookback window that falls after the last date you used the property as your primary residence does not count as nonqualified use.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence If you lived in the home for at least two years and then rented it out, you have up to three years to sell before the residency test itself fails. During that post-move-out rental window, the pro-rata reduction doesn’t apply.

Military, Foreign Service, and Intelligence Community Duty

If you or your spouse serve on qualified official extended duty in the uniformed services, the Foreign Service, or the intelligence community, you can suspend the five-year test period for up to ten years.2Internal Revenue Service. Sale of Your Home The duty must place you at a station at least 50 miles from the home, or in government housing under orders. Time on qualifying duty also doesn’t count as nonqualified use for the allocation.

Temporary Absences

Short absences like vacations count as time you lived in the home, even if you rented it out while away.3Internal Revenue Service. Publication 523, Selling Your Home Longer absences of up to two years total are also protected when they result from a job change, health conditions, or other unforeseen circumstances the IRS recognizes.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence The two-year cap is aggregate across all qualifying absences during ownership.

How to Calculate the Taxable Share

Nonqualified use doesn’t wipe out the exclusion. It carves out a proportional slice of the gain that can’t be excluded. The Worksheet 3 method in Publication 523 runs in five steps:3Internal Revenue Service. Publication 523, Selling Your Home

  • Start with your total gain, then subtract any depreciation claimed after May 6, 1997. Depreciation is taxed separately.
  • Count the days after 2008 that neither you nor your spouse used the home as a primary residence, excluding the protected periods above. That’s your nonqualified use days.
  • Count total ownership days, including any days before 2009.
  • Divide nonqualified use days by total ownership days for the nonqualified use percentage.
  • Multiply that percentage by the gain from step one. The result is the portion of your gain that cannot be excluded.

A Worked Example

The IRS uses this scenario in Publication 523. Finley buys a property on January 1, 2020, for $400,000 and rents it out for two years, claiming $20,000 in depreciation. On January 1, 2022, Finley moves in and stays through January 1, 2024, then sells on January 1, 2025, for $700,000.3Internal Revenue Service. Publication 523, Selling Your Home

Total gain is $320,000 (the $700,000 sale price minus a $380,000 adjusted basis after depreciation). Subtract the $20,000 of depreciation for the nonqualified use math, leaving $300,000. Two rental years out of five ownership years produces a 40% nonqualified use ratio. That makes $120,000 of the gain ineligible for the exclusion, and the remaining $180,000 is tax-free under Section 121. The $20,000 of depreciation is then taxed on its own as unrecaptured Section 1250 gain.

The year between moving out and selling doesn’t count against Finley because it falls after the last date the home was a primary residence. Only the two pre-move-in rental years do the damage.

Depreciation Recapture Sits on Top

Even if your gain falls entirely within the Section 121 dollar caps, the exclusion never covers gain attributable to depreciation deductions taken after May 6, 1997.1Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence Every dollar of depreciation you claimed during rental years comes back as taxable income when you sell.

This depreciation recapture is unrecaptured Section 1250 gain, taxed at a maximum rate of 25% — higher than the 15% long-term capital gains rate most sellers pay.4Internal Revenue Service. Topic No. 409, Capital Gains and Losses In the Finley example, the $20,000 of depreciation is taxed at up to 25% even though $180,000 of gain is completely excluded. Recapture is stripped out of the nonqualified use calculation so it isn’t double-counted, then taxed on its own.

Skipping depreciation while the home was a rental doesn’t help. The IRS requires you to reduce basis by the depreciation you were allowed to claim, whether you actually took the deductions or not.

The 1031 Exchange Wrinkle

If you acquired the property through a like-kind (1031) exchange, you cannot use the Section 121 exclusion at all if you sell within five years of the exchange.5Office of the Law Revision Counsel. 26 U.S. Code 121 – Exclusion of Gain From Sale of Principal Residence The five years run from the date the exchange completed, not from when you moved in.

Clear the five-year mark and the regular nonqualified use rules take over. The pre-residency investment years still count against the exclusion, and the pro-rata calculation is unchanged. Because 1031 properties often carry years of investment use before conversion, the nonqualified percentage tends to be high. Six years as a rental followed by two years of residence produces a 75% nonqualified ratio, leaving only 25% of the gain eligible for exclusion.

Rates and Reporting

Gain allocated to nonqualified use is taxed as a long-term capital gain when you owned the property for more than a year, which is almost always the case in these situations. For 2026, long-term capital gains rates run 0%, 15%, or 20% depending on taxable income, and most homeowners land at 15%. A separate 3.8% net investment income tax may apply if your modified adjusted gross income exceeds $200,000 (or $250,000 for married joint filers).

A converted-rental sale can produce three rates on one transaction: 0% on the excluded slice, up to 25% on depreciation recapture, and 15% or 20% on the nonqualified use portion.

Report the sale on Form 8949 using adjustment code H. Enter the full sale details as if no exclusion applied, then record the excluded (nontaxable) portion as a negative number in column (g).6Internal Revenue Service. Form 8949 Codes The net flows to Schedule D of Form 1040 with the rest of your capital gains and losses for the year.7Internal Revenue Service. About Schedule D (Form 1040), Capital Gains and Losses Capital losses from other investments can offset the taxable portion of the gain; losses applied against capital gains have no dollar cap, though net losses against ordinary income are capped at $3,000 a year ($1,500 for married filing separately).8Internal Revenue Service. 2025 Instructions for Schedule D (Form 1040) Depreciation recapture goes through the Unrecaptured Section 1250 Gain Worksheet in the Schedule D instructions. Given how the exclusion, the nonqualified use allocation, and the recapture layer interact, a tax professional is worth the fee on most converted-rental sales.