The capital gains tax on real estate is the federal tax you pay on the profit when you sell property. For sales in 2026, long-term gains (on property you owned more than a year) are taxed at 0%, 15%, or 20% depending on your taxable income, and short-term gains (one year or less) are taxed at your ordinary income rate. If the property was your primary home, you can usually exclude up to $250,000 of gain ($500,000 if married filing jointly), which means most home sales trigger no federal capital gains tax at all.
How the Taxable Gain Is Calculated
Your gain is not the sale price. It’s the difference between what you net from the sale and your adjusted basis in the property.
Start with the gross sale price and subtract direct selling costs: real estate commissions, title insurance, transfer taxes, and legal fees. That’s your amount realized.1Internal Revenue Service. Publication 523, Selling Your Home
Your adjusted basis begins with what you paid for the property, including certain closing costs from the purchase such as recording fees, survey charges, and transfer taxes.2Office of the Law Revision Counsel. 26 USC 1011 – Adjusted Basis for Determining Gain or Loss Add the cost of capital improvements made while you owned it. A new roof, a finished basement, or a permanent deck all raise your basis and shrink the taxable gain. Routine maintenance and repairs don’t count.
Subtract the adjusted basis from the amount realized. What’s left is your capital gain. Keep receipts, contractor invoices, and settlement statements; if the IRS questions your basis, those records are your only defense.
Costs That Do Not Reduce Your Gain
Not every expense on your closing statements helps. Mortgage-related charges such as loan origination fees, discount points, lender-required appraisal fees, and mortgage insurance premiums cannot be added to basis.1Internal Revenue Service. Publication 523, Selling Your Home Property taxes you paid as the seller through the day before closing are generally reported on Schedule A as an itemized deduction, not used to reduce the gain. Read each line of your closing statement rather than assuming everything counts.
Short-Term vs. Long-Term: The Holding Period
How long you owned the property decides the rate. One year or less produces a short-term gain, taxed at your ordinary income rate. More than one year makes it a long-term gain at the preferential rates below.3Office of the Law Revision Counsel. 26 USC 1222 – Other Terms Relating to Capital Gains and Losses
The clock starts the day after you acquire the property and runs through the transfer date. A single day matters. Close on a purchase on June 15, 2024, and the property becomes long-term on June 16, 2025. Check your original settlement statement before you list.
Inherited real estate is a separate case: it’s always treated as long-term, even if you sell the week after you receive it.4Office of the Law Revision Counsel. 26 USC 1223 – Holding Period of Property
2026 Long-Term Capital Gains Rates
Long-term gains fall into three brackets based on your total taxable income for the year. For 2026, the IRS thresholds are:5Internal Revenue Service. Revenue Procedure 2025-32
- 0% rate: taxable income up to $49,450 for single filers or $98,900 for married filing jointly.
- 15% rate: taxable income above those amounts up to $545,500 (single) or $613,700 (married filing jointly).
- 20% rate: taxable income above $545,500 (single) or $613,700 (married filing jointly).
The 0% bracket is real and easy to miss. A retired couple with modest pension income selling a rental could owe nothing on a long-term gain if their total taxable income stays under the joint threshold. Timing the sale year around your income can save thousands.
Short-term gains get no preferential rate. They’re added to your other income and taxed at the ordinary rate for your bracket.6Internal Revenue Service. Topic No. 409, Capital Gains and Losses For high earners in 2026, that top rate can reach 39.6%. Holding 11 months instead of 13 can swing the effective rate on the gain by roughly 20 percentage points.
The 3.8% Net Investment Income Tax
Higher-income sellers pay an additional 3.8% Net Investment Income Tax on top of the capital gains rate. The surtax applies when modified adjusted gross income exceeds $200,000 (single) or $250,000 (married filing jointly), and it hits the lesser of your net investment income or the amount by which your income crosses the threshold.7Internal Revenue Service. Net Investment Income Tax A married couple with $300,000 in total income and a $100,000 capital gain would pay 3.8% on $50,000. These thresholds are not indexed for inflation.
The Primary Residence Exclusion
The biggest break for home sellers lets you exclude up to $250,000 of gain if you’re single, or up to $500,000 filing jointly.8Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence For most homeowners, this wipes out the federal tax on the sale entirely.
To qualify, you must pass two tests within the five-year period ending on the sale date:
- Ownership: you owned the home for at least two of those five years.
- Use: you lived in it as your primary residence for at least two of those five years.
The two years don’t have to be consecutive. For the $500,000 joint exclusion, both spouses must meet the use test, but only one has to meet the ownership test. You can only claim the exclusion once every two years.
Partial Exclusion for Early Sales
Sell before you meet the full two years and you may still get a prorated exclusion if the move was driven by a qualifying reason:1Internal Revenue Service. Publication 523, Selling Your Home
- A work-related move where your new workplace is at least 50 miles farther from the home than your prior workplace was.
- A health-related move to get or provide medical care.
- An unforeseeable event such as the home being destroyed or condemned, becoming eligible for unemployment, death, divorce, or multiple births from the same pregnancy.
The partial exclusion is prorated by the share of the two-year requirement you completed. One year in gets you up to half the full $250,000 or $500,000.
Military and Foreign Service Exception
Members of the uniformed services, the Foreign Service, and certain intelligence community employees can suspend the five-year test period for up to ten years while on qualified extended duty at a station at least 50 miles from the home.8Office of the Law Revision Counsel. 26 USC 121 – Exclusion of Gain From Sale of Principal Residence That effectively stretches the look-back window to as long as fifteen years.
Inherited vs. Gifted Property
How you received the property changes the math dramatically.
When you inherit real estate, your basis is the property’s fair market value on the date of the prior owner’s death, not what they paid for it.9Office of the Law Revision Counsel. 26 USC 1014 – Basis of Property Acquired From a Decedent If your parent bought a home in 1985 for $80,000 and it was worth $400,000 when they died, your basis is $400,000. Sell for $410,000, and the taxable gain is $10,000. Decades of appreciation are wiped out for income tax purposes.
Gifts work differently. When someone transfers real estate to you while they’re alive, you generally take their original basis.10Office of the Law Revision Counsel. 26 USC 1015 – Basis of Property Acquired by Gifts and Transfers in Trust Same $80,000 home, plus $20,000 in improvements, gifted when it’s worth $400,000: your basis is $100,000. Sell for $400,000 and the taxable gain is $300,000. If the property’s fair market value at the time of the gift is lower than the donor’s basis, your basis for calculating a loss is capped at that lower value.
Depreciation Recapture on Rentals
If you owned the property as a rental, the IRS takes back part of the depreciation benefit at sale. Every dollar of depreciation you claimed (or should have claimed) reduces your adjusted basis, which increases the taxable gain.
The portion of the gain attributable to prior depreciation, called unrecaptured Section 1250 gain, is taxed at a maximum rate of 25%, even if you’re otherwise in the 15% long-term bracket.6Internal Revenue Service. Topic No. 409, Capital Gains and Losses Any gain above the original purchase price is taxed at the regular long-term rates. Buy a rental for $300,000, claim $50,000 in depreciation, sell for $400,000: the first $50,000 of the $150,000 gain is taxed at up to 25%, and the remaining $100,000 at your long-term rate. This is one of the most common surprises rental sellers hit at tax time.
Deferring the Tax With a 1031 Exchange
If the property is held for investment or business use and you’re buying a replacement, a like-kind exchange under Section 1031 lets you defer the gain entirely.11Office of the Law Revision Counsel. 26 USC 1031 – Exchange of Real Property Held for Productive Use or Investment The tax doesn’t disappear; it rolls into the replacement property’s basis and waits for a future sale.
The deadlines are absolute:
- Identify potential replacement properties in writing within 45 days of the sale.
- Close on the replacement within 180 days of the sale, or by your tax return due date including extensions, whichever comes first.
A qualified intermediary must hold the sale proceeds. If you touch the money, even briefly, the exchange fails and the full gain becomes taxable. Primary residences, vacation homes, and properties held for resale (flips) don’t qualify.
Offsetting Gains With Capital Losses
Capital losses from other investments offset your real estate gain dollar for dollar. Sold stocks at a $40,000 loss the same year you realized a $100,000 gain on property? Your net taxable gain is $60,000. If losses exceed gains for the year, you can deduct up to $3,000 of the excess against ordinary income ($1,500 if married filing separately) and carry the rest forward.12Office of the Law Revision Counsel. 26 USC 1211 – Limitation on Capital Losses
One boundary worth knowing: a loss on the sale of your personal residence is not deductible. Losses only work on investment property or other capital assets.
Reporting the Sale and Paying on Time
The closing agent files Form 1099-S with the IRS reporting the gross sale proceeds.13Internal Revenue Service. Instructions for Form 1099-S You report the transaction details on Form 8949, and those figures flow to Schedule D of your return. If the full primary residence exclusion covers the gain, you generally don’t need to report the sale at all, though keeping records is still wise.
A large gain can create a tax bill big enough to trigger underpayment penalties if you wait until April. Make a quarterly estimated tax payment for the quarter in which you sold. The 2026 estimated payment deadlines are April 15, June 15, and September 15 of 2026, and January 15, 2027.14Internal Revenue Service. 2026 Form 1040-ES, Estimated Tax for Individuals Sell in July, and you’d typically make an estimated payment by September 15.
State Tax Is Separate
Federal tax is only part of the bill. Most states also tax capital gains, usually as ordinary income. A handful of states have no income tax and impose no capital gains tax. Rates, exclusions, and filing rules vary widely, so check your state’s treatment before assuming the federal number is what you’ll owe.