An Arizona man just sold his 2600-square-foot house to the city of Scottsdale for about $4 million—but he isn’t using the cash to buy a swanky new home, Atlas Obscura reports. Instead, former property owner Shawn Murphy will stay in his current digs rent-free for the remainder of his life. In exchange, Scottsdale will own the land it sits on: a portion of the McDowell Sonoran Preserve, a protected desert habitat.

The McDowell Sonoran Preserve was founded in the early 1900s, and in 1993 Scottsdale decided to set aside 3000 additional acres of natural lands for conservation. Over the years, more land was added, and by 2012, the McDowell Sonoran Preserve was the largest urban preserve in the Americas, making up one-quarter of the city's land area. Today, it includes more than 30,000 acres of desert—and thanks to Scottsdale, it continues to grow. With their latest purchase, the preserve now includes even more contiguous land, and a house to boot.

For nearly a decade, Fox 10 reports, officials tried to purchase Murphy’s home, which sits near the popular Tom's Thumb trailhead in the preserve. (Murphy bought the house and its surrounding lands in 1999, before they were officially part of the preserve.)

"It's fully surrounded by the preserve and … the north end of the McDowell Mountains," preserve director Kroy Ekblaw told The Arizona Republic. "It's elevated with commanding views of the Verde Valley and the Continental Mountains."

The home’s location was desirable, and city officials also feared that its next owner wouldn’t be as good to the land as its current inhabitants were. "In some point of time, if they were looking to move, we might get a neighbor who doesn't share the same goals," Ekblaw told The Arizona Republic. The sale, he said, “puts to bed the issue of any future change. We're not faced with an unknown."

Earlier this month, both parties finally reached a deal: Since Scottsdale appraised the house at $2.69 million but a separate appraiser hired by Murphy valued it at $6.59 million, they compromised and settled for $4 million. (The purchase was paid through a city sales tax that pays for desert preservation.)

Murphy scored a pretty sweet deal: He lives in the house for free, and he can even rent it out for half the year. However, he has to foot the bill for utilities, maintenance, and insurance. When he dies, the city will likely either use the home as part of the preserve or tear it down, ABC News 12 reports

Scottsdale officials have mixed feelings about the home purchase. They know it was expensive, but "we don't like the idea of condemning someone's home for a park," Mayor Jim Lane told The Arizona Republic. "I think we settled on a reasonable amount."

[h/t Atlas Obscura]

Know of something you think we should cover? Email us at tips@mentalfloss.com.