Mortgage
How Does LendingTree Get Paid?
LendingTree is compensated by companies on this site and this compensation may impact how and where offers appear on this site (such as the order). LendingTree does not include all lenders, savings products, or loan options available in the marketplace.

How Does LendingTree Get Paid?

LendingTree is compensated by companies on this site and this compensation may impact how and where offers appear on this site (such as the order). LendingTree does not include all lenders, savings products, or loan options available in the marketplace.

What Is the Capital Gains Tax on a Home Sale?

Updated on:
Content was accurate at the time of publication.

Selling a home comes with its challenges — from finding a real estate agent and negotiating offers, to managing potential capital gains taxes. Understanding how the capital gains on a home sale works and learning strategies to reduce them can help lower your tax bill when it’s time to sell.

callout-icon

Key takeaways

  • You may owe capital gains taxes on the profit you earn from selling your house.
  • Capital gains are calculated by subtracting your home’s original purchase price from the sales price.
  • There are ways to avoid or reduce your capital gains taxes, including the home sale tax exclusion.
  • You may qualify to exclude up to $250,000 in profit from your home sale (or up to $500,000 for married couples filing jointly).

The IRS classifies real estate as a “capital asset,” and when you sell a capital asset and make a profit, it’s generally subject to capital gains taxes.

The good news is that many homeowners are exempt from capital gains taxes on the sale of their primary residence due to the home sale tax exclusion. Single tax filers can exclude up to $250,000 of profit, while couples who file taxes jointly can exclude up to $500,000. We’ll discuss the eligibility guidelines for the exclusion, as well as other strategies to minimize your tax bill, in the how to avoid capital gains taxes section of this article.

Short-term vs. long-term capital gains

Your capital gains tax bill depends on whether your gain is considered short term or long term. If you’ve lived in your home for at least one year, any profit you make is taxed at long-term capital gain rates, which range from 0% to 28%. Selling your home before the one-year mark means any profits will be taxed at the short-term capital gains rate, which is the same as your standard income tax rate.

Learn more about the 2025 income tax brackets.

loading image

To calculate your capital gains taxes, you’ll need to know how much profit you earned from selling your home. Your profit is the difference between what you paid for the home (the cost basis) and your sales price.

Let’s say you bought a home five years ago for $300,000 and sold it today for $600,000. This means your profit — or gain — is $300,000. As a single tax filer, you can exclude the first $250,000 of profit, meaning you’d only owe taxes on $50,000 ($300,000 – $250,000). If you’re married and file taxes jointly with your spouse, you can exclude the entire $300,000 profit (since the exclusion amount for joint filers is $500,000), meaning you won’t owe any capital gains taxes.

1. Claim the home sale tax exclusion

If you sell your home at a profit, the home sale tax exclusion can help reduce your taxable gain. Here are the home sale tax exclusion amounts by filing status.

Filing status
Exclusion amount
Single$250,000
Married filing separately$250,000
Married filing jointly$500,000

What is the 2-in-5 rule?

In order to qualify for the exclusion, you must have owned and used the home as your primary residence for at least two out of the last five years before selling it — this is known as the “two-in-five-year rule.”

Additionally, you’re generally not eligible if you’ve used the exclusion within the last two years. You may qualify for a special suspension of the five-year test period in special situations, such as if you or your spouse are members of the foreign service or Peace Corps on qualified official extended duty.

2. Use a 1031 exchange

A 1031 exchange can help you defer the capital gains taxes from the sale of your investment property by rolling the sale proceeds into another “like-kind” investment, as defined by the IRS. You cannot use a 1031 exchange for a primary residence or second home.

3. Deduct your home improvements

You can reduce your taxable gain when selling your home by deducting certain home improvements from your home’s cost basis. Smaller, cosmetic improvements — like painting or installing new flooring — usually don’t qualify, but you can deduct substantial renovations that boost your home’s value or prolong its use. Medically necessary home improvements, including installing railings or support bars, are generally tax-deductible.

4. Offset gains with capital losses

You might be able to use capital losses to offset capital gains, including those from a home sale. It’s a good idea to consult with a tax professional to determine if and when this strategy may make sense for you.

 Learn more about tax breaks for homeowners.

loading image

Seniors pay the same capital gains taxes as any other age group and are eligible for the same exclusions — they can exclude up to $500,000 in gains if they’re married filing jointly, and up to $250,000 if they’re single or married but filing separately.

You may not have to pay capital gains taxes when you sell and buy a home at the same time if you qualify for the home sale tax exclusion. As a reminder, you must have lived in the home for two out of the past five years to qualify for the exclusion.

Generally, yes, you will pay capital gains taxes on the sale of a second home, unless you make it your primary residence for at least two years to qualify for the home sale tax exclusion. If you’re not eligible for the exclusion, you’ll have to pay ordinary income tax rates on whatever the profit is when you sell the home.

You might have to pay capital gains taxes when selling an inherited home, but there are ways to reduce or avoid them. The home sale tax exclusion, along with the “stepped-up cost basis rule” can help. The step-up rule adjusts the home’s cost basis to its market value on the previous owner’s death date. This helps reduce your taxable gain, especially if you sell the house fast.

Today's Mortgage Rates

  • 6.57%
  • 5.92%
  • 6.58%
Calculate Payment

Recommended Reading