The state Supreme Court cleared the way Wednesday for San Francisco to seek disciplinary action against a group of police officers who exchanged racist, sexist and homophobic text messages in 2011 and 2012 — calling African Americans “monkeys” and encouraging the killing of “half-breeds,” among other slurs.

The texts, which surfaced publicly in 2015, prompted the district attorney’s office to re-examine thousands of criminal cases the officers have handled. As many as nine officers, who have been on paid leave since December 2015, could be fired if the Police Commission finds serious misconduct.

Federal agents discovered the messages in 2012 during a corruption investigation of veteran plainclothes Sgt. Ian Furminger, who had exchanged thousands of texts with his fellow officers. A jury convicted Furminger in December 2014 on federal charges of taking thousands of dollars in cash that police had found while searching drug dealers and their homes.

He and Officer Edmond Robles, convicted of similar charges, were each sentenced to more than three years in prison, and a third officer, Reynaldo Vargas, who pleaded guilty and testified for the prosecution, got a one-year sentence. Robles and Vargas were implicated in the texting case.

The texts disparaged racial minorities, women and gays. One proclaimed “White power,” and Furminger, according to a court filing, wrote that “cross-burning lowers blood pressure!”

The Police Department learned abut the messages from federal prosecutors in December 2012 but did not disclose them publicly until March 2015, leading then-Police Chief Greg Suhr to announce that he would fire nine of the officers and take disciplinary action against others.

Superior Court Judge Ernest Goldsmith halted the proceedings in December 2015 and ruled that Suhr and his staff should have begun those proceedings by December 2013. Goldsmith said a state law, the Peace Officers’ Bill of Rights, set a firm one-year deadline for taking disciplinary action against officers after police officials learn of their alleged misconduct.

But the First District Court of Appeal reinstated the disciplinary proceedings in May and said the one-year deadline had been suspended, in this case because of the federal criminal investigation, which ended only with the December 2014 jury verdict.

The court said federal prosecutors had directed the Police Department to keep its records confidential during the investigation. The head of the police Internal Affairs Division, Lt. Jerome DeFelippo, testified that a federal prosecutor had threatened him with criminal charges if he released the records while the case against Furminger and his colleagues was pending, the court said.

Allowing the disciplinary proceedings strikes a proper balance between officers’ right to fair treatment and the public’s need to maintain trust in the Police Department, Justice Martin Jenkins said in the 3-0 ruling. He said the messages “displayed unacceptable prejudice against members of the communities SFPD is sworn to protect.”

Lawyers for the officers asked the state Supreme Court to take up the case, arguing that their rights were violated by the department’s failure to file disciplinary charges before the one-year deadline. The court unanimously denied review Wednesday and left the appellate ruling in place as a standard for trial courts throughout the state.

City Attorney Dennis Herrera, whose office argued for the disciplinary proceedings, said the court recognized that the Police Department “can and should investigate and prosecute corrupt officers before moving on to police misconduct revealed during the investigation. Officers accused of misconduct don’t get a free pass just because their texts came to light during a corruption investigation.”

Michael Rains, a lawyer for the officers, said the court was “allowing police agencies to play games with the one-year statute of limitations... It’s bad for society and it’s bad for officers who are under investigation that long.”

The case is Daugherty vs. San Francisco, S249886.

Bob Egelko is a San Francisco Chronicle staff writer. Email: begelko@sfchronicle.com Twitter:@BobEgelko