A laptop displays an article titled "How to avoid capital gains tax when selling investment property

How to Avoid Capital Gains Tax When Selling Investment Property

By Ali Shariat, Realtor and Loan Officer · Updated

If you’re an investor, you know the thrill of watching your property value climb—but that celebration can be cut short by a hefty capital gains tax bill. When it comes time to sell, the IRS is ready to take a slice of your profits. But here’s the good news: with strategic planning and smart moves, you can legally avoid or reduce your capital gains tax burden. This guide breaks down the most effective tactics, so you keep more of your hard-earned money and continue building wealth without penalties.

Jump to:

TLDR – Quick Guide

Detailed Breakdown

1. Utilize a 1031 Exchange

A 1031 Exchange (named after Section 1031 of the IRS code) allows you to sell an investment property and reinvest the proceeds into another “like-kind” property—without immediately paying capital gains tax. The catch? You must identify the new property within 45 days and close within 180 days.

This strategy is ideal for serial investors looking to scale their portfolio without losing capital to taxes.

Learn more about 1031 exchanges

2. Convert to a Primary Residence

If you’ve been renting out a property but can make it your primary home for at least two out of the last five years before the sale, you could be eligible for the Section 121 exclusion. This lets individuals exclude up to $250,000 ($500,000 for married couples) of capital gains from their income.

While this requires a shift in lifestyle, it’s a powerful way to avoid a large tax hit—especially in hot markets.

3. Offset Gains with Capital Losses

Have other investments in the red? Now’s the time to make them work for you. Selling underperforming stocks or assets can create capital losses that offset gains from your property sale. You can also carry forward unused losses into future years.

This strategy—known as tax-loss harvesting—is often used by savvy investors to minimize taxable income.

4. Leverage Depreciation and Deductions

Over the years, you’ve likely claimed depreciation on your rental property, which lowers your cost basis. While depreciation recapture can increase your tax bill at sale, you can still reduce your gains by maximizing deductible expenses like renovations, property improvements, and agent commissions.

Pro tip: Keep meticulous records of every improvement—small upgrades add up.

5. Explore Opportunity Zones

If your property is in an IRS-designated Opportunity Zone, or if you reinvest capital gains into an Opportunity Zone Fund, you may qualify for temporary deferrals or even permanent exclusion of gains. While more complex, this approach offers significant tax advantages for long-term investors.

Explore Opportunity Zones

6. Consider Installment Sales

Instead of taking a lump sum, consider structuring the sale as an installment sale, where the buyer pays you over time. You’ll only pay taxes on the income received each year, potentially keeping you in a lower tax bracket and easing your overall tax liability.

This also improves cash flow and allows more strategic reinvestment over time.

Key Takeaways

FAQs

What is the capital gains tax rate on investment property?

Capital gains on investment property are taxed at either 0%, 15%, or 20%, depending on your income and how long you’ve owned the property. Short-term gains (under a year) are taxed at your regular income rate, which can be significantly higher.

How long do I need to hold a property to qualify for long-term capital gains?

To qualify for long-term capital gains tax rates, you must own the property for more than one year. This typically results in a much lower tax rate compared to short-term gains.

Can I completely avoid paying capital gains tax?

Yes, in certain scenarios. For example, using a 1031 exchange or converting the property into a primary residence can allow you to avoid or significantly reduce capital gains tax legally.

Do I still owe taxes if I lose money on the sale?

No. If your sale results in a loss, you may be able to deduct it from other capital gains or carry it forward to offset future gains. This helps minimize your overall tax burden.

Should I consult a professional before selling?

Absolutely. A tax advisor or real estate strategist can help you identify the best approach to minimize or avoid capital gains tax based on your specific financial situation and goals.

Browse all the areas Ali serves in our Southern California city guides. Related: the best places to invest in California real estate. Have a question about your own situation? Talk with Ali, a Realtor and licensed loan officer, or call (949) 818-1000.

Southern California City Cost & Property Tax Comparison

Compare median home prices, property taxes, Mello-Roos assessments, and estimated monthly payments across Orange County, LA, and San Diego.

MetricIrvineMission Viejo
Median Home Price$1,450,000$1,180,000
Property Tax + Mello-Roos1.35%1.1%
Mello-Roos / CFD0% to 0.6% ($2k-$8k/yr)None (CFD 87-1 expired)
Typical HOA Dues$300 - $550/mo$250 - $450/mo + Lake
Top School DistrictIrvine Unified (Top 1% CA)Capistrano & Saddleback Valley
Est. Monthly Ownership Cost$10,423/mo$8,260/mo

Monthly estimate assumes 20% down at current 30-year fixed rate, including taxes, insurance, and median HOA.

Interactive Tax Tool

Orange County Mello-Roos & Property Tax Estimator

Select a community and purchase price to estimate base Proposition 13 property taxes, local school bonds, and annual Mello-Roos (CFD) assessments.

$1,650,000
CFD Status:Active Mello-Roos CFD

Active CFD No. 2013-3 funds Great Park amenities, community centers, and new Irvine Unified schools.

Estimated Annual & Monthly Tax Breakdown

Base Property Tax (Prop 13 - 1.00%)$16,500
Local School & City Bonds (0.15%)$2,475
Mello-Roos Special Assessment (CFD)$7,800
Total Estimated Annual TaxEffective Total Tax Rate: 1.62%
$26,775
Monthly Property Tax Impact$2,231 / mo

Need the exact tax bill for a specific address?

Mello-Roos amounts vary parcel by parcel. Send Ali the address or APN, and he will pull the official Orange County Tax Collector bill for free.

Questions? Ask Ali.

Contact AliCall (949) 818-1000Text Ali

5.0 on Google (26+ reviews)$50M+ in Closed SalesRealtor® & Licensed Loan Officer

Popular guidesFHA loansJumbo loansFirst-time buyer programsWhere to invest