Capital Gains Home Sale Calculator

Calculate capital gains tax on your home sale. Apply the Section 121 exclusion ($250k/$500k) and see your taxable gain and estimated tax liability.

$
$
$
$
$
%
Capital Gain
$255,000.00
Section 121 Exclusion Used
$255,000.00
Max: $500,000.00
Taxable Gain
$0.00
Fully excluded!
Estimated Tax
$0.00
At 15.00% rate
Calculation StepAmount
Purchase Price$300,000.00
+ Improvements$50,000.00
โˆ’ Depreciation-$0.00
= Adjusted Basis$350,000.00
Sale Price$650,000.00
โˆ’ Selling Expenses-$45,000.00
= Amount Realized$605,000.00
Capital Gain$255,000.00
โˆ’ Section 121 Exclusion-$255,000.00
= Taxable Gain$0.00
Estimated Tax (15%)$0.00
Planning notes, formulas, and examples

About the Capital Gains Home Sale Calculator

When you sell your home for more than your adjusted basis, the profit is a capital gain that may be subject to federal and state taxes. However, the Section 121 exclusion allows most homeowners to exclude up to $250,000 (single filers) or $500,000 (married filing jointly) from capital gains tax if they've lived in the home as their primary residence for at least two of the past five years.

This calculator computes your capital gain by subtracting your adjusted basis (purchase price plus improvements minus depreciation) from the sale price minus selling expenses. It then applies the applicable Section 121 exclusion and shows your taxable gain and estimated tax using the long-term capital-gains rate assumptions you want to model.

Understanding your tax exposure before selling helps you time the sale strategically, make improvements that increase your cost basis, or plan for the tax liability. For investment properties, This calculator also shows the gain before considering a 1031 exchange.

When This Page Helps

Capital gains tax can take a significant bite out of your home sale profit, especially if your gain exceeds the Section 121 exclusion or if the property doesn't qualify. This calculator helps you estimate your tax liability months before selling so you can plan accordingly, potentially timing the sale to optimize your tax situation or consulting a tax professional with specific numbers.

How to Use the Inputs

  1. Enter your original purchase price.
  2. Add the cost of qualifying improvements (renovations, additions, major systems).
  3. Subtract any depreciation claimed (for home office or rental portions).
  4. Enter the expected sale price.
  5. Input total selling expenses (commissions, closing costs, etc.).
  6. Select your filing status to apply the correct Section 121 exclusion amount.
  7. Review your adjusted basis, capital gain, taxable gain, and estimated tax.
Formula used
Adjusted Basis = Purchase Price + Improvements โˆ’ Depreciation Amount Realized = Sale Price โˆ’ Selling Expenses Capital Gain = Amount Realized โˆ’ Adjusted Basis Taxable Gain = Capital Gain โˆ’ Section 121 Exclusion Estimated Tax = Taxable Gain ร— Capital Gains Rate

Example Calculation

Result: $0 taxable gain

Adjusted basis: $300,000 + $50,000 = $350,000. Amount realized: $650,000 โˆ’ $45,000 = $605,000. Capital gain: $605,000 โˆ’ $350,000 = $255,000. With the $500,000 married exclusion, the entire $255,000 gain is excluded from taxation.

Tips & Best Practices

  • Track all qualifying improvements โ€” they increase your basis and reduce taxable gain.
  • You must have owned AND lived in the home for 2 of the past 5 years to qualify for the full exclusion.
  • The exclusion can be used repeatedly, but generally no more than once every 2 years.
  • If you rented the home or claimed depreciation, that portion of gain may not qualify for the exclusion.
  • State capital gains taxes may apply in addition to federal taxes โ€” rates vary by state.
  • Consider a partial exclusion if you moved due to health, job change, or unforeseen circumstances before meeting the 2-year requirement.

Computing Your Adjusted Basis

Your adjusted basis starts with the original purchase price and adds qualifying capital improvements. New roof, kitchen remodel, room addition, HVAC replacement, and major landscaping all count. Routine maintenance, repairs, and cosmetic touch-ups generally do not increase your basis. Keep detailed records including receipts, contracts, and before/after photos.

The 2-of-5-Year Ownership and Use Test

To qualify for the full Section 121 exclusion, you must have owned the property AND used it as your primary residence for at least 24 months during the 60 months preceding the sale. The ownership and use periods don't need to be concurrent, and short absences (vacations, seasonal absences) generally count as periods of use.

Special Situations

Partial exclusions are available if you sell before meeting the 2-year requirement due to a job change, health condition, or unforeseen circumstances. If you used the property as a rental before converting it to your primary residence, gain attributable to rental periods after December 31, 2008, is not eligible for the exclusion.

Sources & Methodology

Last updated:

Frequently Asked Questions

  • Section 121 of the Internal Revenue Code allows homeowners to exclude up to $250,000 (single) or $500,000 (married filing jointly) of capital gains from the sale of their primary residence. You must have owned and used the home as your main residence for at least 2 of the 5 years before the sale.