What Is a 1038 Tax Exchange and How Does It Work?

Section 1038 tax treatment governs what happens when you, as a seller who financed the sale of real property, take that property back after the buyer defaults. The rule caps the gain you have to recognize at the cash (and other non-note property) you actually received, less any gain you already reported, and it gives you a new basis in the property built from the remaining debt, the recognized gain, and your costs to get the property back. If the conditions are met, this treatment is mandatory; it is not an election.

When Section 1038 Applies

Three things have to be true. The original sale of real property created a debt owed to you that was secured by that property. You reacquired the property in satisfaction of that debt, whether by voluntary reconveyance, foreclosure, or some other method. And the reacquisition was to protect your security interest.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

Publication 537 adds a practical limit: you generally cannot pay the buyer extra money to get the property back, unless the original contract already provided for that payment or the buyer has defaulted or default is imminent. The rules apply whether or not you reported the original sale on the installment method.2Internal Revenue Service. Publication 537 – Installment Sales

If any of those conditions is missing, the general property-disposition rules take over and measure gain against the property’s fair market value at repossession, which usually produces a much larger tax bill. Section 1038 is the more favorable treatment, and it is the one that applies in the typical seller-carryback situation.

How Much Gain You Recognize

Your recognized gain is the lesser of two numbers. Run both calculations and use the smaller.

The Cash-Received Figure

Add up all cash and the fair market value of other property (not counting the buyer’s note) you received before the reacquisition. Subtract the gain you already reported on prior returns. If you used the installment method on Form 6252, that reported gain is the cumulative taxable portion of the payments you included in income over the years.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

The Statutory Ceiling

Take the total gain realized on the original sale (sale price minus your adjusted basis at the time). Subtract the gain you already reported, and subtract your reacquisition costs — legal fees, court costs, and other expenses of taking the property back.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

A Worked Example

You sold property with an adjusted basis of $150,000 for $250,000, so the total realized gain was $100,000 and the gross profit ratio was 40 percent. Over time, you received $70,000 in payments, and you reported $28,000 of that as installment gain (40 percent of $70,000). The buyer defaults. You spend $5,000 in legal fees and court costs to recover the property.

The cash-received figure: $70,000 minus $28,000 equals $42,000.

The statutory ceiling: $100,000 minus $28,000 minus $5,000 equals $67,000.

Because $42,000 is less than $67,000, you recognize $42,000 of gain on the reacquisition. Publication 537’s Worksheet D walks through the same steps line by line.2Internal Revenue Service. Publication 537 – Installment Sales

Your New Basis in the Property

Once you own the property again, you need a basis for future depreciation and for figuring gain on a later sale. The new basis has three parts added together: the adjusted basis of the buyer’s debt as of the reacquisition date, the gain you just recognized, and your reacquisition costs.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

If you were on the installment method, the adjusted basis of the remaining debt is the unpaid balance minus the unrealized profit still inside it. Multiply the unpaid balance by the gross profit percentage, then subtract that product from the unpaid balance.2Internal Revenue Service. Publication 537 – Installment Sales

Back to the example. The unpaid balance at default is $180,000 ($250,000 sale price minus $70,000 received). Unrealized profit still in the note is $72,000 ($180,000 times 40 percent). The adjusted basis of the debt is $108,000.

Your new basis in the reacquired property is $108,000 plus $42,000 plus $5,000, or $155,000. That is $5,000 above your original basis, reflecting the reacquisition costs you have capitalized. Worksheet E in Publication 537 handles this calculation.2Internal Revenue Service. Publication 537 – Installment Sales

Capital Gain or Ordinary Income?

Section 1038 limits how much gain you recognize, but it does not change the character of that gain. If you used the installment method, the gain on reacquisition carries the same character the installment payments carried: typically capital gain for investment or personal-use property, with potential ordinary income treatment for Section 1250 depreciation recapture.3eCFR. 26 CFR 1.1038-1 – Reacquisitions of Real Property in Satisfaction of Indebtedness

If the original sale was a deferred-payment sale not reported on the installment method, where title passed to the buyer and the buyer voluntarily reconveyed the property, the recognized gain is ordinary income.3eCFR. 26 CFR 1.1038-1 – Reacquisitions of Real Property in Satisfaction of Indebtedness

The Note and Any Prior Bad Debt Write-Off

Any installment obligation secured by the property is treated as fully satisfied when you reacquire. You do not separately report gain or loss on the note itself; that is already inside the Section 1038 math. If any secured debt remains outstanding after the reacquisition, its basis drops to zero, and the statute explicitly bars treating any debt as worthless or partially worthless as a result of the reacquisition.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

If you already wrote off part of the debt as a bad debt in a prior year, Section 1038(d) reverses that benefit. On reacquisition, you are treated as receiving an amount equal to the previously deducted portion, and the adjusted basis of the debt is increased by that same amount, which then flows into your basis in the property. The gain you report on reacquisition includes both the normal Section 1038 gain and the recaptured bad debt.1Office of the Law Revision Counsel. 26 US Code 1038 – Certain Reacquisitions of Real Property

If the Property Was the Buyer’s (and Your) Former Home

Section 1038(e) carves out a different path when the original sale qualified for the Section 121 exclusion on the sale of a principal residence (up to $250,000 for a single filer, $500,000 for a married couple filing jointly). If you reacquire the home and resell it within one year of the reacquisition date, the normal Section 1038 gain, basis, and bad-debt-recapture rules do not apply. The resale is treated as part of the original transaction, and the Section 121 exclusion is applied to the combined deal.4Office of the Law Revision Counsel. 26 USC 1038 – Certain Reacquisitions of Real Property

The reacquisition is effectively disregarded, with the original sale and the resale treated as one transaction for the exclusion.5eCFR. 26 CFR 1.1038-2 – Reacquisition and Resale of Property Used as a Principal Residence Miss the one-year window and you are back to the standard Section 1038 calculation on the reacquisition, with the later sale treated as its own event.

How to Report It

Report the gain on the same form you used for the original sale. If the sale was on Form 6252 as an installment sale, use Part III of that form, along with the corresponding worksheets in Publication 537, to compute both the gain and the new basis. If you reported the original sale on Form 4797, report the repossession gain there.2Internal Revenue Service. Publication 537 – Installment Sales

Worksheet D handles the gain (the two-figure comparison), and Worksheet E handles the new basis. Running both in order keeps the numbers consistent, because the gain from Worksheet D feeds directly into the basis on Worksheet E.2Internal Revenue Service. Publication 537 – Installment Sales