
How do you allocate sale expenses and calculate gain for a property with both rental and primary residence portions, including the impact of depreciation recapture?
Ask Blue J any tax question, then go deeper. Follow up, add client-specific context, and explore the sources behind every answer with Blue J’s generative AI solution for tax research.
To allocate sale expenses and calculate gain for a property with both rental and primary residence portions—including the impact of depreciation recapture—you must follow a multi-step process that incorporates the requirements of IRC §121, §1250, and related regulations. Here’s a comprehensive breakdown:
1. Determine the Allocation Between Rental and Primary Residence Portions
a. Identify the Portions- If the property consists of physically separate units (e.g., a duplex with one unit rented and one used as a residence), allocate based on the relative fair market value (FMV) or square footage of each portion.- If the rental and residence uses are within the same dwelling unit (e.g., a home office), special rules apply (see below).
b. Allocation Method- The IRS requires that the basis, amount realized (sale price minus selling expenses), and selling expenses be allocated between the residential and rental (or business) portions using the same method as was used for depreciation (typically based on square footage, number of rooms, or FMV at the time of conversion),.
2. Calculate Adjusted Basis for Each Portion
a. Start with Original Cost- Include purchase price, closing costs, and capital improvements.
b. Adjust for Depreciation- For the rental portion, reduce the basis by the total depreciation claimed or allowable during the rental period.- For the residence portion, no depreciation adjustment unless part of the residence was also depreciated (e.g., home office).
c. Other Adjustments- Add capital improvements to the respective portion.- Subtract casualty losses or insurance reimbursements, if any.
3. Allocate Selling Expenses
- Selling expenses (e.g., real estate commissions, legal fees, title insurance) are generally allocated between the rental and residence portions using the same method as for basis and sale price allocation (e.g., by square footage or FMV),.
4. Calculate Gain or Loss for Each Portion
a. For Each Portion:- Amount Realized: (Allocated sale price) – (Allocated selling expenses)- Adjusted Basis: (Allocated original basis + improvements) – (Allocated depreciation)- Gain or Loss: (Amount realized) – (Adjusted basis)
5. Apply Section 121 Exclusion to the Residence Portion
- The IRC §121 exclusion (up to $250,000 single/$500,000 joint) applies only to the gain allocable to the portion used as a principal residence, provided the ownership and use tests are met (owned and used as principal residence for at least 2 of the 5 years preceding the sale),,.
- If the property was used as both a residence and rental, only the gain on the residence portion is eligible for exclusion. The rental portion is not eligible for the exclusion unless it was converted to residence use and the use/ownership tests are met for that portion.
- If the property was converted from rental to residence (or vice versa), and there were periods of "nonqualified use" (e.g., rental use after 2008 and before last use as principal residence), the exclusion is reduced proportionally,.
6. Depreciation Recapture (Section 1250)
- Depreciation Recapture: Any gain attributable to depreciation claimed after May 6, 1997, on the rental (or business) portion must be recognized as unrecaptured Section 1250 gain and is taxed at a maximum rate of 25%. This gain cannot be excluded under Section 121, even if the property was later used as a residence,,,.
- Calculation: The recapture amount is the lesser of (a) the total depreciation taken or allowable, or (b) the gain on the sale of the rental portion.
7. Special Rule for Mixed-Use Within a Single Dwelling Unit
- If the rental/business use was within the same dwelling unit as the residence (e.g., a home office), and the business use did not involve a separate structure, you do not need to allocate gain between the business and residence portions. However, you must still recapture any depreciation claimed for the business use,.
8. Reporting the Sale
- Form 4797: Report the sale of the rental (or business) portion, including depreciation recapture,.
- Schedule D/Form 8949: Report the sale of the residence portion and any gain eligible for exclusion under Section 121,.
9. Example Calculation
Suppose you own a duplex: one unit is your principal residence, the other is rented. You sell the property for $600,000. The original cost was $400,000, with $100,000 in improvements. You allocated 50% to each unit. You claimed $50,000 in depreciation on the rental unit. Selling expenses are $36,000.
Step 1: Allocate Sale Price and Expenses- Sale price per unit: $300,000- Selling expenses per unit: $18,000
Step 2: Calculate Adjusted Basis- Original basis per unit: $200,000- Improvements per unit: $50,000- Rental unit: Subtract $50,000 depreciation → Adjusted basis = $200,000 + $50,000 – $50,000 = $200,000- Residence unit: Adjusted basis = $200,000 + $50,000 = $250,000
Step 3: Calculate Gain- Rental unit: ($300,000 – $18,000) – $200,000 = $82,000- Residence unit: ($300,000 – $18,000) – $250,000 = $32,000
Step 4: Apply Section 121 Exclusion- Residence unit: Up to $250,000 ($500,000 joint) of gain can be excluded if requirements are met. Here, the entire $32,000 is excludable.
Step 5: Depreciation Recapture- Rental unit: Of the $82,000 gain, $50,000 is taxed as unrecaptured Section 1250 gain (max 25% rate). The remaining $32,000 is taxed as long-term capital gain.
Step 6: Reporting- Report the rental unit sale and depreciation recapture on Form 4797.- Report the residence unit sale and exclusion on Schedule D/Form 8949.
10. Summary Table of Steps
- Allocate sale price, basis, and expenses between residence and rental/business portions.
- Adjust basis for each portion (subtract depreciation for rental/business).
- Calculate gain for each portion.
- Apply Section 121 exclusion to the residence portion only.
- Recapture depreciation on the rental/business portion (taxed at up to 25%).
- Report on appropriate IRS forms.
In summary: Allocate sale price, basis, and expenses between the residence and rental portions using the same method as for depreciation. Calculate gain for each portion. Apply the Section 121 exclusion only to the residence portion, and only for gain not attributable to depreciation. Depreciation recapture on the rental portion is taxed at up to 25% and cannot be excluded. Report the sale on Form 4797 (rental/business) and Schedule D/Form 8949 (residence). Careful recordkeeping and correct allocation are essential for compliance and optimal tax treatment,,,,.
Was this answer helpful?
What Blue J customers are saying


