Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

LOS ANGELES — 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. Schechter 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.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

She also rejected a long series of defenses Kesha had offered, including her claim that Gottwald is a "public figure." Schechter 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.

Schechter also ordered Kesha to pay $374,000 in interest on a 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."