Avoiding Capital Gains Tax When Selling Your Home: Read the Fine Print (2024)

If you sell your home, you may exclude up to $250,000 of your capital gain from tax, or up to $500,000 for married couples; but there's a lot of fine print that can help or hurt you.

You probably know that if you sell your home, you may exclude up to $250,000 of your capital gain from tax. For married couples filing jointly, the exclusion is $500,000. Also, unmarried people who jointly own a home and separately meet the tests described below can each exclude up to $250,000.

To claim the whole exclusion, you must have owned and lived in your home as your principal residence for an aggregate of at least two of the five years before the sale (this is called the "ownership and use test"). You can claim the exclusion once every two years.

But even if you don't meet this test, you still might be entitled to a whole or partial tax break, in certain circ*mstances. Here, we'll give an overview of the most important possibilities for either taking advantage of the exclusion or qualifying for it at all.

Is Your Gain on the Sale Low Enough to Be Covered by the Tax Exclusion?

Many people mistakenly believe that their gain is simply the profit on the sale: "We bought it for $100,000 and sold it for $650,000, so that's a $550,000 gain, and we're $50,000 over the exclusion, right?". It's not so simple; which is a good thing, since the fine print can actually work to your benefit.

Your gain is calculated by taking your home's selling price minus:

  • deductible closing costs
  • selling costs, and
  • your tax basis in the property.

Deductible closing costs include points or prepaid interest on your mortgage and your share of the prorated property taxes.

Selling costs include, for example, real estate broker's commissions, title insurance, legal fees, advertising costs, administrative costs, escrow fees, and inspection fees. (See When Home Sellers Can Reduce Capital Gains Tax Using Expenses of Sale.)

Your basis in the property is its original purchase price, plus purchase expenses, plus the cost of capital improvements, minus any depreciation and casualty losses or insurance payments. (See Tax Reasons to Keep Good Records of Home Improvements.)

So, for example, let's say you and your spouse bought a house for $100,000 and sold for $650,000. You'd added $20,000 in home improvements, spent $5,000 fixing the place up for the sale, and paid the real estate brokers at least $25,000 in commissions. The capital gains tax exclusion plus those costs would mean you'd owe no capital gains tax at all.

For more information, see IRS Publication 551, Basis of Assets, and look for the section on real property.

Do You Meet the Ownership and Use Test for the Capital Gains Tax Exclusion—or Qualify for an Exception to It?

Now let's say that you haven't lived in your home a total of two years out of the last five. You might still be eligible for a partial exclusion of capital gains, however, if:

  • you sold because of a change in your employment
  • your doctor recommended the move for your health, or
  • you're selling it during a divorce or due to other unforeseen circ*mstances such as a death in the family or multiple births. ("I changed my mind about living here" won't cut it.)

In any such a case, you'd get a portion of the exclusion, based on the portion of the two-year period you lived there. To calculate it, take the number of months you lived there before the sale and divide it by 24.

For example, if an unmarried taxpayer lives in her home for 12 months, and then sells it for a $100,000 profit due to an unforeseen circ*mstance, the entire amount could be excluded. Because she lived in the house for half of the two-year period, she could claim half of the exclusion, or $125,000. (12/24 x $250,000 = $125,000.) That covers her entire $100,000 gain.

Nursing Home Stays and the Ownership and Use Test

For people who've moved to a nursing home, the ownership and use test is lowered to one out of five years in your own home before entering the facility. And time spent in the nursing home still counts toward ownership time and use of the residence. For example, if you lived in a house for a year, then spent the next five in a nursing home before selling the home, the full $250,000 exclusion would be available.

Marriage and Divorce and the Ownership and Use Test

Married couples filing jointly may exclude up to $500,000 in gain, provided:

  • either spouse owned the residence
  • both spouses meet the use test, and
  • neither spouse has sold a residence within the last two years.

Separate residences. If each member of a married couple owns and occupies a separate residence and files jointly, each may exclude up to $250,000 in gain when they sell. Also, if it's a new marriage and one spouse sold a residence within two years before the marriage (thereby self-disqualifying from the exclusion), the other spouse could still exclude up to $250,000 in gain on a residence owned before the marriage.

Double tax breaks? A new marriage can also double the tax break in some circ*mstances. Suppose a single man sold his principal residence on October 1 and gained $500,000 in profits. Let's also say that he and his girlfriend had been living in the house for two years (but her name wasn't on the title), so they both satisfy the use test. If they get married by midnight December 31 of the same year, they can file a joint return for that year and exclude the entire $500,000.

Divorce and the tax break. Divorced taxpayers may tack on the ownership and use of their residence by their former spouse. For example, say that upon divorce, the wife is allowed to live in the husband's residence until she sells it. He has owned the residence for 18 months. Once the sale occurs, the couple will split the profits 50-50.

