With dozens of colleges, Boston is a hub for young people living apart from their families. The greater region is also home to hundreds of thousands of empty nesters, many with multiple spare rooms.

The program is run jointly by the Boston Elderly Commission and nesterly, which describes itself as a home-sharing start-up. “On any given night,” nesterly says on its website, “more than 50 million bedrooms sit empty across the U.S. Many of these spare rooms belong to older homeowners whose large houses have become a burden as they age.”

Mayor Martin J. Walsh has endorsed the initiative as part of a broader plan to overcome a housing shortage.

“By matching established adults with extra space with students who are eager to engage with their communities, we’re creating a housing pilot that provides more affordable options for everyone,” Walsh said in a statement.

Nesterly cofounder Noelle Marcus told the Boston Herald that rents will run about $600 a month and could be lower if renters agree to do chores for the older homeowners. Leases will run from several months to a year.