When you sell real estate, the IRS does not tax the sale price. It taxes the gain, which is the amount realized on the sale minus your adjusted basis in the property. Get the basis calculation wrong, or lose the records needed to prove it, and you can end up overpaying (or underpaying, with penalties attached) when the return is filed.
The basis rules are not the same for every property. A primary residence, a second home, and an inherited property are each treated differently under the tax code. Understanding those differences, before a sale is on the calendar, is one of the more overlooked pieces of real estate and estate planning.
Key takeaways
- Taxable gain is calculated as amount realized minus adjusted basis, not the full sale price.
- A primary residence's basis starts at purchase price plus qualifying capital improvements, and may benefit from the Section 121 exclusion.
- A second home follows similar basis rules but generally does not qualify for the primary-residence exclusion.
- Inherited property typically receives a “step-up” in basis to fair market value as of the date of death, while gifted property generally carries over the original owner's basis.
- Good records (purchase documents, improvement receipts, appraisals) are what make any of these basis positions defensible to the IRS.
What cost basis means and why it matters
At its simplest, your cost basis is what you are allowed to subtract from the sale proceeds before the IRS calculates your taxable gain. The IRS explains in Publication 523 that adjusted basis generally reflects acquisition cost plus capital improvements, reduced by items such as depreciation or casualty-loss deductions. A higher, well-documented basis generally means a smaller taxable gain. A basis you cannot substantiate can mean the IRS defaults to treating more of the proceeds as taxable.
Capital improvements vs. repairs: what actually counts
Not every dollar spent on a home affects its basis. The IRS draws a sharp line between capital improvements, which are added to basis, and repairs, which maintain a property but do not change its tax basis. Knowing which bucket a given project falls into is often the difference between a smaller taxable gain and a larger one.
Projects that generally count as capital improvements include:
- Room additions, finished basements, or finished attics
- A new roof, siding, or windows
- A new heating, cooling, or ventilation system
- New or upgraded plumbing, wiring, or a septic system
- A kitchen or bathroom remodel
- A new driveway, walkway, deck, or in-ground pool
- Permanent landscaping, such as a retaining wall or drainage system
Projects that are generally treated as repairs or routine maintenance, and that do not increase basis, include:
- Painting interior or exterior surfaces
- Fixing a leaky faucet or patching a small roof leak
- Replacing a few broken tiles or a cracked windowpane
- Routine servicing of a furnace, HVAC system, or appliances
- Unclogging drains or cleaning gutters
The line is not always obvious. A repair performed as part of a larger renovation, such as replacing a section of drywall during a full kitchen remodel, is generally absorbed into that capital improvement. An isolated, standalone repair made simply to keep the home in working order typically is not. When in doubt, keep the invoice and a short note describing the scope of the work; that record is what ultimately supports the basis you claim.
Primary residence: purchase price, improvements, and the home sale exclusion
For a primary residence, basis generally starts with the purchase price, including certain assumed debt and qualifying acquisition costs, as described in IRS Publication 523. From there:
- Basis increases for qualifying capital improvements, meaning work that adds value, prolongs the home's useful life, or adapts it to new uses, not routine repairs and maintenance.
- Basis decreases for items such as depreciation (if any portion of the home was used for business or rental) or casualty-loss deductions already claimed.
Many homeowners who sell a primary residence do not owe any federal tax on the gain, because of the Section 121 home sale exclusion of up to $250,000 for single filers and $500,000 for married couples filing jointly, when ownership and use requirements are met. The exclusion does not eliminate the need to track basis; it applies after gain is calculated, and any gain above the exclusion amount is still taxable.
Second home: similar math, different exclusion rules
A second home, such as a vacation property, is generally treated as a capital asset under the same basic framework: purchase cost plus qualifying improvements, adjusted for depreciation if the property was ever rented out. The IRS notes that sales of a second residence are reported on Form 8949 and Schedule D.
The key difference from a primary residence is the exclusion. A second home generally does not qualify for the Section 121 exclusion unless it independently meets the ownership-and-use requirements of a principal residence for the relevant period. In practice, that means most vacation home sales generate a fully taxable capital gain, calculated the same way as any other investment property sale.
If the second home was ever rented out, depreciation taken (or depreciation you were allowed to take, whether or not you claimed it) reduces basis and can trigger depreciation recapture on sale, taxed differently from the rest of the gain.
Inherited property: the step-up in basis
Inherited real estate works differently from either of the scenarios above. Rather than carrying over what the decedent originally paid, the property generally receives a basis equal to its fair market value on the date of death, or the alternate valuation date if the estate's personal representative properly elects it, per IRS Publication 551. If a federal estate tax return (Form 706) was filed or required, the value reported there generally controls the beneficiary's basis.
This “step-up” can meaningfully reduce or even eliminate capital gains tax for an heir who sells relatively soon after inheriting, since much or all of the appreciation that occurred during the decedent's lifetime is effectively erased for tax purposes.
This is a meaningful contrast with gifted property, which generally retains the original owner's basis (carryover basis) rather than stepping up to current fair market value. A home given during the owner's lifetime and a home passed at death can produce very different tax outcomes for the recipient, even if the property itself is identical.
Why records matter
None of these basis calculations are useful if you cannot document them. The IRS specifically instructs taxpayers to keep records of events affecting basis, including:
- Original purchase and closing documents
- Receipts and invoices for capital improvements, potentially spanning decades of ownership
- Appraisals or Form 706 valuations establishing fair market value at the date of death for inherited property
- Records of any depreciation claimed on a property that was ever rented
Common mistakes to avoid
- Confusing repairs with capital improvements. This is one of the most common basis-tracking errors; see the breakdown above for how the IRS draws the line.
- Losing track of improvements made decades ago. Homeowners who hold a property for 20 or 30 years often cannot reconstruct improvement costs without contemporaneous records.
- Assuming a gift carries the same step-up as an inheritance. Gifted property generally keeps the giver's original basis; this is a frequent and costly misunderstanding.
- Overlooking depreciation recapture on a second home that was ever rented. Depreciation allowed or allowable reduces basis and can create a separately taxed recapture amount, whether or not it was actually claimed.
- Treating the sale price as the taxable amount. Tax is based on gain, amount realized minus adjusted basis, not the gross proceeds from closing.
When to talk with us
Cost basis questions rarely show up in isolation. They tend to surface alongside broader decisions: whether to sell a vacation home, how to structure an inheritance, or how real estate fits into a larger estate and tax picture. We do not provide individualized tax or legal advice in isolation, and we encourage coordinating with your CPA or estate attorney on the specifics of your situation. If you would like to talk through how a property sale or inheritance fits into your overall financial plan, schedule a call with us.
Frequently asked questions
Does paying off my mortgage change my taxable gain? No. Mortgage payoff does not factor into the gain calculation. Gain is based on amount realized minus adjusted basis, regardless of how much debt was outstanding.
Do all home improvements increase my basis? No. Only capital improvements that add value, extend useful life, or adapt the property to new use generally count. Routine repairs and maintenance generally do not.
Does a second home automatically qualify for the home sale exclusion? Generally not. The Section 121 exclusion is tied to ownership and use as a principal residence, which most second or vacation homes do not satisfy.
Does inherited property keep the original owner's basis? Generally no. Inherited property typically receives a new basis equal to fair market value on the date of death, which is different from the carryover basis rule that applies to gifted property.
What records should I keep for an inherited property? Keep any estate valuation or appraisal, Form 706 information if an estate tax return was filed, and records of any improvements or depreciation after you inherited the property.
