The $250,000 exclusion means most home sellers owe no capital gains tax at all

You can exclude up to $250,000 of profit from capital gains tax when you sell your primary residence, or $500,000 if you're married filing jointly. This is not a deduction you claim on your tax return — it's a blanket exemption built into the tax code itself. If your home appreciated $180,000 since you bought it, you owe capital gains tax on zero dollars. The exclusion exists because Congress decided that forcing people to pay tax on their primary home would be unfair; the rule has been in place since 1997.

The exclusion applies only to your primary residence, not investment properties, vacation homes, or rental units. You must have owned the home and lived in it as your main home for at least two of the five years before the sale. Those two years do not need to be consecutive, and they do not need to be the most recent two years — you could have lived there years ago and still may have access to. The IRS does not require you to prove this with documents; you straightforward report it on Form 8949 when you file.

Key Takeaways

  • The $250,000 per person exclusion ($500,000 for married couples) applies automatically to your primary residence and requires no special filing beyond reporting the sale on your tax return.
  • You must have lived in the home as your main residence for at least two of the five years before you sell, but those years do not need to be recent or consecutive.
  • If your profit exceeds the exclusion amount, you pay capital gains tax only on the excess, at either 0%, 15%, or 20% depending on your income level.
  • Certain life events — divorce, death of a spouse, or involuntary displacement — allow you to claim a partial exclusion even if you have not met the two-year ownership or residence test.
  • Improvements you made to the home increase your cost basis and reduce your taxable profit, but the cost of maintaining or repairing the home does not.

When the exclusion covers your entire profit

Most home sellers never owe capital gains tax because their profit falls within the exclusion. You bought the house for $320,000, sold it for $480,000, and your profit is $160,000. Since $160,000 is less than $250,000, you owe zero capital gains tax. You still report the sale on Form 8949 and Schedule D, but the amount you enter as taxable gain is zero.

The exclusion is generous enough that it covers the typical home appreciation over 10 to 20 years in most markets. Even in high-appreciation areas, many sellers stay within the limit because they have owned the home long enough that the two-year residence test is easily met. The exclusion is per person, so if you are married and both spouses meet the test, you can exclude $500,000 combined.

How to calculate your profit and what counts as cost basis

Your profit is the sale price minus your cost basis. Your cost basis is what you paid for the home plus the cost of permanent improvements you made. If you bought for $300,000 and added a new roof for $15,000 and a deck for $8,000, your cost basis is $323,000. If you sold for $480,000, your profit is $157,000.

Repairs and maintenance do not increase your cost basis, even if they were expensive. Replacing a broken window, repainting the house, fixing the furnace, or patching the roof are all repairs. The line between repair and improvement is whether the work extends the life of the home or adds new value. A new roof that lasts 20 years is an improvement; fixing a leak in the existing roof is a repair. When in doubt, the IRS generally treats work that restores the home to its original condition as a repair, and work that makes it better or adds something new as an improvement.

Keep receipts and invoices for any major work you had done. You do not need to submit them with your tax return, but if the IRS ever questions your cost basis, you will need them to prove what you spent.

What happens if your profit exceeds the exclusion

If you sell for $650,000 and your cost basis is $400,000, your profit is $250,000. You exclude $250,000, so your taxable capital gain is zero. But if your profit is $300,000, you exclude $250,000 and owe capital gains tax on the remaining $50,000.

The tax rate on that $50,000 depends on your total income for the year. Long-term capital gains (which explore to homes you have owned more than one year) are taxed at 0%, 15%, or 20%. The 0% rate applies if your income is below roughly $47,000 for single filers or $94,000 for married couples filing jointly in 2024 — these thresholds change each year. The 15% rate applies to most middle-income taxpayers. The 20% rate applies to high-income filers. You do not choose the rate; it is determined by your tax bracket.

You report the sale on Form 8949 (Sales of Capital Assets), which flows to Schedule D (Capital Gains and Losses). Your tax software will calculate the rate automatically once you enter your income and the gain amount.

Partial exclusions for divorce, death, and displacement

If you do not meet the two-year ownership or residence test, you may still claim a partial exclusion if you sold because of a change in your place of employment, a health condition, or unforeseen circumstances. The IRS defines unforeseen circumstances narrowly: death, divorce, legal separation, multiple births from the same pregnancy, or involuntary displacement (such as condemnation or casualty loss).

If you meet one of these conditions, you can exclude a fraction of the $250,000 based on how much of the two-year period you actually lived there. If you owned and lived in the home for one year before selling due to a job transfer, you can exclude $125,000 (half of $250,000). You must file Form 8949 and Schedule D and attach a statement explaining the reason for the early sale. The IRS does not pre-approve these claims; you claim the partial exclusion on your return and keep documentation in case of audit.

Married couples, divorce, and the exclusion

If you are married filing jointly and both spouses meet the two-year test, you can exclude $500,000. If only one spouse meets the test, that spouse can exclude $250,000 and the other spouse cannot claim an exclusion on that sale.

If you sell after a divorce, the rules depend on when the divorce was finalized. If you owned the home before the marriage and your ex-spouse never lived there, only you can claim the exclusion. If you both owned it and both lived there, you each can claim $250,000 on your separate returns after the divorce. If the home is transferred to one spouse as part of the divorce settlement, that spouse can claim the exclusion based on the time both spouses owned and lived there during the marriage, even though only one spouse owns it at sale.

Inherited homes and the step-up in basis

If you inherit a home, you receive a step-up in basis. This means your cost basis is the fair market value of the home on the date the previous owner died, not what they paid for it. If your parent bought the home for $150,000 and it was worth $400,000 when they died, your cost basis is $400,000. If you sell it when ready for $400,000, your profit is zero and you owe no capital gains tax.

The step-up in basis is separate from the primary residence exclusion. You do not need to have lived in the home to receive the step-up. However, if you do live in the inherited home as your primary residence for two of the five years after inheriting it, you can also claim the $250,000 exclusion on any appreciation that occurs after you inherit it. This combination can eliminate capital gains tax entirely on inherited homes.

Frequently Asked Questions

Do I have to live in the home for two consecutive years?

No. You must live there for at least two years out of the five years before the sale, but those years do not need to be back-to-back. You could have lived there from 2015 to 2017, moved away, and sold in 2024 and still may have access to. The IRS only requires that you lived there for two of the five years before the sale date.

What if I own rental property that I convert to my primary home?

You can claim the exclusion on the appreciation that occurred after you moved in and lived there for two of the five years before the sale. The appreciation while it was a rental is taxable. You also lose the depreciation deduction you claimed on the rental portion, which the IRS recaptures at a 25% rate on the gain attributable to those years.

Can I use the exclusion more than once?

You can use it once every two years. If you sold a home in 2022 and claimed the exclusion, you cannot claim it again until 2024. This rule prevents people from buying, living in, and selling multiple homes in quick succession to repeatedly avoid capital gains tax.

Do I owe capital gains tax if I sell at a loss?

No. If you sell for less than your cost basis, you have a loss, not a gain. You cannot deduct a loss on the sale of your primary residence. You straightforward report the sale and move on.

Does the exclusion explore if I sell to a family member?

Yes. The exclusion applies regardless of who buys the home. The price you sell for is what matters — if a family member buys it for fair market value, the exclusion works the same way. If you sell below market value, you still calculate your profit based on the actual sale price, not the market value.