Leaving behind a home for a loved one to inherit is a huge gift, but without the right planning, it could be an equally large headache. 

Beneficiaries must juggle many considerations when they inherit a home, especially if they’re sharing that gift with siblings or others. There are tax implications whether they keep or sell the home, emotional attachments to the house and the items within the house, as well as other potential estate planning issues. 

There is no right or wrong answer when choosing to keep or sell an inherited home. In some cases, the property can become a source of rental income, whereas in other situations, it could be another source of cash after it’s sold — especially when the real-estate market is doing well. But before jumping into the choice, here’s what to know: 

The tax implications of selling the home

Individuals who sell a home after living in it for two out of the last five years enjoy the tax benefit of an exemption — for single filers, the exclusion is $250,000, while for those who are married filing jointly, it’s $500,000. This exemption is applied when a home is sold to reduce the capital gains the sellers would have to pay. For example, if a married couple sold a home for $1 million and had a basis of $500,000, they would pay $0 in capital-gains tax for that sale. Comparatively, if they sold it for $1.5 million, they would reduce the tax obligation by $500,000, and pay capital gains tax on the remaining $500,000. 

Surviving spouses who inherit the full value of their home after their husband or wife dies can still take advantage of the $500,000 exemption if they sell the house within two years of death, said Peter Palion, a financial adviser and founder of Master Plan Advisory. 

Read: My wife’s father left her a home and some money in a trust. This subsidizes our lifestyle. What happens to me if she dies?

Nonspouses should think carefully about if and when they plan to sell the home. Their basis of the inherited home becomes the fair market value on the date of death of the grantor, which means they’ll pay very little in taxes if they sold the property in the short-term. Comparatively, they could face a large tax exposure if they were to sell after numerous years, or decades. For example, if the grantor left behind a home after she died in 2010, when the fair market value at that time was $250,000, and the beneficiary held on to the house for another 10 years before selling it for $500,000, he would be responsible for paying the capital gains on the difference (in this case, $250,000). 

Beneficiaries should reach out to a real estate professional who can assist in determining the fair market value of the home, or to get an appraisal on the property. “The first thing they need to do is to establish the value of the property,” said Jennifer Grant, a financial adviser at Perryman Financial Advisory. “This small action can pay for itself many times over in tax savings.” 

Keeping the home for now versus selling soon 

For some, the best strategy for this inheritance may be to hold off on selling, perhaps because they need time to make this decision. In that scenario, the property must still be maintained and secured and the taxes, insurance and mortgage payments must still be paid, said George Reilly, a financial adviser at Safe Harbor Financial Advisers. 

“Generally, there is time to assess the situation and determine if you want to keep the property and either use it or turn it into a rental property, or sell it,” he said. 

If the home still has a mortgage, beneficiaries should reach out to the lender to see if there were any clauses regarding the change in ownership, Reilly said. If the existing rate is favorable, they might be able to keep the loan instead of refinancing, said Rob Greenman, lead adviser and partner of Vista Capital Partners. 

Read: My father’s divorce decree says his kids will inherit his house — but he later put it in a trust for his third wife. Which one wins out?

Working with other beneficiaries 

The inheritance of a home can get trickier when more than one beneficiary is listed, especially when including children and grandchildren. “If there’s no agreement, the only solution may be to sell,” said Patricia Hausknost, a financial adviser. 

There are various options family members can take, including selling the home and splitting the proceeds; renting the home and sharing the income; or finding an arrangement if one sibling wants to keep the house, such as buying out the other owners, or trade other inherited assets for the property. 

Deciding to keep the home or sell might also come down to how worthwhile the property is as an investment. Can the beneficiaries see a better return if they were to use it as rental income or put the sales proceeds in an investment portfolio? Is the home in good shape, or does it require repairs and improvements? 

“Things get more complicated when the next generation (grandchildren) inherit,” Hausknost said. “There are generally more opinions which make it more difficult to reconcile.”