Capital Gains Basics When Selling a Home (And When to Ask a CPA)
Selling your home is one of the largest financial transactions most people ever make. Before you sign anything, it pays to understand how the IRS treats the profit you earn on a home sale — and to know when the numbers are complex enough that a licensed CPA should weigh in. This article covers the fundamentals in plain language so you can walk into any conversation with buyers, agents, or advisors feeling prepared.
What Is a Capital Gain on a Home Sale?
A capital gain is simply the difference between what you sell your home for and what you originally paid for it (plus certain costs). In tax language:
- Adjusted basis — your original purchase price, plus closing costs you paid when you bought, plus the cost of qualifying capital improvements you made over the years (a new roof, an addition, updated HVAC, etc.).
- Amount realized — your sale price, minus selling expenses such as agent commissions, transfer taxes, and certain closing costs.
- Capital gain — amount realized minus adjusted basis. If the result is positive, you may owe tax on that profit.
Keeping good records of what you paid for improvements over the years can meaningfully reduce your taxable gain. Receipts, permits, and contractor invoices are worth holding onto for as long as you own the property.
The Primary Residence Exclusion: The Most Important Rule to Know
Many homeowners are relieved to learn that federal tax law includes a generous exclusion for profits on a primary residence. Under current IRS rules, you may be able to exclude up to $250,000 of gain if you file as a single taxpayer, or up to $500,000 if you are married and file jointly — as long as you meet the ownership and use tests.
The Ownership and Use Tests
To qualify for the full exclusion, you generally must have:
- Owned the home for at least two of the last five years before the sale date, and
- Lived in it as your primary residence for at least two of those same five years.
The two years do not have to be continuous or the same two years as long as both tests are satisfied within the five-year window. There are also partial exclusion rules for certain situations — job relocations, health reasons, and unforeseen circumstances — so if you do not fully meet the tests, you may still qualify for a reduced exclusion.
For the authoritative details straight from the source, the IRS publishes guidance on home sale gains and the exclusion rules at IRS.gov, including Publication 523, which walks through the ownership and use tests, what counts as a capital improvement, and how to report the sale.
When You Might Still Owe Taxes
The exclusion is powerful, but it does not apply in every situation. You could have a taxable gain if:
- Your profit exceeds the exclusion limit (homes in high-appreciation markets are a common example).
- You do not meet the two-year ownership and use tests.
- You used part of the home exclusively for business or as a rental, which may require recapturing depreciation you previously deducted.
- You have already used the exclusion on another home within the past two years.
If a gain is taxable, the rate you pay depends on how long you owned the home. Homes held for more than one year qualify for long-term capital gains rates, which are generally lower than ordinary income rates. Homes sold within a year of purchase are taxed at ordinary income rates. High-income households may also be subject to the Net Investment Income Tax — another reason to talk numbers with a professional before you close.
State Taxes: Don't Forget Your State Return
Federal rules get most of the attention, but your state may have its own capital gains tax treatment. Some states follow federal rules closely; others do not. Check with your state's department of revenue or a local CPA to understand your full tax picture. Your county tax office can also confirm assessed values and transfer tax obligations that affect your net proceeds.
Cash Sales and Capital Gains: Same Rules Apply
If you are considering a cash sale — selling directly to an investor or home-buying company rather than listing on the open market — the capital gains rules are exactly the same. The method of sale does not change your tax liability. What may differ is your net proceeds: a cash buyer typically offers below market value in exchange for speed and certainty, while a traditional listing may net you a higher price but involves agent commissions, repairs, showings, and a longer timeline. Neither path eliminates your potential tax obligation.
Being clear on your expected gain before you compare offers helps you make a true apples-to-apples decision.
When to Consult a CPA (and Other Professionals)
For many straightforward primary-residence sales, the exclusion wipes out the taxable gain entirely and no special reporting is needed beyond your regular return. But you should strongly consider consulting a licensed CPA or tax advisor before you sell if:
- Your expected gain is close to or exceeds the exclusion limits.
- You have used any part of the home as a rental or home office.
- You inherited the home (inherited property has different basis rules).
- You received the home through a divorce settlement.
- You are unsure whether you meet the two-year use test.
- You have a complex income picture that might trigger the Net Investment Income Tax.
A CPA can also help you time a sale strategically — for example, ensuring you clear the two-year threshold before closing, or considering which tax year a sale falls into. The Consumer Financial Protection Bureau offers resources on the financial aspects of buying and selling a home at ConsumerFinance.gov, which can be a useful starting point for understanding your overall financial position.
Beyond tax advice, you should also involve a licensed title company or real estate attorney to review any purchase agreement before you sign. If you are navigating a financially difficult situation — such as potential foreclosure or significant debt tied to the property — HUD-approved housing counseling agencies listed at HUD.gov offer free or low-cost guidance from unbiased advisors.
For general legal background on how home sale taxes work, Nolo.com publishes plain-language legal information on capital gains and real estate that many homeowners find helpful before speaking with a professional.
Practical Steps to Take Right Now
- Gather your original purchase documents and calculate your adjusted basis, including documented improvements.
- Confirm whether you meet the two-year ownership and use tests for the primary residence exclusion.
- Estimate your expected gain and compare it to the exclusion limits for your filing status.
- If your situation involves rentals, inheritance, or a large gain, schedule a conversation with a licensed CPA before you accept any offer.
- Review your state's capital gains rules separately from the federal rules.
- Keep all records — closing documents, improvement receipts, and permits — until at least three years after you file the return for the year of sale.
Understanding your tax position gives you real negotiating confidence, whether you ultimately choose a traditional listing or a direct cash sale. When you are ready to explore your options, you can request a no-obligation cash offer through Fasthomesale101. We connect homeowners with buyers who are genuinely interested in purchasing as-is, on your timeline — with no pressure to accept any offer that does not work for you.