Learn the complete process of calculating capital gains tax on your real estate investments with step-by-step examples, current tax rates, and optimization strategies for 2026.

Understanding Capital Gains Tax on Real Estate

When you sell a real estate investment for more than you paid for it, you've realized a capital gain. The IRS requires you to pay taxes on this gain, but the amount depends on several factors including how long you owned the property, your income level, and the type of property sold.

Key Insight

Capital gains tax rates are significantly lower than ordinary income tax rates, especially for properties held longer than 12 months. This makes real estate an attractive long-term investment vehicle.

Step 1: Determine Your Adjusted Basis

Your adjusted basis is the starting point for calculating capital gains. It includes:

  • Purchase Price: The original amount you paid for the property
  • Purchase Costs: Closing costs, title fees, legal fees, and inspection costs
  • Capital Improvements: Major renovations that add value or extend property life
  • Less Depreciation: For investment properties, subtract any depreciation claimed

Adjusted Basis Formula:

Adjusted Basis = Purchase Price + Purchase Costs + Capital Improvements - Depreciation

Example: Calculating Adjusted Basis

Property Details:

  • Purchase Price: $300,000
  • Purchase Costs: $8,000
  • Capital Improvements: $25,000 (new roof, kitchen remodel)
  • Depreciation Claimed: $15,000

Adjusted Basis = $300,000 + $8,000 + $25,000 - $15,000 = $318,000

Step 2: Calculate Your Capital Gain

Once you have your adjusted basis, calculating the capital gain is straightforward:

Capital Gain Formula:

Capital Gain = Sale Price - Selling Costs - Adjusted Basis

What Are Selling Costs?

Selling costs typically include:

  • Real estate agent commissions (usually 5-6% of sale price)
  • Staging and marketing costs
  • Legal and closing fees
  • Title insurance and transfer taxes
  • Home repairs required for sale

Continuing Our Example:

  • Sale Price: $450,000
  • Selling Costs: $27,000 (6% commission + $2,000 other costs)
  • Adjusted Basis: $318,000 (from Step 1)

Capital Gain = $450,000 - $27,000 - $318,000 = $105,000

Step 3: Determine Long-term vs Short-term

The length of time you owned the property significantly affects your tax rate:

Holding Period Tax Treatment Tax Rates
12 months or less Short-term capital gain Taxed as ordinary income (up to 37%)
More than 12 months Long-term capital gain Preferential rates: 0%, 15%, or 20%

Step 4: Apply the Correct Tax Rate

For long-term capital gains, your tax rate depends on your total taxable income and filing status:

2026 Long-Term Capital Gains Tax Rates (Taxable Income)

Single Filers

Income Range Tax Rate
$0 - $49,450 0%
$49,451 - $545,500 15%
$545,501+ 20%

Married Filing Jointly

Income Range Tax Rate
$0 - $98,900 0%
$98,901 - $613,700 15%
$613,701+ 20%

Step 5: Calculate Additional Taxes

Depreciation Recapture Tax

If you claimed depreciation on the property, the part of your gain equal to that depreciation (up to the total gain) is taxed at your ordinary income rate, capped at 25%.

Net Investment Income Tax (NIIT)

High-income earners may owe an additional 3.8% tax on investment income:

  • Single filers with income over $200,000
  • Married filing jointly with income over $250,000
  • Married filing separately with income over $125,000

State Capital Gains Tax

Don't forget state taxes! Rates vary significantly by state:

  • No state tax: Alaska, Florida, Nevada, New Hampshire, South Dakota, Tennessee, Texas, Wyoming, plus Missouri (repealed its capital gains tax in 2025) and Washington (its capital gains tax exempts real estate)
  • High state taxes: California (13.3%), New York (10.9%), New Jersey (10.75%)
  • Moderate taxes: Most other states range from 3-8%

Complete Calculation Example

Scenario: Investment Property Sale

Property Details:

  • Purchased: January 2020 for $300,000
  • Capital improvements: $25,000
  • Depreciation claimed: $15,000
  • Sold: March 2026 for $450,000
  • Selling costs: $27,000
  • Owner taxable income before the sale: $120,000 (married filing jointly)
  • State: California

Calculation Steps:

  1. Adjusted Basis: $300,000 + $25,000 - $15,000 = $310,000
  2. Capital Gain: $450,000 - $27,000 - $310,000 = $113,000
  3. Holding Period: 6+ years = Long-term gain
  4. Federal Tax Rate: 15% (2026 married filing jointly band: $98,901–$613,700 of taxable income)
  5. Federal Capital Gains Tax: $98,000 × 15% = $14,700
  6. Depreciation Recapture: $15,000 × 22% = $3,300 (taxed at the ordinary rate, here the 22% bracket, never more than 25%)
  7. California State Tax: $113,000 × 13.3% = $15,029 (top rate, a conservative estimate)
  8. NIIT: $0 (income plus gain of $233,000 is under the $250,000 threshold)
  9. Total Tax: $14,700 + $3,300 + $15,029 = $33,029

Gain After Tax: $113,000 - $33,029 = $79,971

Effective Tax Rate: 29.2%

From sale price to tax: the complete example Two stacked bars. The $450,000 sale price splits into $27,000 of selling costs, the $310,000 adjusted basis and the $113,000 gain; the amount realized, $423,000, is the sale price minus selling costs. The $113,000 gain splits into $15,000 of depreciation recapture, taxed at 22% for $3,300, and $98,000 of long-term gain, taxed at 15% for $14,700. California tax is 13.3% of $113,000, $15,029. Total tax $33,029. Sale price $450,000 Gain $113,000 Adjusted basis $310,000 Selling costs $27,000 Amount realized $423,000 The $113,000 gain, taxed by layer $98,000 Depreciation recapture $3,300 $15,000 × 22% Long-term gain $14,700 $98,000 × 15% California, on the whole gain $15,029 $113,000 × 13.3% Total tax $33,029
The complete example above: $450,000 − $27,000 selling costs = $423,000 amount realized; minus the $310,000 adjusted basis ($300,000 + $25,000 improvements − $15,000 depreciation) leaves a $113,000 gain. The $15,000 that came from depreciation is taxed at the 22% ordinary rate and the other $98,000 at 15%; California taxes the whole gain. NIIT is $0 in this example.

Tax Optimization Strategies

1. Hold for Over 12 Months

The difference between short-term and long-term capital gains rates can save you thousands. If you're close to the 12-month mark, consider waiting.

2. Harvest Tax Losses

Offset gains by selling underperforming investments at a loss in the same tax year.

3. Consider Installment Sales

Spread the gain over multiple years by accepting payments over time, potentially keeping you in lower tax brackets.

4. Use 1031 Like-Kind Exchanges

For investment properties, consider a 1031 exchange to defer taxes by reinvesting in similar property.

5. Primary Residence Conversion

If you can convert an investment property to your primary residence and live there for 2 of 5 years, you may qualify for the $250,000/$500,000 exemption.

Common Mistakes to Avoid

Warning Signs

  • Poor Record Keeping: Always save receipts for improvements and expenses
  • Ignoring State Taxes: State taxes can significantly impact your net proceeds
  • Missing Deadlines: Estimated tax payments may be required
  • DIY Complex Situations: Consult professionals for high-value or complex transactions

When to Seek Professional Help

Consider consulting a tax professional when:

  • Property values exceed $500,000
  • You're considering a 1031 exchange
  • Multiple properties are involved
  • You have complex ownership structures
  • State tax implications are unclear

Ready to Calculate Your Capital Gains?

Use our free capital gains calculator to instantly estimate your tax liability with 2026 rates.

Use Free Calculator