City Hall has struck a deal with the police and teachers’ unions, whose leaders called the agreement the best they could hope for in a recession.

The agreements with the police union and the teachers’ union conclude months of negotiations, during which both unions needed to prioritize the benefits they wanted to preserve, said Louis Cavaliere, president of the New Haven Police Union, and David Cicarella, president of the New Haven teacher’s union, in separate interviews. The police officers avoided layoffs, but no details of the teachers’ contract have been released.

“This had to be the worst time for any union to be in contract negotiation given the state of the economy,” Cavaliere said. “I think we did a very good job accomplishing what our members wanted to obtain. We preserved hiring and did not have to layoff anyone.”

The police union reached its agreement with the city on Sept. 30, voting 276 to 45 in favor of the proposed three-year contract, which will begin retroactively in July 2008 — when the previous contract expired — and last until June 2011. The vote ended more than a year and a half of negotiations between the city and the police union, which started in January 2008. The contract will remain pending until the Board of Alderman votes to approve it, a vote that is scheduled to take place on Oct. 19.

Cavaliere explained that the union’s major concerns going into the negotiations with the city were preserving their work schedules and pension benefits. The new contract, he said, contains fewer benefits for the officers than its predecessor, which was to be expected given the state of the economy. New Haven’s police officers will receive no wage increases in the contract’s first year but will receive 3 percent increases per year for the next two years. The officers will also be required to complete 20 years of service before they are eligible for retiree medical benefits, and the maximum retirement age was increased from 65 to 67 years.

The contract also contains a “Bad Boy Clause,” which states that any officer convicted of corruption charges can lose not only his or her job but also pension.

City Hall spokeswoman Jessica Mayorga said that though the police union negotiations went on for some time, city officials are pleased to have a contract that recognizes the importance of the services the officers provide to city residents as well as the needs of the officers.

Less set in stone than the police union contract, which needs only to be voted upon by the Board of Aldermen to go into effect, the tentative agreement reached Monday between the New Haven chapter of the American Federation of Teachers and City Hall is a required step on the way to a formal contract.

Moreover, it is a necessary component of Mayor John DeStefano Jr.’s push to reform New Haven’s public schools, the mayor said in a statement.

The details of the agreement will not be available until it is put to a vote of the teachers’ union on Oct. 13. However Cicarella said that during negotiations between city officials and the union there were a slew of contentious issues on the table, Cicarella said. Foremost among them was the reform of New Haven’s Public School system, he said.

“Reform is lengthening the school day, [initiating] different programs and a longer school year,” Cicarella said. “Those types of things come along with the contract.”

He said the union wants everyone within the school system to be accountable for students’ performance on standardized tests.

“The principal, the mayor, and the superintendent as well as the teachers all have to be accountable,” he said. “City Hall was not opposed to that. If things don’t go well [with students’ test scores] who do you then hold accountable?”

Mayorga said that a partnership between the New Haven Federation of Teachers and City Hall, as demonstrated in the tentative agreement announced Monday, will bring New Haven’s students and schools to the next level.

Cicarella said he believed the union would ratify the contract. A spokesperson for the International American Federation of Teachers declined to comment on the matter as the contract is yet to be ratified.