If the wife sells the home nine months later, she may tack on her ex-husband's ownership to meet the two-year ownership test. Also, the husband may tack on his ex-wife's continued use of the residence to meet the two-year use test. Each one is entitled to exclude $250,000 of profits from the sale. Widowed taxpayers may also tack on the ownership and use by their deceased spouse.

Partial Exclusion for Second Home That's Also Used as Primary Home

If you sell a home that you sometimes used as a vacation or rental property and sometimes as your primary residence, you're eligible for only that portion of the capital gains exclusion that corresponds to the amount of time you actually lived there as your primary residence. (The rest of the time is called "non-qualifying use.")

Note that the calculation is made over more than a mere five-year period: It applies right back to January of 2009 (when the relevant legislation was passed). What's more, if during the five years before the sale you never actually made the home your primary residence, you're likely disqualified from using the exclusion. (You won't be surprised to hear that this rule was meant to generate additional tax revenue to offset some other tax cuts.)

Home Offices and Depreciation: A Tax Drawback

The capital gains tax exclusion does not apply to depreciation allowable on residences after May 6, 1997. If you are in a high tax bracket and plan to live in your home for a long time, taking depreciation deductions for a home office is quite valuable right now. But if not, you might want to reconsider using a portion of your home as an office, because all depreciation deductions you take will be taxed at 25% when you sell the house.

Example: A married couple sells a home with an adjusted basis (purchase price plus capital improvements) of $100,000 for $600,000. Over the years, they had taken $50,000 in depreciation deductions for a home office.

Sales Price: $600,000
Adjusted Basis - $100,000
Taxable gain = $500,000

Of that gain, $450,000 is tax-free; the $50,000 taken as depreciation deductions is subject to 25% capital gains tax.

Can You Split Up Big Gains With a Co-Owner to Bring You Under the Exclusion?

If you expect huge gains from selling a house—more than can be excluded from tax—you should consider ways to divide ownership of the house.

For example, say a couple owns their residence together with their adult son (perhaps because they've given him a share). If he meets the ownership and use tests as to one-third of the property, the son may sell his share for a $250,000 gain without incurring a tax. His parents could simultaneously sell their share for $500,000 without tax, sheltering the entire $750,000 gain.

How Much Capital Gains Tax Will You Owe on Taxable Gain?

If part or all of your gain on the sale of your residence is taxable, you'll pay tax on the gain at capital gain tax rates. These rates are lower than personal income tax rates, provided that you owned the home for more than one year. If you owned the home for less than one year, you'll need to pay tax on your gain at your personal ordinary income tax rate.

There are three long-term capital gain tax rates: 0%, 15%, and 20%. The rate at which you'll pay depends on your tax filing status and your total taxable income. The capital gain tax rate is 15% for most taxpayers. But if your income is low enough, your capital gain tax rate is zero.

The rule is that if your total taxable income, including your taxable capital gain, puts you in the 10% or 12% personal ordinary income tax brackets, you pay zero capital gain tax. If your total taxable income places you in the 22%, 24%, 32%, or 35% personal income tax brackets, you pay a 15% capital gain tax. If your income places you in the top 37% bracket, you pay a 20% tax on your long-term capital gains.

The personal income tax brackets are adjusted each year for inflation. The following chart shows the applicable capital gain tax rate based on 2022 taxable income.

Long-Term Capital Gains Rate

2022 Income if Single

2022 Income if Married Filing Jointly

2022 Income if Head of Household

0%

$0 to $41,675

$0 to $83,350

$0 to $55,800

15%

$41,676 to $459,750

$83,351 to $517,200

$55,801 to $488,500

20%

All over $459,750

All over $517,200

All over $488,500

Example 1: John and Jill are married and earned $25,000 in taxable gain on the sale of their home, which they owned for five years. They had $50,000 in other income. Thus their total income for 2022 is $75,000. At this income level, they pay capital gains tax at the 0% rate. In other words, they need pay no tax on their gain.

Example 2: Barton, a single man, sold his home, which he owned for seven years, for a $100,000 taxable gain. He had $100,000 in other taxable income for the year. His total taxable income is $200,000. At this income level, he pays a 15% capital gain tax on his $100,000 gain, for a $15,000 tax.

Example 3: Lexi and Elmore, a married couple, sold their home for a $300,000 gain. They owned the home for 20 years. They had $250,000 in other income for the year. Their total taxable income was $550,000. At this income level, they pay a 20% capital gain tax on their $300,000 gain, for a $60,000 tax.

See a CPA, accountant, or tax attorney if you have questions or concerns about your capital gains tax obligations.

Avoiding Capital Gains Tax When Selling Your Home: Read the Fine Print (2024)

FAQs

What is a simple trick for avoiding capital gains tax? ›

Hold onto taxable assets for the long term.

The easiest way to lower capital gains taxes is to simply hold taxable assets for one year or longer to benefit from the long-term capital gains tax rate.

Is there a way to avoid capital gains tax on the selling of a house? ›

You will avoid capital gains tax if your profit on the sale is less than $250,000 (for single filers) or $500,000 (if you're married and filing jointly), provided it has been your primary residence for at least two of the past five years.

Are there any loopholes for capital gains tax? ›

A few options to legally avoid paying capital gains tax on investment property include buying your property with a retirement account, converting the property from an investment property to a primary residence, utilizing tax harvesting, and using Section 1031 of the IRS code for deferring taxes.

How do I bypass capital gains? ›

The like-kind (aka "1031") exchange is a popular way to bypass capital gains taxes on investment property sales. With this transaction, you sell an investment property and buy another one of similar value.

Do you have to pay capital gains after age 70? ›

This means right now, the law doesn't allow for any exemptions based on your age. Whether you're 65 or 95, seniors must pay capital gains tax where it's due.

Do I have to buy another house to avoid capital gains? ›

How Long Do I Have to Buy Another House to Avoid Capital Gains? You might be able to defer capital gains by buying another home. As long as you sell your first investment property and apply your profits to the purchase of a new investment property within 180 days, you can defer taxes.

At what age do you not pay capital gains? ›

Capital Gains Tax for People Over 65. For individuals over 65, capital gains tax applies at 0% for long-term gains on assets held over a year and 15% for short-term gains under a year. Despite age, the IRS determines tax based on asset sale profits, with no special breaks for those 65 and older.

How long do I have to buy another house to avoid capital gains? ›

Thankfully, you can defer capital gains tax should you purchase another rental property within 180 days of the original investment property sale. There are also a variety of other options to lower your tax liabilities or avoid paying capital gains tax on your rental properties altogether.

Can you deduct closing costs from capital gains? ›

In addition to the home's original purchase price, you can deduct some closing costs, sales costs and the property's tax basis from your taxable capital gains. Closing costs can include mortgage-related expenses. For example, if you had prepaid interest when you bought the house) and tax-related expenses.

Do you pay capital gains after age 65? ›

Current tax law does not allow you to take a capital gains tax break based on age. In the past, the IRS granted people over the age of 55 a tax exemption for home sales. However, this exclusion was eliminated in 1997 in favor of the expanded exemption for all homeowners.

Is there a once-in-a lifetime capital gains exemption? ›

The capital gains exclusion applies to your principal residence, and while you may only have one of those at a time, you may have more than one during your lifetime. There is no longer a one-time exemption—that was the old rule, but it changed in 1997.

What excludes you from paying capital gains tax? ›

This means that if you sell your home for a gain of less than $250,000 (or $500,000 if married, filing jointly), you will not be obligated to pay capital gains tax on that amount. However, there are certain criteria you must meet to qualify for the home sale exclusion.

What is the 121 home sale exclusion? ›

The Section 121 Exclusion is an IRS rule that allows you to exclude from taxable income a gain of up to $250,000 from the sale of your principal residence. A couple filing a joint return gets to exclude up to $500,000.

How can I avoid capital gains tax without a 1031 exchange? ›

Utilizing a Deferred Sales Trust, investors can defer capital gains taxes over time. Deferred Sales Trusts provide an alternative to 1031 exchanges for deferring capital gains taxes on appreciated assets.

What lowers capital gains tax? ›

Long-term investing offers a significant advantage in minimizing capital gains taxes due to the favorable tax treatment for investments for longer durations. When investors hold assets for more than a year before selling, they qualify for long-term capital gains tax rates, typically lower than short-term rates.

What is the 2 out of 5 year rule? ›

When selling a primary residence property, capital gains from the sale can be deducted from the seller's owed taxes if the seller has lived in the property themselves for at least 2 of the previous 5 years leading up to the sale. That is the 2-out-of-5-years rule, in short.

Top Articles
Latest Posts
Article information

Author: Ms. Lucile Johns

Last Updated:

Views: 6068

Rating: 4 / 5 (41 voted)

Reviews: 80% of readers found this page helpful

Author information

Name: Ms. Lucile Johns

Birthday: 1999-11-16

Address: Suite 237 56046 Walsh Coves, West Enid, VT 46557

Phone: +59115435987187

Job: Education Supervisor

Hobby: Genealogy, Stone skipping, Skydiving, Nordic skating, Couponing, Coloring, Gardening

Introduction: My name is Ms. Lucile Johns, I am a successful, friendly, friendly, homely, adventurous, handsome, delightful person who loves writing and wants to share my knowledge and understanding with you.