The Tax Brief real effective rates for 111+ countries — bi-weekly, free.
TAX GUIDE

Capital Gains Tax on Selling a Home 2026: $250K/$500K Rule

KEY INSIGHT
If you sell your main home you can exclude up to $250,000 of gain from income, or up to $500,000 if you file jointly, when you owned and used it as your home for at least 24 months of the last 5 years (IRS Topic 701). Gain above the exclusion is a capital gain, taxed at 0%, 15% or 20% for most people. You cannot deduct a loss on the sale of your home.
At a glance

Key Facts

Exclusion
$250,000 / $500,000 joint
Tests
Own and use 2 of last 5 years
Loss on home
Not deductible
Rates above exclusion
0%, 15%, 20%
Introduction

Most homeowners pay no federal tax when they sell their main home, thanks to a large exclusion. It is $250,000 of gain, or $500,000 for a married couple filing jointly, if you meet the ownership and use tests.

This guide explains the tests, how to figure the gain, when you owe tax, the partial exclusion and special cases, and how to report the sale, with worked examples from IRS Topic 701, Publication 523 and Topic 409.

Section 01

The $250,000 and $500,000 Exclusion

The IRS says that if you have a capital gain from the sale of 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 with your spouse. To qualify you must meet both the ownership test and the use test. You meet the ownership test if you or your spouse owned the home for at least 24 months (2 years) out of the last 5 years before the sale, and the use test if you and your spouse used it as a residence for at least 24 months of the previous 5 years.

On a joint return, either spouse can meet the ownership test but both must meet the use test individually. The two 2-year periods need not be the same, but both tests must be met within the 5-year period ending on the sale date. Generally you cannot use the exclusion if you excluded the gain from another home sold in the two years before this sale. The exclusion applies only to your main home, meaning your principal residence.

Section 02

How to Figure the Gain

Publication 523 says to subtract selling expenses from the selling price to get the amount realized, then subtract your adjusted basis; a positive number is a gain and a negative number is a loss. Events during your ownership, such as using the home for business or making improvements, can affect your gain or loss. If you sold at a loss you cannot deduct it, but you do not owe tax on the sale proceeds. If your home was transferred to a spouse or ex-spouse in a divorce settlement, you are generally considered to have no gain or loss.

Section 03

Worked Examples

SaleGain or lossTaxable after exclusion (single, $250,000)Taxable after exclusion (joint, $500,000)
Price $700,000, selling expenses $42,000, adjusted basis $300,000$358,000$108,000$0
Price $600,000, selling expenses $36,000, adjusted basis $450,000$114,000$0$0
Price $400,000, selling expenses $24,000, adjusted basis $450,000Loss of $74,000Not deductibleNot deductible

These are our illustrations and assume the ownership and use tests are met. If the $108,000 taxable gain in the first example were taxed at 15%, the federal tax would be $16,200, but the rate depends on your total taxable income; see below.

Section 04

Tax Rates on the Part You Cannot Exclude

Net capital gains are taxed at different rates depending on taxable income. For taxable years beginning in 2025 the IRS says the rate on most net capital gain is no higher than 15% for most individuals, with 0% at taxable income up to $48,350 (single and married filing separately), $96,700 (married filing jointly and qualifying surviving spouse) or $64,750 (head of household), and 20% to the extent income exceeds the 15% thresholds. Those are the 2025 figures in Topic 409. For taxable years beginning in 2026, Revenue Procedure 2025-32 sets the 0% rate at taxable income up to $49,450 (single and married filing separately), $98,900 (married filing jointly and surviving spouse) or $66,200 (head of household), and the 15% rate up to $545,500 (single), $306,850 (married filing separately), $613,700 (married filing jointly and surviving spouse) or $579,600 (head of household); above those amounts the 20% rate applies. IRS Topic 409 also says net short-term capital gains (assets held one year or less) are taxed as ordinary income, and the portion of any unrecaptured section 1250 gain from real property is taxed at a maximum 25%. For more on the brackets see our capital gains on real estate guide and capital gains brackets guide.

Section 05

Partial Exclusion and Special Cases

You may qualify for a partial exclusion, less than the full amount, if you meet one of the situations in Publication 523, which include a work-related move, a health-related move, a death, a divorce, a pregnancy with multiple children, a change in employment status, a change in unemployment compensation eligibility or another unusual event. Members of the Uniformed Services, the Foreign Service, the intelligence community and (under Publication 523) Peace Corps employees and volunteers who are on qualified official extended duty may elect to suspend the five-year test period for up to 10 years. If you sell under an installment contract, the exclusion remains available. Publication 523 says you cannot exclude the part of the gain equal to depreciation allowed or allowable after May 6, 1997, so depreciation from a home office or rental use can change the result; see our depreciation recapture guide.

Section 06

Reporting the Sale

If you receive Form 1099-S you must report the sale even if the gain is excludable, and you must also report it if you cannot exclude all of the gain. Use Schedule D and Form 8949 when required. See our Schedule D guide and Form 8949 guide. If you sold a rental or investment property rather than your main home, use our real estate guide instead.

Section 07

Official Sources

IRS Topic 701: Sale of your home, IRS: Publication 523, Selling Your Home, IRS Topic 409: Capital gains and losses.

FAQ

Frequently Asked Questions

How much capital gains tax do I pay when I sell my house?

Nothing on the first $250,000 of gain ($500,000 on a joint return) if you meet the ownership and use tests; any gain above that is a capital gain taxed at 0%, 15% or 20% for most people.

How do I calculate capital gains on the sale of property?

Selling price minus selling expenses is the amount realized; subtract your adjusted basis. Positive is a gain, negative a loss.

What is the 2-out-of-5-year rule?

You must have owned the home for at least 24 months and used it as your residence for at least 24 months within the 5 years before the sale.

Do I have to report the sale if the gain is excluded?

Yes if you receive Form 1099-S, and also if you cannot exclude all of the gain.

Can I deduct a loss on my home?

No. Publication 523 says you cannot deduct the loss, but you do not owe tax on the sale proceeds.

Can I use the exclusion twice in a short time?

Generally not if you excluded the gain from another home sold in the two years before this sale.

What if I lived there less than 2 years?

You may qualify for a partial exclusion for reasons such as a work-related move or a health-related move; see Publication 523.

Does the exclusion apply to a second home or rental?

No. The exclusion applies only to your main home.

Do military members get extra time?

Yes. Eligible members of the Uniformed Services, Foreign Service, intelligence community and (under Publication 523) Peace Corps personnel on qualified official extended duty can elect to suspend the five-year test period for up to 10 years.
Disclaimer:This guide gives general tax information for educational purposes and is not tax, legal or financial advice. Rules, forms and deadlines are set by the authorities named here and can change; check the official sources linked in this guide and talk to a qualified tax professional about your own situation.
Keep reading

Related Guides