Answer · IRC § 121, § 1250

How much is capital gains tax on real estate?

Three kinds of property, three different answers. The section 121 exclusion, the 25% cap on depreciation recapture, and why a long-held rental costs more than the headline rates.

Tax year 2026 figures. Last updated .

The answer depends entirely on what the property was to you

There is no single real-estate rate. The same building, sold for the same gain, is taxed three different ways depending on how it was used: as your main home, as a second home, or as a rental.

Sorting that out first is most of the work. Everything else follows from it.

Your main home: often nothing at all

If you owned and lived in the property for two of the five years before the sale, section 121 lets you exclude $250,000 of gain filing single or $500,000 jointly. For most sales that covers the entire gain and the tax is zero.

The two years need not be continuous, and they need not be the same two years for ownership and residence. What the exclusion does not cover is the portion of gain attributable to depreciation claimed after May 1997 — if you ever let the property or claimed a home-office deduction, that slice remains taxable.

The ceilings are fixed in statute and have not moved since 1997. In markets where prices have multiplied since, long-tenured owners increasingly find a taxable gain above the exclusion on a home they assumed was fully covered.

A second home: the ordinary ladder, and nothing else

A holiday house, an investment flat you never let, a property bought for a child — none of these qualify for section 121, because you did not live in them as your principal residence.

The gain is simply a long-term capital gain on the 0/15/20 ladder, with the 3.8% surtax on top where modified AGI exceeds the threshold. No exclusion, but no recapture either, because you were not depreciating it.

A rental: the gain splits in two

This is where the arithmetic surprises people. While you let the property you claimed depreciation, which reduced your taxable rental income each year. That depreciation also reduced your basis. On sale, the slice of gain corresponding to it comes back as unrecaptured section 1250 gain, taxed at up to 25% rather than at the preferential rates.

So a rental sale produces two figures: the recaptured portion at up to 25%, and the residual gain on the 0/15/20 ladder. Only the second part gets the favourable treatment people expect from "capital gains".

Two clarifications that matter. The recaptured amount is the lesser of depreciation taken and total gain, so it can never exceed what you actually made. And 25% is a maximum: if your ordinary rate is below it, the lower rate applies.

Why a long-held rental costs more than the headline rate

Twenty-seven and a half years is the residential depreciation schedule, so a property held a decade has typically shed a third of its building value into depreciation. That is a third of the original cost now sitting in the 25% bucket rather than the 15% one.

Add the 3.8% surtax — a property sale often pushes modified AGI well over the threshold in a single year — and a state that taxes gains as ordinary income, and the combined rate on a long-held rental can approach or exceed 40% on part of the gain. The headline "20% top rate" describes none of that.

It is also worth knowing that depreciation is recaptured whether or not you actually claimed it. The statute says "allowed or allowable" — failing to claim it does not avoid the recapture, it just means you gave up the deduction and kept the tax.

What this calculator models, and what it does not

The calculator handles the main-home exclusion including the reduced exclusion, and the rental split into recaptured and residual gain. Select "A home you lived in" or "A rental property" and it applies the right treatment.

It does not model 1031 like-kind exchanges, instalment sale reporting under section 453, opportunity zone deferral, or the passive activity loss rules that may release suspended losses on disposal. Any of those can change the answer materially, and each is a reason to take the figure to a professional rather than act on it. The methodology page lists the full scope.

Inherited property and the stepped-up basis

Property inherited from a decedent generally takes a basis equal to its fair market value at the date of death, rather than what the deceased paid. Decades of appreciation are extinguished for tax purposes at that moment.

The practical effect is large. A house bought for $60,000 in 1985 and worth $700,000 at death passes to the heirs with a $700,000 basis. Sold shortly after for $710,000, the taxable gain is $10,000 rather than $650,000.

The holding period is automatically long-term regardless of how briefly the heir held it. This is one of the strongest arguments against selling appreciated property late in life purely to simplify an estate, and it is a genuine feature of the code rather than a loophole.

When a home is also a rental

Mixed use is common and it complicates both regimes at once. A property that was your residence and later a rental, or one where part is let, is split between the two treatments.