“We are excited to use Blue J to elevate the initial work product our team is able to produce."
"We’re incorporating Blue J to ensure our people are well-equipped with a research tool that delivers on both ease of use and quality of deliverable. It will save us a lot of time as a starting point, so we can focus our efforts on the analysis. Ultimately, it helps us get to the right answer, faster.”
"We’re incorporating Blue J to ensure our people are well-equipped with a research tool that delivers on both ease of use and quality of deliverable. It will save us a lot of time as a starting point, so we can focus our efforts on the analysis. Ultimately, it helps us get to the right answer, faster.”


"We had used Checkpoint for a long time but found it wasn’t particularly well-used in our practice."
"A lot of our practitioners would have to turn to Google to find what they were looking for, which of course isn’t ideal. Blue J is a real game-changer when it comes to this, since it combines the efficiency of Google with the authoritative tax materials our people really need to serve their clients best. At ELO, we pride ourselves on providing services that are focused on value for clients and exceeding their expectations. Adding Blue J to our toolbox will enable us to do just that, as we continue to evolve our service offerings to better serve our clients’ needs.”
"A lot of our practitioners would have to turn to Google to find what they were looking for, which of course isn’t ideal. Blue J is a real game-changer when it comes to this, since it combines the efficiency of Google with the authoritative tax materials our people really need to serve their clients best. At ELO, we pride ourselves on providing services that are focused on value for clients and exceeding their expectations. Adding Blue J to our toolbox will enable us to do just that, as we continue to evolve our service offerings to better serve our clients’ needs.”


"We find this tool to be a game-changer for us and our clients.”
“We had the opportunity to pilot some other AI solutions in the market, and found that the improvement over traditional search was limited - except in Blue J’s case, where the efficiency gain over traditional research methods is significant."
“We had the opportunity to pilot some other AI solutions in the market, and found that the improvement over traditional search was limited - except in Blue J’s case, where the efficiency gain over traditional research methods is significant."


“Blue J is an exciting technology because it enables the practitioner to remain in the driver’s seat of the analysis."
"Thoughtful functions are included to encourage and facilitate deeper analysis, not to replace or reduce it. We’ll continue to find new and impactful ways to leverage the technology, which has benefited our clients and staff alike. At RSM we strive to be compelling to our clients and to be digital by embracing new technologies to fulfill that promise.”
"Thoughtful functions are included to encourage and facilitate deeper analysis, not to replace or reduce it. We’ll continue to find new and impactful ways to leverage the technology, which has benefited our clients and staff alike. At RSM we strive to be compelling to our clients and to be digital by embracing new technologies to fulfill that promise.”


"We wanted to have a tool that people were using at all staff levels."
"We wanted something that lived up on their third screen - something that would be available and helpful to them every day. What we've found is it's been easy to get people to get into the habit of using Blue J because it helps people. Blue J allows us to quickly respond to client questions in a way that they can understand it, which helps us deal with the volume of client questions that come in. We were up and running very quickly with Blue J - within 5 minutes, our staff understood how this will be helpful, and the rest of the training program is refining prompting skills and building use cases and best practices."
"We wanted something that lived up on their third screen - something that would be available and helpful to them every day. What we've found is it's been easy to get people to get into the habit of using Blue J because it helps people. Blue J allows us to quickly respond to client questions in a way that they can understand it, which helps us deal with the volume of client questions that come in. We were up and running very quickly with Blue J - within 5 minutes, our staff understood how this will be helpful, and the rest of the training program is refining prompting skills and building use cases and best practices."
