The District’s main public library got a reprieve from plans to cut its Sunday hours after Mayor Vincent C. Gray (D) announced Friday that the city had found extra funding to keep the building open seven days a week.

Gray’s statement came about 48 hours before the Martin Luther King Jr. Memorial Library — the public library’s central branch — was set to be closed on a non-holiday Sunday for the first time since opening its doors in 1972.

After a report earlier this week on the looming Sunday closure, library supporters urged the city to reverse its decision and restore Sunday hours at the branch, which is at 901 G St. NW.

The mayor announced Friday that the city had allocated $316,000 to the library system, allowing the King library to keep its Sunday hours during the 2012 fiscal year, which begins today.

Recent savings on the city’s debt service made the additional funding possible, Gray said. “We had some savings, and we are reinvesting it in the library,” he said.

D.C. officials had announced earlier this year it would cut $800,000 from the library system’s budget — to less than $35 million — in response to the city’s ongoing budget woes.

When D.C. Public Library spokesman George Williams announced the cuts Sept. 19, he said that ending the King library’s Sunday service was the least-painful option available.

Terry Lynch, director of the Downtown Cluster of Congregations and a member of former mayor Anthony Williams’s library task force, wrote in a letter to Gray and council members that the King library cuts ran against Gray’s “own stated goal for improved educational services to our youth and city.”

On Friday, Gray said he wished there had been more outcry when he originally proposed the budget in the spring — or when the D.C. Council approved it. “It’s almost as if people don’t pay attention because it’s months down the road,” he said.

Library patrons did voice their concerns about the cuts during the library board’s Sept. 21 meeting in Deanwood, according to Ginnie Cooper, the D.C. system’s chief librarian. “They told us that having MLK open on Sundays means there’s a library open when we need it,” she said.

As the system’s neighborhood libraries began shuttering on Sundays, patrons relied more heavily on the King library as a Sunday afternoon haven, where parents could bring their children to read a story and the unemployed could use computers to find new job opportunities, George Williams said.

“We’re still that place,” he said.

D.C. Council member Tommy Wells (D-Ward 6), chairman of the council’s Public Works, Recreation and Libraries Committee, was a force behind Gray’s reversal, meeting with library administrators and supporters and then lobbying the mayor.

“I told them we needed to make this one of our top priorities,” he said. “Mayor Gray agreed and said he would see what he could do.”

Lynch said that although he is pleased the King library will remain open Sundays, he wants the city to start restoring Sunday hours at the neighborhood libraries, too.

Staff writers Tim Craig and Nikita Stewart contributed to this report.