introduction
Real Estate capital gains tax is the federal tax that may apply when you sell real estate for more than your adjusted basis. For U.S. homeowners and investors, the amount you owe depends on factors such as the property’s basis, selling expenses, holding period, type of property, income, and whether you qualify for a home-sale exclusion. The IRS treats a home as a capital asset in many situations, but different rules can apply to a personal residence, rental property, or business property.
This guide explains how real estate capital gains tax works, how to calculate a taxable gain, when the $250,000 or $500,000 home-sale exclusion may apply, how investment properties differ from primary residences, and which records you should keep before selling. Tax rules can be fact-specific, so use this article as general education and consult a qualified tax professional for advice about your situation.
What Is Real Estate Capital Gains Tax?

Real estate capital gains tax is generally a tax on the profit from selling property when the property’s sale proceeds exceed its adjusted tax basis.
The basic concept is:
Capital Gain = Amount Realized − Adjusted Basis
The IRS explains that a capital gain generally occurs when an asset is sold for more than its adjusted basis. For real estate, the basis can be affected by the original purchase price, certain improvements, depreciation, and other adjustments.
For example, suppose you purchase a property for $300,000 and later sell it for $450,000. Your starting gain is not automatically $150,000 of taxable income because selling expenses and qualifying adjustments can affect the calculation.
That distinction is important: sale price is not the same thing as taxable capital gain.
How Does Real Estate Capital Gains Tax Work?
The tax usually depends on three major questions:
- What is your adjusted basis?
- How much did you realize from the sale?
- Does a special exclusion, deduction, loss, or property-specific rule apply?
The IRS generally classifies capital gains as short-term or long-term. A property held for more than one year before sale generally produces a long-term capital gain, while property held for one year or less generally produces a short-term gain.
Long-term gains can receive preferential federal tax rates, while short-term gains are generally taxed using ordinary income tax rates.
Why the Holding Period Matters
Holding period can make a major difference.
If an investment property is held for more than one year, the resulting gain is generally treated as long-term. If it is held for one year or less, the gain is generally short-term.
However, simply holding property for more than a year does not guarantee a particular tax result. Rental property, business property, depreciation, installment sales, and other circumstances can introduce additional rules.
How to Calculate Real Estate Capital Gains
A useful starting formula is:
Adjusted Basis = Original Cost + Qualifying Capital Improvements + Certain Other Adjustments − Certain Reductions
Then:
Gain = Amount Realized − Adjusted Basis
The IRS’s home-sale guidance explains that the calculation can involve selling expenses, improvements, depreciation and other adjustments.
Step 1: Determine Your Original Cost
Your basis generally starts with what you paid for the property.
Depending on the circumstances, other acquisition-related amounts may also affect basis.
Keep documentation such as:
- Purchase closing statement
- Settlement statement
- Records of qualifying improvements
- Receipts for major renovations
- Legal or professional costs related to the acquisition
- Documentation for certain property-related adjustments
Step 2: Add Qualifying Improvements
Certain improvements can increase your tax basis.
Examples may include substantial projects that add value, extend useful life, or adapt the property to a new use.
Examples can include:
- Adding a room
- Building certain permanent structures
- Major kitchen renovations
- Significant bathroom renovations
- Replacing major components of a property
Routine repairs and maintenance generally should not automatically be treated as capital improvements. The exact tax treatment depends on the circumstances.
Step 3: Account for Depreciation
Depreciation can make the calculation more complicated when property has been used as a rental or for business purposes.
Even if you did not claim depreciation that you were allowed to claim, tax rules can require adjustments to basis. The IRS has specific rules for depreciation and the sale of rental or business property.
This is one reason investors should maintain detailed records throughout the ownership period instead of trying to reconstruct the property’s tax history immediately before a sale.
Step 4: Subtract Appropriate Selling Expenses
The amount realized from a sale can be affected by selling expenses.
Depending on the transaction, expenses connected with the sale may include certain:
- Real estate commissions
- Advertising expenses
- Legal fees
- Transfer-related costs
- Other qualifying selling expenses
The exact treatment depends on the expense and property type.
Primary Residence Capital Gains Exclusion
One of the most important U.S. tax rules for homeowners is the home-sale exclusion.
If you qualify, you may be able to exclude up to $250,000 of gain from federal income when selling your main home. A qualifying married couple filing jointly may generally be able to exclude up to $500,000 if the applicable requirements are satisfied.
This is not a $250,000 or $500,000 deduction from the sale price. It is an exclusion of qualifying gain from income.
Basic Ownership and Use Tests
Generally, you must satisfy both an ownership test and a use test to qualify for the full exclusion.
The IRS states that, generally, you must have owned the home for at least 24 months during the five-year period ending on the sale date. You generally must also have used the home as your residence for at least 24 months during that five-year period.
For married couples filing jointly, additional requirements apply.
Example of the Home-Sale Exclusion
Imagine a homeowner has a qualifying adjusted gain of $180,000 from selling a main home.
If the homeowner meets the applicable requirements for the exclusion, the entire $180,000 may potentially be excluded because it is below the $250,000 maximum for a qualifying individual.
Now imagine the qualifying gain is $325,000.
A qualifying individual may potentially exclude up to $250,000, leaving $75,000 subject to the applicable tax rules.
The actual calculation can be more complicated if there are periods of rental use, depreciation, previous exclusions, ownership changes, or other special circumstances.
Real Estate Capital Gains Tax on Investment Property
Investment and rental properties do not automatically receive the same treatment as a qualifying primary residence.
If you sell an investment property for more than its adjusted basis, you may have a taxable gain. Rental property can also involve depreciation-related rules that affect the tax calculation.
The IRS notes that certain unrecaptured Section 1250 gain from the sale of real property can be taxed at a maximum rate of 25%.
That means investors should not assume that their entire real estate gain will simply be taxed at one capital-gains percentage.
Rental Property Example
Suppose an investor buys a rental property for $400,000 and later sells it for $600,000.
The initial difference is $200,000, but the investor’s actual taxable gain may differ because the adjusted basis can change during ownership.
Depreciation claimed or allowable during the rental period can reduce basis and potentially increase the gain recognized at sale.
This is why rental-property owners should review depreciation schedules and prior tax returns before completing a sale.
What Are the Federal Capital Gains Tax Rates?
Federal long-term capital gains are generally subject to preferential rates rather than ordinary income rates.
For 2026, the IRS provides a 0%, 15%, and 20% framework for most net long-term capital gains, with the applicable rate depending on taxable income and filing status. The IRS’s 2026 inflation-adjustment guidance lists the relevant capital-gain thresholds.
For 2026, the maximum amount eligible for the 0% capital-gains rate is:
| Filing Status | Maximum 0% Rate Amount | Maximum 15% Rate Amount |
|---|---|---|
| Single | $49,450 | $545,500 |
| Married Filing Jointly | $98,900 | $613,700 |
| Married Filing Separately | $49,450 | $306,850 |
| Head of Household | $66,200 | $579,600 |
These figures relate to taxable income and the capital-gain rate structure; they should not be confused with gross income.
High-income taxpayers may also need to consider the 3.8% Net Investment Income Tax (NIIT). The NIIT can apply to certain investment income when modified adjusted gross income exceeds statutory thresholds.
State Capital Gains Tax on Real Estate
Federal tax is only part of the picture.
Your state may impose its own income tax or other tax consequences when you sell real estate. State treatment varies considerably, and some states have no individual income tax while others tax capital gains through their regular income-tax systems.
If you are selling property in a state where you do not currently live, additional state-specific issues can arise.
Before closing a large real estate transaction, consider checking:
- State income-tax rules
- Nonresident filing requirements
- State withholding requirements
- Local transfer taxes
- Property-specific taxes
- Residency rules
A federal calculation alone may not tell you your final tax liability.
How to Reduce Real Estate Capital Gains Tax Legally
Tax planning should focus on understanding legitimate exclusions, basis adjustments, timing rules and property-specific provisions.
1. Check Whether You Qualify for the Home-Sale Exclusion
If the property is your primary residence, determine whether you meet the ownership and use requirements before assuming that the gain is taxable.
The IRS specifically provides Publication 523 for taxpayers selling a home.
2. Maintain Records of Capital Improvements
Good records can help establish an accurate adjusted basis.
Keep invoices, receipts, contracts and closing documents for qualifying improvements and other relevant costs.
3. Review Depreciation
Rental and business property requires particular attention to depreciation.
Before selling, review your depreciation history with a tax professional so that you understand how it affects your adjusted basis and potential taxable gain.
4. Consider Timing
For investment property, the difference between a short-term and long-term holding period can affect the applicable federal tax treatment.
However, tax should not be the only reason to delay or accelerate a real estate sale. Market conditions, financing costs, investment objectives and personal circumstances also matter.
Real estate capital gains tax can affect homeowners and investors when they sell property for a profit. Understanding real estate capital gains tax helps sellers estimate their potential tax liability before completing a sale. The amount of real estate capital gains tax depends on factors such as adjusted basis, selling price, holding period, and available exclusions. For many homeowners, real estate capital gains tax may be reduced or excluded when they qualify for the primary residence rules. Learning how real estate capital gains tax works can also help property owners plan ahead and keep proper records. Investors should review real estate capital gains tax rules carefully because rental properties can involve depreciation adjustments. Before selling, understanding real estate capital gains tax and getting professional tax advice can help avoid costly mistakes.
5. Consider Tax-Loss Planning
Capital losses from other investments can sometimes offset capital gains under applicable tax rules.
The IRS explains that net capital losses may generally be deductible up to an annual limit, with unused amounts potentially carried forward.
Because loss rules can become complicated, coordinate the sale of investments with your broader tax plan rather than making isolated decisions.
Can You Avoid Capital Gains Tax by Buying Another House?
Buying another house does not automatically eliminate federal capital gains tax on the sale of your old home.
The commonly repeated idea that you can simply roll the gain from one personal residence into another is outdated.
Instead, qualifying homeowners generally look to the home-sale exclusion described above. Investment or business property may involve different rules, including potential eligibility for a Section 1031 like-kind exchange when the statutory requirements are met.
A 1031 exchange is not a general tax-free rule for selling a personal residence and buying another personal residence. It is a specialized provision with detailed requirements.
Common Mistakes With Real Estate Capital Gains Tax
Mistake 1: Using Sale Price as the Gain
A $500,000 sale does not necessarily mean a $500,000 capital gain.
Your gain depends on the amount realized and adjusted basis.
Mistake 2: Ignoring Improvements
Failing to maintain documentation for qualifying improvements can make it harder to establish your correct basis.
Mistake 3: Forgetting Depreciation
Rental and business property can have depreciation-related adjustments that materially affect the tax calculation.
Mistake 4: Assuming Every Home Sale Is Tax-Free
The home-sale exclusion has eligibility requirements and limits. Not every property owner automatically receives the full exclusion.
Real estate capital gains tax can affect homeowners and investors when they sell property for a profit. Understanding real estate capital gains tax helps sellers estimate their potential tax liability before completing a sale. The amount of real estate capital gains tax depends on factors such as adjusted basis, selling price, holding period, and available exclusions. For many homeowners, real estate capital gains tax may be reduced or excluded when they qualify for the primary residence rules. Learning how real estate capital gains tax works can also help property owners plan ahead and keep proper records. Investors should review real estate capital gains tax rules carefully because rental properties can involve depreciation adjustments. Before selling, understanding real estate capital gains tax and getting professional tax advice can help avoid costly mistakes.
Mistake 5: Looking Only at Federal Tax
State and local rules can affect the overall cost of a real estate transaction.
Mistake 6: Waiting Until Closing to Review Taxes
Tax planning is usually easier before the transaction is finalized. Reviewing the expected gain, basis and possible exclusions early gives you more time to identify documentation problems and professional advice needs.
A Practical Real Estate Capital Gains Tax Checklist
Before selling property, gather:
- Original purchase documents
- Closing statement from the purchase
- Records of qualifying improvements
- Receipts and invoices
- Mortgage and refinancing records
- Depreciation schedules, if applicable
- Previous tax returns
- Selling-cost estimates
- Records showing dates of ownership and occupancy
- Information about previous home-sale exclusions
- State tax information
Then calculate an estimated gain before the transaction closes.
For complicated transactions, have a qualified tax professional review the calculation.
real estate guideIRS home sale tax rulesBefore selling a property, homeowners should understand the real estate guide and review the official IRS home sale tax rules for current federal requirements.
Frequently Asked Questions
What is real estate capital gains tax?
Real estate capital gains tax generally applies when you sell property for more than its adjusted tax basis and the resulting gain is taxable. The calculation can involve the purchase price, qualifying improvements, selling expenses, depreciation and other adjustments. A qualifying sale of a primary residence may receive an exclusion of up to $250,000, or potentially $500,000 for eligible married couples filing jointly.
How much capital gains tax do you pay when selling a house?
There is no single tax amount for every home seller. Your federal liability depends on the taxable gain, filing status, income, holding period and whether you qualify for the home-sale exclusion. State taxes may also apply. For 2026, most long-term capital gains fall within the federal 0%, 15% or 20% rate structure, depending on taxable income.
How can I avoid capital gains tax on my primary residence?
You may be able to exclude up to $250,000 of qualifying gain, or up to $500,000 for certain married couples filing jointly, if the IRS requirements are met. Generally, ownership and use tests require qualifying periods within the five years before the sale. Special rules can apply to partial exclusions and unusual circumstances.
Does buying another house avoid capital gains tax?
No. Buying another personal residence does not automatically eliminate capital gains tax from the sale of your previous home. The federal home-sale exclusion is generally the key provision for qualifying homeowners. Investment-property transactions can involve different provisions, such as a properly structured Section 1031 exchange, but those rules are not the same as purchasing another personal residence.
Real estate capital gains tax can affect homeowners and investors when they sell property for a profit. Understanding real estate capital gains tax helps sellers estimate their potential tax liability before completing a sale. The amount of real estate capital gains tax depends on factors such as adjusted basis, selling price, holding period, and available exclusions. For many homeowners, real estate capital gains tax may be reduced or excluded when they qualify for the primary residence rules. Learning how real estate capital gains tax works can also help property owners plan ahead and keep proper records. Investors should review real estate capital gains tax rules carefully because rental properties can involve depreciation adjustments. Before selling, understanding real estate capital gains tax and getting professional tax advice can help avoid costly mistakes.
Do I pay capital gains tax on a rental property?
A rental property can produce taxable gain when sold, and the calculation can be more complicated than a primary-home sale because depreciation may affect adjusted basis. Certain depreciation-related gain can receive different tax treatment. Investors should review depreciation records and the property’s tax basis before selling rather than relying on the purchase price alone.
Conclusion
Real estate capital gains tax is not simply a percentage of the property’s selling price. The important number is generally the taxable gain after determining the property’s adjusted basis and amount realized, followed by applying any relevant exclusions and tax rules.
The best practical step is to calculate your estimated gain before selling. Gather your purchase records, improvement receipts, depreciation information and expected selling expenses, then have a qualified tax professional review the numbers if the transaction is significant or complicated.