What actually reduces capital gains tax on a rental property sale
You cannot avoid capital gains tax entirely when you sell rental property at a profit, but you can reduce the taxable gain itself by increasing your cost basis — the amount you originally paid plus certain improvements. The IRS taxes only the difference between what you sell for and your cost basis, so a higher basis means a smaller gain and less tax owed.
The most straightforward way to reduce your taxable gain is to deduct the cost of capital improvements you made to the property. These are not repairs or maintenance; they are permanent upgrades that add value, extend the property's life, or adapt it to new uses. A new roof, foundation work, added rooms, new HVAC system, or upgraded electrical wiring all count. Painting, fixing a leak, or replacing a broken window do not.
You can also defer the tax — push it into the future — through a 1031 exchange, which lets you reinvest the sale proceeds into another investment property without paying capital gains tax at that moment. The tax is deferred, not erased, and you owe it when you eventually sell the replacement property without doing another exchange.
Key Takeaways
- Capital improvements you made to the rental property — new roof, HVAC, foundation work, added rooms — increase your cost basis and reduce your taxable gain dollar-for-dollar.
- A 1031 exchange lets you reinvest sale proceeds into another investment property and defer capital gains tax, though the tax is owed later when you sell without exchanging again.
- Depreciation recapture tax applies to the depreciation deductions you took while you owned the rental, and you owe it at a 25% rate regardless of your income tax bracket.
- If you inherited the rental property, you may receive a stepped-up basis that erases the gain that existed before you inherited it.
- Keeping detailed records of every improvement, its cost, and the date you completed it is essential because the IRS requires proof when you report your cost basis.
How capital improvements increase your cost basis
When you buy a rental property for $300,000 and later sell it for $450,000, your gain is $150,000 before any adjustments. But if you spent $40,000 on a new roof, foundation repair, and upgraded plumbing — all capital improvements — your cost basis rises to $340,000. Now your gain is only $110,000, and your tax bill shrinks accordingly.
The IRS distinguishes capital improvements from repairs by asking whether the work adds value, prolongs the property's life, or adapts it to a new use. A new roof is a capital improvement; patching a leak is a repair. Adding a bedroom is a capital improvement; painting the existing bedroom is maintenance. Replacing the entire HVAC system is a capital improvement; servicing the existing system is a repair.
You must keep receipts, invoices, and documentation for every improvement. When you sell, you report your adjusted cost basis on your tax return, and the IRS may ask for proof. If you cannot document an improvement, you cannot deduct it from your gain. Many property owners lose thousands in potential tax savings because they did not keep records.
Understanding 1031 exchanges and tax deferral
A 1031 exchange is a mechanism that lets you sell one investment property and buy another without triggering capital gains tax at the moment of sale. The name comes from Section 1031 of the Internal Revenue Code. You do not pay tax on the gain; instead, you defer it by rolling the proceeds into a replacement property.
The process requires strict timing and specific rules. You have 45 days from the sale of your original property to identify potential replacement properties, and you have 180 days total to close on the replacement property. You cannot straightforward pocket the money and buy later; a may have access to intermediary — a third party — must hold the sale proceeds during this window. If you touch the money yourself, the exchange fails and you owe tax when ready.
The replacement property must be of equal or greater value, and it must be held for investment or business use, just like the original property. You can exchange a rental house for an apartment building, a commercial property for raw land held for investment, or a strip mall for a single-family rental. You cannot exchange rental property for a primary residence or a property you plan to flip and sell quickly.
The tax is deferred, not eliminated. When you eventually sell the replacement property without doing another 1031 exchange, you owe capital gains tax on the original gain plus any additional gain from the replacement property. Many investors chain multiple 1031 exchanges together over decades to defer tax indefinitely, but the liability remains.
Depreciation recapture and what it costs
While you owned the rental property, you likely deducted depreciation on your tax returns — a deduction that assumes the building loses value over time, even though real estate often appreciates. The IRS allows this deduction to encourage investment in rental housing, but when you sell, you must "recapture" that depreciation and pay tax on it.
Depreciation recapture is taxed at a flat 25% rate, regardless of your income tax bracket. If you deducted $50,000 in depreciation over 20 years of ownership, you owe $12,500 in recapture tax when you sell — even if your ordinary income tax rate is only 12% or 22%. This tax applies whether you sell at a gain or a loss, and it applies even if you use a 1031 exchange to defer your regular capital gains tax.
You cannot avoid depreciation recapture by using a 1031 exchange, but you can reduce it by taking fewer depreciation deductions while you own the property. This is rarely a good strategy, because the tax savings from depreciation deductions usually outweigh the recapture tax you pay later. However, if you know you will sell soon and want to minimize tax at sale, you could choose not to deduct depreciation in your final years of ownership.
Stepped-up basis for inherited rental properties
If you inherit a rental property, you receive a stepped-up basis — the property's fair market value on the date of the previous owner's death becomes your new cost basis. This can erase the entire capital gain that existed before you inherited it.
For example, suppose your parent bought a rental house for $200,000 and it was worth $500,000 when they died. Your cost basis is $500,000, not $200,000. If you sell it a year later for $510,000, your gain is only $10,000, not $310,000. The $300,000 gain that existed before you inherited it is never taxed.
This benefit applies only to property you inherit; it does not explore to property you receive as a gift while the owner is alive. If someone gives you a property, your cost basis is the same as theirs, and you inherit their tax liability. The stepped-up basis rule is one reason some families hold appreciated real estate until death rather than transferring it during life.
Keeping records of improvements and basis adjustments
The IRS requires you to support your cost basis with documentation. For each capital improvement, keep the original invoice or receipt, a description of the work, the date it was completed, and the contractor's name. Photographs before and after the improvement are helpful but not required.
Create a spreadsheet or file that lists every improvement, its cost, and the date. When you sell the property, provide this record to your tax preparer or accountant. They will use it to calculate your adjusted cost basis and report it correctly on your tax return.
If you cannot document an improvement, you cannot claim it. The IRS does not accept your word or memory; it accepts receipts and invoices. Many property owners discover too late that they threw away the documentation and cannot recover the tax benefit.
When selling at a loss and other edge cases
If you sell a rental property for less than your cost basis, you have a capital loss. You cannot deduct this loss against your ordinary income (wages, salary, interest). However, you can use it to offset capital gains from other investments — stocks, bonds, other real estate sales. If your capital losses exceed your capital gains in a year, you can carry the unused loss forward to future years.
If you convert a rental property to your primary residence and then sell it, the rules change. You may be able to exclude up to $250,000 of gain (or $500,000 if married filing jointly) if you meet the ownership and use tests. However, you must have lived in the property as your main home for at least two of the five years before the sale. The portion of the gain that came from years you rented it out is still taxable.
If you own rental property in multiple states or countries, each jurisdiction may have its own capital gains tax in addition to federal tax. Some states have no capital gains tax; others tax it as ordinary income. This is a conversation for a tax professional in your state.
Frequently Asked Questions
Can I do a 1031 exchange if I already sold the property?
No. The 45-day identification period starts on the day you close the sale. If you have already closed and did not identify a replacement property within 45 days, the exchange window has closed and you owe capital gains tax on the sale. You cannot go back and do a 1031 exchange retroactively.
What counts as a capital improvement versus a repair?
A capital improvement adds value, extends the property's useful life, or adapts it to a new use. Replacing the entire roof is a capital improvement; patching a leak is a repair. Adding a room is a capital improvement; repainting is maintenance. When in doubt, ask your tax preparer before you pay the contractor.
Do I owe depreciation recapture if I use a 1031 exchange?
Yes. Depreciation recapture is owed at the time of sale regardless of whether you do a 1031 exchange. The exchange defers your regular capital gains tax but not the 25% recapture tax on depreciation you deducted while you owned the property.
If I inherit a rental property, do I have to pay the previous owner's capital gains tax?
No. You receive a stepped-up basis equal to the property's fair market value on the date of death. The gain that existed before you inherited it is never taxed. You owe tax only on any gain that occurs after you inherit it.
Can I reduce capital gains tax by donating the rental property to charity?
Yes, but with limits. If you donate appreciated property to a may have access to charity, you avoid capital gains tax on the appreciation and may deduct the fair market value as a charitable contribution. However, you must itemize deductions on your tax return for this to benefit you, and the deduction is limited to a percentage of your adjusted gross income. Consult a tax professional before donating appreciated real estate.