Portland’s St. Patrick Catholic Church is again under contract to be sold after a previous deal with the owner of an adjacent shopping center fell through.

The sale is likely to result in the demolition of the church on outer Congress Street, said Steve Brinn, president of the executive committee of the Jewish Community Alliance of Southern Maine, which is buying the property.

Brinn said his organization signed a purchase-and-sale agreement for the church last week. The sale isn’t expected to close until mid-2015 and the church building is likely to be razed before the sale is completed. The demolition will allow the alliance to put up a building that better meets the organization’s needs, he said.

The church has been on the market for nearly four years and the last service there was held in May 2013. The diocese became interested in selling the building in 2010, when St. Patrick, St. Pius X and St. Joseph’s churches were combined into one parish, Our Lady of Hope. Because of declining church membership and a parish deficit, the parish decided to close and sell St. Pius X, leaving the other two churches operating.

But when church leaders went to the owners of the Westgate Shopping Center, next to St. Patrick, to seek a lease for additional parking spaces, the shopping center’s owner instead renewed an offer made years before to buy the church. Parish officials then pursued that sale and took St. Pius X off the block.

The parish and Charter Realty, the owner of Westgate Shopping Center, signed a letter of intent on the sale, contingent on Charter Realty getting some permits and approval. The deal fell through and neither the parish nor Charter Realty said why the sale never closed. Charter Realty, the diocese and the parish did not respond to requests for comment Tuesday, beyond a confirmation by the diocese that a purchase-and-sale agreement had been signed with the Jewish Community Alliance.

Dave Guthro, spokesman for the Roman Catholic Diocese of Portland, said by email that he and the diocese’s chief financial officer were out of the office and more information wasn’t immediately available.

Brinn said the Jewish Community Alliance has been looking for a new headquarters for more than 30 years. He said the group moved into 57 Ashmont St. in Portland in the early 1980s, intending to stay for only a year or two.

The right deal for a move never came along until the group checked out St. Patrick Church this year, he said.

“We looked at pretty much every property in Portland,” Brinn said. “That one (St. Patrick) we couldn’t miss because it had a big ‘For Sale’ sign on it.”

He said the alliance needs office space and a large gathering space. It plans to offer the building as a community meeting space and also operates both preschool and after-school programs, which means the alliance needs outdoor play space and more parking, he said.

The organization also operates Jewish Family Services, which runs a food pantry and other charitable activities, and the Jewish Federation, a fundraising and charitable operation, Brinn said, and needs space for those functions.

Brinn said plans for a new building aren’t far enough along to estimate the cost. He also said the group hasn’t decided whether to use the existing foundation after the church is demolished or build a new one.

The church had been listed at $1.59 million. Brinn said his organization paid less than that, but declined to provide a specific figure.

The lot containing the church is 2.25 acres.

Money from the sale of churches goes back to the parishes. However, church officials said, most of the proceeds are typically deposited in an informal, diocese-run “bank,” which invests the money and makes loans to parishes that are running deficits or have to make expensive repairs to church buildings.