From: Rabbi Moshe Sofer
To: Rabbi Wolf Chayes
A community built a synagogue on rented land whose fixed rent in commodities became exorbitantly expensive, and they sought to close the synagogue, remove furnishings, and potentially demolish it. The Chasam Sofer permits all steps, ruling that ceasing services is not 'demolition,' removing intact furnishings is permitted, the nobleman's destruction involves no prohibited agency, and the community may demolish for rebuilding given financial hardship.
Source: Shu"t Chasam Sofer OC §32