Depreciation claimed on the let portion is recaptured on sale and cannot be sheltered by the section 121 exclusion, however large that exclusion is. Periods of "nonqualified use" after 2008 — time the property was not your principal residence — reduce the excludable share of the gain proportionally under section 121(b)(5).

This calculator models the main-home and rental cases separately and does not split a single property across both. Where a property has a mixed history, treat the figure here as an upper or lower bound rather than an answer, and take the specifics to a professional.

Instalment sales spread the money, not always the tax

Seller financing, or any arrangement where the price arrives across more than one tax year, can be reported under section 453 so that gain is recognised as payments are received rather than all at once.

The attraction is obvious: a $600,000 gain recognised over six years may stay inside the 15% band each year where the whole amount in one year would have crossed into 20% and triggered the net investment income tax.

Two things temper it. Depreciation recapture is not spread — the unrecaptured section 1250 portion is generally recognised in full in the year of sale, however the cash arrives. And you are taking credit risk on the buyer for years, which is a commercial decision rather than a tax one.

This calculator recognises the whole gain in the year of sale. If you are considering instalment reporting, the figure here is the all-at-once case, which is the right starting point for deciding whether spreading is worth it.

Selling costs come off the gain

Easy to overlook on a property sale, where they are large. Agent commission, legal and conveyancing fees, transfer taxes and title costs all reduce the amount realised, and therefore the gain.

On a typical sale those run to several percent of the price — on a $650,000 property, often $35,000 or more. That is a direct reduction in taxable gain, worth several thousand dollars in tax at ordinary long-term rates.

Enter the net proceeds rather than the headline sale price when using the calculator, and keep the closing statement: it is the document that evidences every one of these figures.

Worked example

Computed by the same engine that powers the calculator, at the moment this page was built — not typed in by hand. Open the derivation to see every rule and citation.

A rental held long enough to matter

A single filer with $160,000 of wages sells a rental for $650,000. Adjusted basis $280,000, and $110,000 of depreciation claimed over the holding period.

Taxable income after deduction
$513,900
Taxable gain
$370,000
Tax owed without the sale
$27,134
Tax the sale added
$78,461.25
of which net investment income tax
$12,540
Total federal tax
$105,595.25
Effective rate on the gain
21.21%

The derivation shows the $110,000 of recapture taxed separately from the residual gain. Notice the recapture line carries its own rate — it is not part of the 15% figure beside it.

Caveats on this example (1)
  • Net investment income was derived from capital gains and qualified dividends only. Interest, non-qualified dividends, rents, royalties and passive business income inside ordinaryIncome are also net investment income under IRC 1411(c) and are not counted here.
