Lukasz Gottwald, the music producer better known as Dr. Luke, scored a comprehensive legal victory on Thursday in his six-year legal battle with the singer Kesha.

Gottwald sued the singer in 2014, accusing her of defaming him by fabricating a rape allegation in a bid to get out of her recording contract. Kesha has alleged that Gottwald drugged her and raped her, and also claimed in a text message to Lady Gaga that Gottwald had raped Katy Perry.

In a ruling on Thursday, New York Supreme Court Judge Jennifer G. Schecter ruled that Kesha had defamed Gottwald in the text message to Lady Gaga, noting that Perry has denied the claim and there is no evidence to support it.

She also rejected a long series of defenses Kesha had offered, including her claim that Gottwald is a “public figure.” Schecter ruled that Gottwald is not a household name, and had not been the subject of a public discourse on sexual assault before Kesha made her allegation.

“Though Gottwald has sought publicity for his label, his music, and his artists — none of which are the subject of the defamation here — he never injected himself into the public debate about sexual assault or abuse of artists in the entertainment industry,” the judge wrote. “The only reason Gottwald has any public connection to the issues raised in this lawsuit is because they were raised in this lawsuit.”

The ruling means that Gottwald’s attorneys will not have to prove Kesha acted with “actual malice” when she made her claim — setting a much lower bar for the trial.

Schecter also ordered Kesha to pay $374,000 in interest on royalty payments that she had delayed turning over to Gottwald’s company, in breach of her contract.

The judge made it clear she was not ruling on the factual question of whether Gottwald raped Kesha, saying that would have to be left to a jury.

Kesha’s legal team said she would appeal.

“Judge Schecter issued rulings today on motions for summary judgment in the Dr. Luke litigation,” Kesha’s lawyers said in a statement. “We disagree with the Court’s rulings. We plan to immediately appeal.”

Christine Lepera, Gottwald’s attorney, issued a statement lauding the ruling.

“Today’s important decision by the Court in Dr. Luke’s lawsuit brings him closer to the justice that he seeks. First, the Court has now ruled that she made a false and defamatory accusation about Dr. Luke when she baselessly claimed that he raped Katy Perry. Second, the Court rejected Kesha’s attempts to invoke legal technicalities to avoid responsibility for her statements. And third, the Court also correctly held that Kesha breached her contract with Dr. Luke’s company. Dr. Luke looks forward to the trial of his case where he will prove that Kesha’s other false statements about him were equally false and defamatory.”

Read the judge’s ruling: