Home Sale Capital Gains & Section 121 Exclusion Calculator
Work out your taxable capital gain when selling a primary residence after the IRS Section 121 exclusion ($250k single / $500k married), estimate the federal tax owed, and download a professional PDF report.
| Line item | Amount |
|---|---|
| Calculate to see the worksheet | |
The exclusion applies only to gain from a qualifying primary residence; losses on a personal home are not deductible. Depreciation recapture and the 3.8% surtax can apply even when the rest of the gain is fully excluded. Figures are federal only and rounded.
How to use the capital gains exclusion calculator
Enter your sale and purchase figures, pick your filing status to set the exclusion, and the calculator works out your gain, how much Section 121 shields, and the federal tax on what is left — separating the long-term gain from depreciation recapture and the 3.8% surtax, because each is taxed differently.
Choose your filing status
Single and head of household get a $250,000 exclusion; married filing jointly gets $500,000. This is the single biggest lever on the result.
Enter the sale and purchase
Sale price and selling costs, then what you paid and what you spent on capital improvements. The calculator turns these into your gain.
Add what changes the tax
Months you qualified toward the two-year test, any depreciation claimed, and your other income — which decides your 0/15/20% rate.
Read the result and save the PDF
Taxable gain, estimated federal tax, the tax the exclusion saved you, a full worksheet and a two-page report.
How the taxable gain is calculated
The exclusion comes off the gain, not the sale price — and the gain itself is much smaller than the raw price rise once selling costs, your original price and every improvement are counted. Only what is left after the exclusion is taxed.
Worked example — a single filer sells for $650,000, bought years ago at $300,000
Amount realized: $650,000 − $40,000 costs = $610,000
Adjusted basis: $300,000 + $10,000 improvements = $310,000
Total gain: $610,000 − $310,000 = $300,000
Section 121 exclusion (single): $250,000, leaving $50,000 taxable
Tax at 15%: $50,000 × 15% = $7,500 (income stays under the $200k surtax line, so no NIIT)
The $650,000 sale — and even the full $300,000 gain — is a red herring. Only $50,000 is taxed, for about $7,500. The same sale by a married couple would owe nothing at all.
What the exclusion is worth
How the same sale plays out under different circumstances, the 2026 rates that apply to whatever is left, and the extra layers that survive the exclusion even when the main gain is wiped out.
| Situation | Exclusion | Taxable gain | Est. federal tax | Tax vs no exclusion |
|---|---|---|---|---|
| Married, 2 years | $500,000 | $0 | $0 | saves ~$67,900 |
| Single, 2 years | $250,000 | $50,000 | ~$7,500 | saves ~$45,100 |
| Single, 12 months (job move) | $125,000 | $175,000 | ~$29,100 | saves ~$23,500 |
| Single, no exclusion | $0 | $300,000 | ~$52,600 | — |
Same house, same $300,000 gain, same $100,000 of other income — and a federal bill ranging from nothing to $52,600. Filing status and how long you lived there move the number far more than anything about the property itself.
| Filing status | 0% rate up to | 15% rate up to | 20% rate above |
|---|---|---|---|
| Single | $49,450 | $545,500 | $545,500 |
| Married filing jointly | $98,900 | $613,700 | $613,700 |
| Head of household | $66,200 | $579,600 | $579,600 |
These are total-taxable-income thresholds (Rev. Proc. 2025-32). Your taxable home-sale gain stacks on top of your other income, so a big other income can push part of the gain from the 15% band into 20%. Most sellers with a taxable slice land in the 15% band.
| Total gain | Single — excluded | Single — taxable | Married — excluded | Married — taxable |
|---|---|---|---|---|
| $150,000 | $150,000 | $0 | $150,000 | $0 |
| $250,000 | $250,000 | $0 | $250,000 | $0 |
| $400,000 | $250,000 | $150,000 | $400,000 | $0 |
| $600,000 | $250,000 | $350,000 | $500,000 | $100,000 |
| $900,000 | $250,000 | $650,000 | $500,000 | $400,000 |
The taxable column is simply the gain minus the cap, never below zero. A single filer with a gain under $250,000 — or a married couple under $500,000 — has nothing taxed at all, which is why the great majority of home sales generate no federal capital gains tax.
| Layer | Rate | When it applies |
|---|---|---|
| Long-term capital gains | 0 / 15 / 20% | On gain above the exclusion; the rate is set by your total taxable income for the year. |
| Depreciation recapture | up to 25% | On depreciation claimed for a home office or rental use. Carved out of Section 121 — owed even when the rest is fully excluded. |
| Net Investment Income Tax | 3.8% | On the taxable gain once your MAGI tops $200,000 single or $250,000 married. The excluded portion does not count toward the threshold. |
| State income tax | varies | Most states tax the same gain, a handful do not. This calculator estimates federal tax only. |
The exclusion only shields the ordinary long-term gain. Depreciation and the surtax are computed separately, which is why an owner who once rented the home or claimed a home office can owe tax even when their headline gain sits well under the cap.
One house, one $300,000 gain, and the federal tax swings from $52,600 to nothing. None of that spread comes from the property — it is entirely the exclusion and how long you owned and lived in the home.
- Marriage is the biggest single lever — the $500,000 joint cap wipes out the tax on this gain entirely, where a single filer still pays on $50,000.
- Time in the home is the second — falling short of the two-year test cuts the exclusion in proportion, and the larger taxable slice drags the 3.8% surtax into play.
- Your income sets the rate, not the exclusion — it decides whether the taxable part lands in the 0, 15 or 20% band and whether the surtax applies, so two identical sales can owe different tax.
Everything the calculator works out
A handful of figures give you the full picture — the gain, what the exclusion shields, the tax on what is left, and a report you can keep with your sale paperwork.
The figures behind the exclusion
The $250,000 and $500,000 caps have not moved since 1997 and are not indexed to inflation, so they shield a shrinking share of the gain each year home prices rise. Every figure in the tool recomputes for the status, sale and income you enter.
Built for anyone selling a home
For most sellers the exclusion quietly covers the whole gain and the tax question never arises. The people who need a real number are the ones near or over the cap — and the agents helping them set expectations before a sale.
Working out the real net proceeds before deciding to sell, and whether timing or filing status changes the bill enough to matter.
- Add up your basis and improvements first
- Check you will clear the two-year test
- The sale date matters more than the season
Sitting on decades of gains that may top even the $500,000 cap, especially a single or recently widowed owner facing the smaller exclusion.
- A gain over the cap is normal after 20+ years
- A widowed seller can often still use $500k for a window
- Dig out old improvement receipts — they are basis
Giving a seller a real after-tax figure instead of a vague “you probably will not owe anything,” especially on a high-appreciation listing.
- Run it before the listing appointment
- Flag depreciation if they rented or took a home office
- Save the PDF to the client file
7 things to know about the home sale exclusion
The details that decide whether a sale is tax-free or carries a five-figure bill — and the ones that catch sellers out after the deal has closed.
Home sale capital gains FAQ
The questions sellers and their agents ask most when a sale is on the horizon and the tax question comes up.
Section 121 of the tax code lets you exclude a large chunk of the profit on selling your main home from federal tax — up to $250,000 if you file singly and $500,000 if you are married filing jointly. These caps have been fixed since 1997 and are not indexed to inflation, so they cover a smaller share of gains every year prices rise.
The exclusion applies to the gain, not the sale price, and only to a qualifying primary residence. Sell for a profit under the cap and you generally owe no federal tax on it at all; sell for more and only the excess is taxed.
Start with the amount realized — the sale price minus selling costs like the agent’s commission and closing fees. Then subtract your adjusted basis: what you paid for the home, plus the cost of capital improvements, minus any depreciation you claimed. The difference is your gain.
This is where people overestimate. Selling costs and years of improvements often knock six figures off the gain before the exclusion is even applied, so the taxable number is usually far smaller than the raw price rise suggests.
Only the part above your exclusion. A single filer with a $300,000 gain excludes $250,000 and is taxed on $50,000; a married couple with the same gain excludes all of it and owes nothing. Because the caps are large, most home sales produce no federal tax at all.
When there is a taxable slice, it is taxed at long-term capital gains rates of 0, 15 or 20% depending on your total income, with a possible 3.8% surtax on top for higher earners. Depreciation, if any, is taxed separately at up to 25%.
No, and this is the most common misunderstanding. The old rule that let you roll a gain into a more expensive home was repealed in 1997. What you do with the money afterward — buy up, buy down, rent, or spend it — has no bearing on the exclusion.
Qualification depends only on the home you sold: whether it was your primary residence and whether you met the ownership and use tests. There is no requirement to reinvest the proceeds.
To claim the full exclusion you must have owned the home and used it as your primary residence for at least two of the five years before the sale. The two years do not have to be continuous, and the ownership and use periods can overlap rather than being counted separately.
Fall short and you may still get a partial exclusion if the move was driven by a change in job location, health, or other unforeseen circumstances — proportional to the months you did qualify. A voluntary early move for other reasons generally gets nothing.
If you ever claimed depreciation on the home — for a home office or a period as a rental — that depreciation is recaptured when you sell. It is taxed at a rate of up to 25% and is specifically carved out of the Section 121 exclusion, so it is owed even when the rest of your gain is fully excluded.
Only depreciation taken after May 6, 1997 is recaptured this way. It is a frequent surprise for owners who rented the property out or deducted a home office in earlier years and assumed the exclusion would cover everything.
Yes. Section 121 can be used repeatedly — as often as once every two years. This replaced the pre-1997 rules, which allowed a one-time exclusion for owners over 55 and are no longer in effect.
The two-year clock runs from your last use of the exclusion. Sell one qualifying home and claim it, and you generally must wait two years before claiming it again on another, even if you meet every other test.
The NIIT is a 3.8% surtax on investment income, including a taxable home-sale gain, that applies once your modified adjusted gross income tops $200,000 for single filers or $250,000 for married filing jointly. Only the amount above the threshold, up to the size of the gain, is hit.
Crucially, the excluded portion of your gain does not count toward this — the exclusion keeps it out of your income entirely. That is why a fully excluded sale usually avoids the surtax even for high earners, while a large taxable slice can trigger it.
Estimation Only — Not Tax or Legal Advice: This calculator estimates federal capital gains tax on a home sale from the figures you enter and the 2026 long-term rates and Section 121 limits. It assumes a qualifying sale of a main home and does not test the ownership and use rules, non-qualified-use periods, or partial-exclusion eligibility that determine whether and how much you can exclude. It models federal tax only — state and local income taxes, which most states levy on the same gain, are not included — and it treats depreciation recapture and the 3.8% surtax in simplified form. The exclusion caps, capital gains brackets and surtax thresholds are set by federal law and change with legislation; the figures here reflect 2026 amounts, and two bills to raise or eliminate the caps were before Congress in mid-2026 but are not law. For planning purposes only; confirm your basis, holding period and eligibility, and consult a CPA or tax professional before relying on any figure for a real transaction.