Show the working — 19 steps, each with its citation
  1. Gain on sale of depreciable real property$370,000Amount realized less adjusted basisIRC 1001; IRS Pub. 544

    $650,000 amount realized less $280,000 adjusted basis, which is already net of depreciation taken.

  2. Depreciation allowed or allowable$110,000Unrecaptured Section 1250 gainIRC 1(h)(1)(E), 1(h)(6); IRS Pub. 544

    Straight-line depreciation taken over the holding period. "Allowed or allowable" means depreciation the taxpayer could have claimed counts even if it was not claimed.

  3. Unrecaptured Section 1250 gain$110,000Unrecaptured Section 1250 gain capIRC 1(h)(1)(E), 1(h)(6); IRS Pub. 544

    The lesser of $110,000 of depreciation and $370,000 of total gain. Taxed at up to 25%.

  4. Remaining long-term gain above depreciation$260,000Unrecaptured Section 1250 gainIRC 1(h)(1)(E), 1(h)(6); IRS Pub. 544

    Appreciation beyond the depreciation taken, eligible for the 0/15/20% rates.

  5. Net short-term capital gain or loss for the year$0Short-term / long-term nettingIRC 1222; IRS Pub. 550

    Assets held one year or less. Taxed at ordinary rates if a net gain.

  6. Net long-term capital gain or loss for the year$370,000Short-term / long-term nettingIRC 1222; IRS Pub. 550

    Assets held more than one year. Eligible for the 0/15/20% rates.

  7. Standard deduction-$16,100Deduction from adjusted gross incomeRev. Proc. 2025-32 4.14(1) (IRC 63(c)(2))

    Adjusted gross income of $530,000 less $16,100.

  8. Taxable income$513,900Taxable incomeIRC 63(a)

    The figure the rate tables and the capital gain ceilings are both measured against.

  9. Ordinary income taxed at 10%$1,240Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $12,400 of taxable income between $0 and $12,400.

  10. Ordinary income taxed at 12%$4,560Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $38,000 of taxable income between $12,400 and $50,400.

  11. Ordinary income taxed at 22%$12,166Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $55,300 of taxable income between $50,400 and $105,700.

  12. Ordinary income taxed at 24%$9,168Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $38,200 of taxable income between $105,700 and $143,900.

  13. Unrecaptured Section 1250 gain taxed at 24%$13,890Unrecaptured Section 1250 gain maximum rateIRC 1(h)(1)(E), 1(h)(6); IRS Pub. 544

    $57,875 at the 24% ordinary rate, which is below the 25% maximum.

  14. Unrecaptured Section 1250 gain taxed at 25%$13,031.25Unrecaptured Section 1250 gain maximum rateIRC 1(h)(1)(E), 1(h)(6); IRS Pub. 544

    $52,125 at the 25% maximum rate.

  15. Ordinary income stacked below the long-term gain$253,900LTCG bracket stackingIRC 1(h); Schedule D Tax Worksheet, Form 1040 instructions

    Long-term gain is taxed by reference to where it sits ON TOP of $253,900 of other taxable income, not from the bottom of the rate table.

  16. Long-term gain taxed at 15%$39,000LTCG bracket stackingRev. Proc. 2025-32 4.03 (IRC 1(h), 1(j)(5))

    Gain between the $49,450 zero-rate ceiling and the $545,500 15% ceiling.

  17. Net investment income tax threshold$200,000IRC 1411 thresholdIRC 1411(a)-(b); 26 C.F.R. 1.1411-2

    Modified AGI of $530,000 against the $200,000 threshold for a single filer. This threshold is statutory and is not adjusted for inflation.

  18. Net investment income tax at 3.8%$12,540Net investment income taxIRC 1411(a)-(b); 26 C.F.R. 1.1411-2

    3.8% of $330,000, the lesser of net investment income ($370,000) and the amount by which modified AGI exceeds the threshold ($330,000). Here the binding figure is the excess of modified AGI over the threshold.

  19. Total tax$105,595.25Sum of all tax stepsRev. Proc. 2025-32 (I.R.B. 2025-45)

    $105,595.25 on $530,000 of total income, an effective rate of 19.92%.

The same building, if it had been your home

Identical sale price and basis, but the property was the seller’s principal residence for the whole period and never let, so no depreciation was claimed.

Taxable income after deduction
$263,900
Taxable gain
$120,000
Tax owed without the sale
$27,134
Tax the sale added
$21,040
of which net investment income tax
$3,040
Total federal tax
$48,174
Effective rate on the gain
17.53%

The $370,000 gain is reduced by the $250,000 exclusion, leaving a much smaller taxable amount and no recapture at all. Same asset, same price — a different history.

Caveats on this example (1)
  • Net investment income was derived from capital gains and qualified dividends only. Interest, non-qualified dividends, rents, royalties and passive business income inside ordinaryIncome are also net investment income under IRC 1411(c) and are not counted here.
