WELLSWOOD — It was an unexpected bit of good fortune for the city when a church and its Sunday school building went up for sale.

The church — Iglesia M.U. Vino Nuevo — is at 5120 Mendenhall Drive, adjacent to Wellswood Park and the park’s ball fields. On Thursday, the Tampa City Council voted to buy the property for $400,000 plus $4,000 in closing costs. The seller is the Plant City based district of the United Methodist Church.

City officials plan to convert the buildings into a community center and into offices for parks and recreation staff members; they hope to open the retooled facilities next year. Staffers now work from two trailers at the park.

“It’s truly something that came from heaven,” said Greg Bayor, the city’s parks and recreation director.

The city expects it will cost an additional $600,000 to pay for repairs which include a new roof, asbestos removal and possibly new air-conditioners. But the total expense, Bayor said, will be considerably less than the $2 million to $3 million it would cost to build a new community center.

The church buildings have more than 15,000 square feet including 11 classrooms, a sanctuary with seating for more than 200 people, and a fellowship hall with seating for about 100 people, according to a real estate listing.

“It looks like it would make a great performance area,” Bayor said of the sanctuary.

The buildings also would allow the city to expand its summer camp program, he said.

The church has been vacant for a while. An undated sign on the front door, written in Spanish, states the church is closed for repairs.