How Gain on a Home Sale Is Calculated
The math works like cost basis for investments. Subtract your adjusted basis from your amount realized to get your gain or loss.
| Term | What it means |
|---|---|
| Amount realized | Your selling price minus your selling expenses. |
| Adjusted basis | What you paid for the home, plus certain costs and improvements, minus certain reductions. |
Under the home sale exclusion rules, you can generally exclude up to $250,000 of gain ($500,000 if married filing jointly). You must have owned and lived in the home as your main home for at least 24 months of the 5 years before the sale. You generally can’t use the exclusion if you excluded gain from another home sale in the prior 2 years.
Purchase Records That Set Your Basis
Purchase Price and Closing Costs
Your basis starts with what you paid, including your down payment and any borrowed amount. If you built the home, start with the cost of the land plus construction.
| Costs you can add to basis | Costs you can’t add to basis |
|---|---|
| Abstract, recording and survey fees | Fire or casualty insurance premiums |
| Charges for installing utility services | Rent for living in the home before closing |
| Legal fees for the title search, sales contract and deed | Mortgage costs, such as mortgage insurance, points, appraisals and credit reports |
| Transfer or stamp taxes and owner’s title insurance | Escrow for future taxes or insurance |
Gifted or Inherited Homes
For a gifted home, record the date you received it and the donor’s adjusted basis. Also note whether gift tax was paid and the home’s fair market value (what it would sell for) at the time of the gift. You generally use the donor’s basis to calculate the gain or loss.
If you inherited the home, your basis generally resets to its fair market value on the date of death. This is called a stepped-up basis. Keep proof of that value, such as an appraisal.
Improvement Records That Raise Your Basis
Improvements that add value or extend your home’s life increase your basis, so keep the receipts. Routine repairs don’t count; these include repairs such as painting, fixing leaks, filling cracks or replacing broken hardware. Improvements that last under 1 year or are no longer part of the home, like carpet you later replaced, also don’t count. Repairs done during an extensive remodel do count.
Records That Lower Your Basis
Some events reduce your basis, which raises your gain. Keep records of:
- Depreciation you took for business or rental use, including a home office deduction.
- Casualty losses you deducted and insurance payments you received or expect to receive for them.
- Payments you received for easements or rights-of-way.
- Energy credits or subsidies for improvements included in your basis.
Sale Records That Show Your Amount Realized
Your sale price appears on Form 1099-S or your closing documents. Subtract selling expenses, which include:
- Real estate agent commissions
- Advertising fees
- Legal fees for the sale
- Mortgage points or loan charges you paid that would normally be the buyer’s
If you receive Form 1099-S, you must report the sale even if your gain is excludable. You also report it if you can’t exclude all of your gain. IRS Publication 523 explains how to report on Form 8949 and Schedule D (Form 1040). Keep in mind, you can’t deduct a loss on the sale of your main home.