Show the working — 17 steps, each with its citation
  1. Gain on sale of principal residence$370,000Amount realized less adjusted basisIRC 1001; IRS Pub. 523

    $650,000 amount realized less $280,000 adjusted basis.

  2. Maximum Section 121 exclusion$250,000Section 121 exclusionIRC 121; IRS Pub. 523

    Owned for 60 months and used as a principal residence for 60 months in the 5-year lookback, both at least 24. No exclusion claimed in the prior 2 years.

  3. Section 121 exclusion applied-$250,000Section 121 exclusionIRC 121; IRS Pub. 523

    $250,000 of gain is excluded from income, the lesser of the $250,000 maximum exclusion and the $370,000 of excludable gain.

  4. Taxable long-term gain from the home sale$120,000Section 121 exclusionIRC 121; IRS Pub. 523

    Taxed at the long-term capital gain rates.

  5. Net short-term capital gain or loss for the year$0Short-term / long-term nettingIRC 1222; IRS Pub. 550

    Assets held one year or less. Taxed at ordinary rates if a net gain.

  6. Net long-term capital gain or loss for the year$120,000Short-term / long-term nettingIRC 1222; IRS Pub. 550

    Assets held more than one year. Eligible for the 0/15/20% rates.

  7. Standard deduction-$16,100Deduction from adjusted gross incomeRev. Proc. 2025-32 4.14(1) (IRC 63(c)(2))

    Adjusted gross income of $280,000 less $16,100.

  8. Taxable income$263,900Taxable incomeIRC 63(a)

    The figure the rate tables and the capital gain ceilings are both measured against.

  9. Ordinary income taxed at 10%$1,240Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $12,400 of taxable income between $0 and $12,400.

  10. Ordinary income taxed at 12%$4,560Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $38,000 of taxable income between $12,400 and $50,400.

  11. Ordinary income taxed at 22%$12,166Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $55,300 of taxable income between $50,400 and $105,700.

  12. Ordinary income taxed at 24%$9,168Ordinary income tax bracketsRev. Proc. 2025-32 4.01 (IRC 1(j)(2))

    $38,200 of taxable income between $105,700 and $143,900.

  13. Ordinary income stacked below the long-term gain$143,900LTCG bracket stackingIRC 1(h); Schedule D Tax Worksheet, Form 1040 instructions

    Long-term gain is taxed by reference to where it sits ON TOP of $143,900 of other taxable income, not from the bottom of the rate table.

  14. Long-term gain taxed at 15%$18,000LTCG bracket stackingRev. Proc. 2025-32 4.03 (IRC 1(h), 1(j)(5))

    Gain between the $49,450 zero-rate ceiling and the $545,500 15% ceiling.

  15. Net investment income tax threshold$200,000IRC 1411 thresholdIRC 1411(a)-(b); 26 C.F.R. 1.1411-2

    Modified AGI of $280,000 against the $200,000 threshold for a single filer. This threshold is statutory and is not adjusted for inflation.

  16. Net investment income tax at 3.8%$3,040Net investment income taxIRC 1411(a)-(b); 26 C.F.R. 1.1411-2

    3.8% of $80,000, the lesser of net investment income ($120,000) and the amount by which modified AGI exceeds the threshold ($80,000). Here the binding figure is the excess of modified AGI over the threshold.

  17. Total tax$48,174Sum of all tax stepsRev. Proc. 2025-32 (I.R.B. 2025-45)

    $48,174 on $280,000 of total income, an effective rate of 17.21%.

Run your own figures

Nothing you enter leaves your browser. The calculation runs locally and no values are transmitted or stored on a server — see the privacy page.

You
The sale
State

Related questions

How much is capital gains tax on real estate?

It depends on what the property was to you. On a main home, often nothing, because the section 121 exclusion covers the whole gain. On a second home, the ordinary 0/15/20% ladder. On a rental the gain splits: the part matching depreciation you claimed is unrecaptured section 1250 gain taxed at up to 25%, and only the remainder gets the preferential rates. Selling a long-held rental therefore produces a higher bill than the headline rates suggest.

Why do I owe 25% on the sale of a rental property?

Because depreciation you claimed while letting the property reduced your basis, and on sale that portion of the gain is recaptured as unrecaptured section 1250 gain. The 25% is a maximum, not a flat rate — if your ordinary rate is lower, the lower rate applies. The recaptured amount is the lesser of the depreciation taken and the total gain, so it can never exceed what you actually made on the sale.

How to avoid capital gains tax on real estate

On a main home the exclusion under IRC section 121 is the large one: $250,000 of gain excluded filing single, $500,000 jointly, if you owned and lived in the property for two of the five years before the sale. The two years need not be continuous. Falling short for a work move, a health reason or another qualifying unforeseen circumstance gives a reduced exclusion rather than none — and that reduction prorates the maximum exclusion, not the gain, which is the step most calculators get wrong. Improvements you paid for also raise your basis and shrink the gain, if you kept the receipts.

The full guide index lists every answer page, and the state comparison covers the state layer on top of these federal figures.