Most home sellers hear one number: the first $250,000 of gain is tax-free ($500,000 for a married couple filing jointly). That is true, and for most sellers it is the end of the story. But two questions decide what you really owe, and both are arithmetic: how big the “gain” is after the costs that reduce it, and, if you are over, what the tax rate on the excess turns out to be once it is stacked on top of the rest of your income. This guide works out both for 2026 with the same engine as the Home Sale Capital Gains Tax Calculator, which follows IRS Publication 523 and the Schedule D Tax Worksheet.
Step 1: how far the price can rise before there is any tax
The gain is not the sale price minus the purchase price. It is what you receive after selling costs (the agent's commission, title and transfer costs, legal and advertising fees) minus your basis: the purchase price, the closing costs of buying that are part of the price, and the cost of improvements that are still part of the home, less any depreciation (Publication 523, Worksheet 2). Tax starts when that gain is above the exclusion. Assuming selling costs of 6% of the sale price, buying costs of 2% of the purchase price that go into the basis, and no improvements, the sale price at which tax begins, by purchase price, and how many years of steady appreciation it takes to get there:
| Bought for | Single: tax begins above | Years at 3% / 5% a year | Joint: tax begins above | Years at 3% / 5% a year |
|---|---|---|---|---|
| $200,000 | $482,979 | 29.8 / 18.1 | $748,937 | 44.7 / 27.1 |
| $300,000 | $591,490 | 23.0 / 13.9 | $857,447 | 35.5 / 21.5 |
| $400,000 | $700,001 | 18.9 / 11.5 | $965,958 | 29.8 / 18.1 |
| $500,000 | $808,511 | 16.3 / 9.9 | $1,074,469 | 25.9 / 15.7 |
| $600,000 | $917,022 | 14.4 / 8.7 | $1,182,979 | 23.0 / 13.9 |
| $800,000 | $1,134,043 | 11.8 / 7.2 | $1,400,001 | 18.9 / 11.5 |
The pattern is that the exclusion is a fixed dollar amount, so it covers more of the growth on a cheaper home: the $200,000 home would have to be worth 2.4 times what was paid, the $800,000 home only 1.4 times. Every $10,000 you spend on improvements that stay part of the house raises the price at which tax begins by about $10,638 (the $10,000 divided by what is left of each dollar of price after selling costs), and in the other direction depreciation you took on a home office or rental is subtracted from the basis, so it lowers the line. These are the amounts when you qualify for the exclusion at all: you need to have owned the home and lived in it for 24 of the last 60 months (the months need not be in a row) and not to have used the exclusion on another home sale in the last 24 months.
Step 2: the tax on the excess depends on everything else you earned
The part above the exclusion is a long-term capital gain (a home owned more than a year). Long-term gains are taxed at 0%, 15% or 20%, but which one depends on where the gain sits on top of the rest of your taxable income for the year (after the standard deduction of $16,100 single or $32,200 joint). For 2026 the 0% rate applies up to $49,450 of taxable income for a single filer and $98,900 for a joint return, the 15% rate up to $545,500 and $613,700 (Revenue Procedure 2025-32, section 3.03), and 20% above. On top of that, the taxable gain counts as net investment income, so once your income including the gain is over $200,000 ($250,000 joint) you owe 3.8% of the smaller of the gain and the excess (26 U.S.C. 1411). Here is the same $100,000 of taxable gain (a single owner who bought at $400,000 and sold at $750,000; a couple who sold at $1,000,000) at different other incomes:
| Filing status | Other income | Gain taxed at 0% / 15% / 20% | Income tax | 3.8% tax | Total (share of the gain) |
|---|---|---|---|---|---|
| Single | $0 | $49,450 / $34,450 / $0 | $5,168 | $0 | $5,168 (5.2%) |
| Single | $30,000 | $35,550 / $64,450 / $0 | $9,668 | $0 | $9,668 (9.7%) |
| Single | $60,000 | $5,550 / $94,450 / $0 | $14,168 | $0 | $14,168 (14.2%) |
| Single | $100,000 | $0 / $100,000 / $0 | $15,000 | $0 | $15,000 (15%) |
| Single | $150,000 | $0 / $100,000 / $0 | $15,000 | $1,900 | $16,900 (16.9%) |
| Single | $250,000 | $0 / $100,000 / $0 | $15,000 | $3,800 | $18,800 (18.8%) |
| Single | $500,000 | $0 / $61,600 / $38,400 | $16,920 | $3,800 | $20,720 (20.7%) |
| Joint | $0 | $67,800 / $0 / $0 | $0 | $0 | $0 (0%) |
| Joint | $40,000 | $91,100 / $8,900 / $0 | $1,335 | $0 | $1,335 (1.3%) |
| Joint | $100,000 | $31,100 / $68,900 / $0 | $10,335 | $0 | $10,335 (10.3%) |
| Joint | $200,000 | $0 / $100,000 / $0 | $15,000 | $1,900 | $16,900 (16.9%) |
| Joint | $300,000 | $0 / $100,000 / $0 | $15,000 | $3,800 | $18,800 (18.8%) |
| Joint | $800,000 | $0 / $0 / $100,000 | $20,000 | $3,800 | $23,800 (23.8%) |
Three things the table shows. First, a low-income seller can sell above the exclusion and pay little or nothing: a single filer with $30,000 of other income has $35,550 of the gain in the 0% stretch (the $49,450 limit less the $13,900 of taxable income already there), and a couple with no other income pays no income tax at all on $100,000 because the gain, less their $32,200 deduction, stays under $98,900. This is usually a retiree's situation, and it is why the gain, not just the price, is what matters. Second, the 15% rate covers a wide middle: from $65,550 of other income the whole gain is at 15% for a single filer, and income does not change the rate again until the 3.8% tax adds to it above $200,000 of total income (the $1,900 in the $150,000 row is 3.8% of the $50,000 by which income with the gain passes $200,000). Third, the top rate is a late arrival: 20% only starts at $545,500 single or $613,700 joint of taxable income, so a couple with $800,000 of other income pays the full 23.8% on the whole $100,000.
Selling before 24 months: a partial exclusion, in proportion
If you fall short of the 24 months you get no exclusion, unless the main reason for the sale was a work-related move (a new job at least 50 miles farther from the home), a health-related move or an unforeseeable event (Publication 523). Then the exclusion is the shortest of your months of residence, months of ownership and months since your last exclusion, divided by 24, times $250,000 (each spouse separately on a joint return):
| Months owned and lived in | Single | Joint, both spouses |
|---|---|---|
| 6 | $62,500 | $125,000 |
| 12 | $125,000 | $250,000 |
| 18 | $187,500 | $375,000 |
| 23 | $239,583 | $479,167 |
Without a qualifying reason the first dollar of gain is taxable, so at 23 months the difference between selling now and waiting a month or two is the whole exclusion, which is why the closing date matters: the tests count to the date of sale, taken from Form 1099-S or the date title transferred.
If the home was ever rented or had a home office
Two rules take part of the gain out of the exclusion. Depreciation taken or allowable after May 6, 1997 comes off first and is taxed as unrecaptured section 1250 gain, at your ordinary rate up to 25%. And after 2008, months when the home was not your main home (before you last lived there) allocate a share of the rest of the gain, equal to those months divided by the months you owned it, which cannot be excluded. Publication 523's own examples, run through the engine: bought for $400,000, rented for 2 years (taking $20,000 of depreciation), lived in for 2 years, sold for $700,000 5 years after buying: the gain is $320,000, $20,000 is recaptured, $120,000 (2 of 5 years of the remaining $300,000) is taxed as long-term gain, and $180,000 is excluded. Rental after the last day you lived there is different: a home bought for $400,000, lived in for 3 years, then rented, and sold for $600,000 had $227,000 of gain after $27,000 of depreciation, and only the $27,000 of depreciation is taxed, because the rental months after the last day of residence are not nonqualified use.
What the figures leave out
- Federal tax only, on a return whose other income is one lump; state tax is a flat rate you type in the calculator, because state rules vary.
- Co-owners, inherited or gifted homes (the basis rules differ), a separately rented part of the property, a home acquired in a like-kind exchange, installment sales, the disability test, military extensions and a surviving spouse selling within two years of a death are not modelled; Publication 523 covers each.
- The tax is worked out with the exact 2026 brackets, not the IRS Tax Table, so a figure can differ from a return by a few dollars. The tax rates and thresholds are 2026 amounts; the exclusion amounts and the net investment income tax thresholds are fixed in the statute.
To run your own sale, with your costs, months and income, use the Home Sale Capital Gains Tax Calculator. This is general information about how the tax rules work, not tax advice for your situation.
Sources
- IRS Publication 523 (2025) — Selling Your Home: the eligibility test, partial exclusion (Worksheet 1), gain or loss (Worksheet 2), taxable gain with depreciation and nonqualified use (Worksheet 3) and its Finley, Taylor and Logan examples
- 26 U.S. Code § 121 — Exclusion of gain from sale of principal residence
- IRS Revenue Procedure 2025-32 — 2026 maximum zero rate and 15% rate amounts (section 3.03), tax brackets and standard deduction (sections 3.01, 3.14)
- 2025 Instructions for Schedule D (Form 1040) — the Schedule D Tax Worksheet
- 26 U.S. Code § 1411 and the 2025 Instructions for Form 8960 — the 3.8% net investment income tax and why gain excluded under section 121 is not part of it