Selling real estate can trigger several taxes at once: capital gains tax at up to three rates, a special rate on depreciation you claimed, and sometimes a 3.8% surcharge. Selling your main home is treated very differently from selling a rental.
This guide covers the 2026 rate thresholds, the home sale exclusion, depreciation recapture, the net investment income tax and like-kind exchanges, with a worked rental sale. It follows IRS Topics 409, 701 and 559, Publications 523 and 544 and Revenue Procedure 2025-32.
If you hold an asset more than one year before you dispose of it, the gain is long-term. If you hold it one year or less, the gain is short-term, and net short-term gains are taxed as ordinary income at graduated rates. For long-term gains, the IRS sets the taxable income at which each rate applies. These are the 2026 amounts from Revenue Procedure 2025-32.
| Filing status | 0% rate applies up to | 15% rate applies up to | 20% rate above |
|---|---|---|---|
| Married filing jointly and surviving spouse | $98,900 | $613,700 | $613,700 |
| Head of household | $66,200 | $579,600 | $579,600 |
| Single | $49,450 | $545,500 | $545,500 |
| Married filing separately | $49,450 | $306,850 | $306,850 |
The IRS says a 20% rate applies to the extent that your taxable income exceeds the thresholds for the 15% rate. The thresholds are measured against your taxable income, which includes the gain. For the ordinary income brackets, see our 2026 federal tax brackets guide.
If you have a gain from selling your main home, you may qualify to exclude up to $250,000 of it from income, or up to $500,000 if you file a joint return. You must meet both tests: you owned the home for at least 24 months out of the 5 years before the sale, and you used it as your residence for at least 24 months of the previous 5 years. The two periods do not have to be the same 2 years.
Two traps apply to rental use. The exclusion does not cover the portion of gain equal to depreciation allowed or allowable after May 6, 1997, which must be recaptured and reported under section 1250. And if you received Form 1099-S (Proceeds From Real Estate Transactions), you must report the sale on Form 8949 even if you have no taxable gain to report.
Gain on selling section 1250 property, which is depreciable real property, is treated as ordinary income to the extent of additional depreciation. Pub. 544 says you have no additional depreciation if you used the straight-line method (or another method that gives no more than straight-line), held the property longer than 1 year and, for qualified property, made a timely election not to claim a special depreciation allowance. In that common case the part of the gain that comes from depreciation you took is unrecaptured section 1250 gain, taxed at a maximum 25% rate. The rest of a long-term gain is taxed at 0%, 15% or 20%. Land is not depreciable, so it creates no recapture. Our depreciation recapture guide explains the rules in depth.
The net investment income tax (NIIT) is 3.8% of the lesser of your net investment income or the amount by which your modified adjusted gross income exceeds $200,000 (single or head of household), $250,000 (married filing jointly or qualifying surviving spouse) or $125,000 (married filing separately). Net investment income includes net gains from the disposition of real estate to the extent taken into account in computing taxable income, and rents unless they come from a trade or business to which the NIIT does not apply. It does not apply to the excluded part of the gain from selling your principal residence.
An investor bought a rental property for $300,000, took $50,000 of depreciation over the years and sold it for $450,000, paying $27,000 in selling costs.
| Step | Amount |
|---|---|
| Sale price | $450,000 |
| Less selling costs | $27,000 |
| Amount realized | $423,000 |
| Purchase price | $300,000 |
| Less depreciation taken | $50,000 |
| Adjusted basis | $250,000 |
| Total gain (amount realized minus adjusted basis) | $173,000 |
| Part from depreciation (unrecaptured section 1250 gain) | $50,000 |
| Remaining long-term gain | $123,000 |
The depreciation part is taxed at a maximum of 25%, which is at most $12,500. If the remaining $123,000 falls entirely in the 15% band, the tax on it would be $18,450.00. These are illustrations at the top rates; the actual split depends on your other income, and the NIIT may add 3.8%. The example ignores state tax and assumes the improvements and closing costs are already reflected in the figures.
The nonrecognition rules for like-kind exchanges apply only to exchanges of real property held for investment or for productive use in a trade or business and not held primarily for sale. Buildings, land and rental property are examples of property that may qualify; real property used for personal purposes does not. State rules can differ, so read our 1031 exchange state tax guide and ask a tax professional before relying on a deferral.
Report most sales and other capital transactions, and calculate the gain or loss, on Form 8949, then carry the totals to Schedule D. If your capital losses exceed your capital gains, you can use the lesser of $3,000 ($1,500 if married filing separately) or your total net loss to lower other income, and carry the rest forward. See our Form 8949 guide. State capital gains taxes are separate: see state capital gains tax by state.
IRS Topic no. 409: Capital gains and losses, IRS Topic no. 701: Sale of your home, IRS Topic no. 559: Net investment income tax, IRS Publication 523: Selling Your Home, IRS Publication 544: Sales and Other Dispositions of Assets, IRS Revenue Procedure 2025-32.