SANFORD, Fla. — Several hours after the city manager publicly announced that he had reached an agreement with Chief Bill R. Lee Jr. to resign over the Sanford Police Department’s handling of the Trayvon Martin shooting case, the City Commission voted late Monday afternoon to reject Chief Lee’s resignation.

Mayor Jeff Triplett was among a 3-to-2 majority of commissioners to vote “no confidence” in Chief Lee last month, prompting him to temporarily step aside. But during a special meeting Monday to consider Chief Lee’s future, Mr. Triplett was clearly torn amid a spirited debate punctuated with applause and standing ovations from backers of the chief in the audience.

In the end, Mr. Triplett voted in favor of Chief Lee’s remaining in the department, once again as part of a 3-to-2 majority. He said he wanted to review the reports of an independent investigation about the Police Department’s handling of the case before making a decision.

“I am not ready to have him come back and run the Police Department,” Mr. Triplett said. “But I am not ready for this, either.”