Cost basis in real estate: How to calculate

Aug 3, 2025

5-minute read

Share:

A stunning house captured during twilight hours.

When you sell a home and make a profit, you may owe capital gains tax. How much? That’s where cost basis comics in. It’s a way to figure out the overall cost of a property for tax purposes. The initial cost basis of a home includes the cost of buying the house, as well as closing costs. It also adds in capital improvements to maximize the cost of the home, which reduces how much profit you’ll pay tax on.

Nothing in this article is intended to be personalized tax advice. Please consult a tax advisor to determine the best course of action for your personal situation.

What is cost basis in real estate?

While cost basis starts with how much you spend to buy a home, it doesn’t end there. It also includes capital improvements and losses due to property damage. For tax purposes, a capital improvement is a permanent upgrade that prolongs the usefulness of a home, adds value, or readies the property for new uses. Regular maintenance is not a capital improvement.

While most people think of cost basis as only affecting taxes on a one-unit single-family home, it also affects rental properties.

See what you qualify for

Get started

Why is cost basis important in real estate?

The cost basis is important in real estate for tax purposes.

Any capital gains tax you owe when you sell your primary residence is determined by subtracting your adjusted cost basis from your profit. There also are exemptions on the first $250,000 in profit from selling your primary home if you’re filing as a single taxpayer and the first $500,000 if you’re married and filing a joint tax return. To qualify for the exemption, you must meet an ownership and use test.

As a form of asset management to limit tax liability, investment property owners will often take depreciation on their tax returns. The basis for the value that’s being depreciated is often the cost basis.

Take the first step toward the right mortgage

Apply online for expert recommendations with real interest rates and payments

What can be included in the cost basis of a property?

Your cost basis typically includes:

  • The original investment you made in the property, including any loans
  • Certain items like legal, abstract, or recording fees incurred in connection with the property
  • Any seller debts that a buyer agrees to pay

Adjusted cost basis in real estate

The cost basis of a property can change for several reasons. The most common include making improvements that increase its value, depreciation for rental properties, and insurance losses due to damage.

In most instances, you’re going to calculate your cost basis when you do your taxes after selling your home. Investors may calculate it more frequently because they would be balancing the ongoing depreciation of their investment property against the improvements made.

How to calculate your adjusted cost basis

The formula for cost basis is:

Price + Eligible closing costs + Home improvements - Depreciation (if applicable)

Depreciation only applies to investment properties, not to your primary residence.

Factors that can affect your cost basis

For most people, the most significant factor affecting their cost basis is increased value through home improvements, but there are other factors.

Can reduce cost basis

Can increase cost basis

Depreciation

Additions to the home

Insurance claims for damages or theft

Investments made to fix damages or losses

Tax credits for home energy improvements

Legal fees spent to address tax issues

Certain canceled debt

Replacing roof

Postponed gains for the sale of your home

Paving your driveway

Investment credit taken

Installing central air

Rebates that are adjustments to the sale price

Rewiring a house

Easements

Assessments for local improvements like water connections, sidewalks, and roads

Personal disposition of the depreciable property

Legal costs to defend and protect the title

Residential energy credits

Legal fees related to zoning


 
 
 
 
 
 
 
 

Make your offer stand out!

Get a Verified Approval with Rocket Mortgage® today

How cost basis changes with inherited or gifted property

Inherited or gifted property is treated differently when it comes to determining taxes. The value is generally updated the day the gift or inheritance is received.

Cost basis and inherited property

When it comes to inherited property, the basis in the home is often the fair market value at the time of death, based on tax records if an estate tax return was filed, and based on an appraisal if it wasn’t.

If you’re a surviving spouse, it works slightly differently. The portion of ownership you receive from your partner is adjusted on the date of their death. The basis for your portion of ownership is the same as the day you bought the house, so adding the two together gives you your new basis.

The exception to this is in community property states, where the value of the home becomes the cost basis for the property on the day of a spouse’s passing, as long as at least half the value of the property interest can be included in the estate.

Cost basis and gifted property

Gifted property has several tax implications. The person giving the gift typically pays any gift tax that is owed. Generally, the receiver’s cost basis is the donor’s adjusted basis at the time of the gift, with a couple of exceptions:

If the donor’s adjusted basis is more than the fair market value of the home, you use the fair market value of the home as your basis in any sale.

If the donor paid the gift tax and their adjusted basis was less than the home’s fair market value, the amount of federal gift tax is added to the adjusted basis.

For investors, there may be an advantage to giving away rental property. While there are gift tax implications, depreciation recapture doesn’t get triggered based on the transfer, which could result in a lower tax bill.

Examples of calculating cost basis in real estate

If you’re looking to calculate cost basis, it helps to see some examples.

For homeowners

Michelle bought her home 3 years ago for $180,000, paying $6,000 in eligible closing costs. She added a mother-in-law suite for $50,000. She had a $10,000 insurance claim to cover the roof replacement. The current worth is $450,000. What’s the cost basis?

In this case, the formula for determining cost basis is:

Original sales price + Eligible closing costs + Improvements - insurance claims

$180,000 + $6,000 + $50,000 - $10,000 = $226,000

For investors

Richard and his two daughters purchased a condominium building with eight units 15 years ago for $500,000. The property is now worth $2 million. They took the maximum allowable depreciation. What’s the cost basis?

In this case, your cost basis formula is:

Original sales price – Depreciation

The key in this case is to be able to calculate depreciation. There are multiple ways to do this, depending on the formula used; however, let’s assume Richard and his daughters used the general depreciation system, employing a straight-line convention. The amount of yearly depreciation you can take is the original sales price divided by 27.5.

$500,000 ÷ 27.5 = $18,181

Next, you multiply maximum yearly depreciation by the number of years you’ve owned the property.

15 × $18,181 = $272,715

To determine cost basis, subtract the current depreciation from the original value.

$500,000 - $272,715 = $227,285

If you were gifted property

Isaiah’s older brother, Isaac, gifted him a lake house that was initially purchased for $215,000. There were $6,450 in eligible closing costs. It has a porch for which Isaac originally paid $20,000. Isaac paid the gift tax. At the time of the gift, it was worth $630,000.

Since the property has gone up in value since Isaac bought it, Isaiah’s cost basis is Isaac’s adjusted cost basis in the home:

Purchase price + Eligible closing costs + Improvements

Substituting in the numbers:

$215,000 + $6,450 + $20,000 = $241,450

The bottom line: Use cost basis to calculate your sale profit

Cost basis is the amount of your capital investment in an asset. It’s important to understand this because it’s the amount your capital gains tax is based on when you sell your home, prior to accounting for any exemptions.

If you’re ready to sell your current home and find your next one, get started with Redfin®. You can also start your mortgage application online with Rocket Mortgage®. Again, if you have questions on your personal tax situation, consult a tax preparer or financial advisor.

Headshot of a man with glasses smiling.

Kevin Graham

Kevin Graham is a Senior Blog Writer for Rocket Companies. He specializes in economics, mortgage qualification and personal finance topics. As someone with cerebral palsy spastic quadriplegia that requires the use of a wheelchair, he also takes on articles around modifying your home for physical challenges and smart home tech. Kevin has a BA in Journalism from Oakland University. Prior to joining Rocket Mortgage he freelanced for various newspapers in the Metro Detroit area.