The High Court on Friday issued an injunction banning the publication of personal information on members of the judiciary and their relatives, as well as any threats or harassment.
The move comes amid a string of complaints against magistrates deemed to be biased in favour of anti-government protesters.
Pro-Beijing figures and media have targeted magistrates they accuse of handing down lenient sentences to people involved in protests, while offensive graffiti recently appeared denouncing a magistrate who ruled that police officers had lied when giving testimony in court.
The injunction, sought by the Department of Justice, will be in force until November 13.
Barrister and pro-Beijing lawmaker Priscilla Leung said she welcomed the move because many public figures had suffered from doxxing, herself included. She said it poses a threat to people's personal safety.
"I do think that law enforcement agencies, as well as judicial officers, should be protected," she said. "They should be left with enough room to exercise their duty without undue pressure."
Legal sector lawmaker Dennis Kwok urged the authorities to clearly explain the scope of the injunction, adding that he was worried the wording might be too vague and people could be punished for simply expressing their views on court rulings.
"I would hope that... clear guidelines could be given, so that members of the public would not breach the injunction inadvertently, by way of criticising certain judgements."
But the lawmaker also said that he hoped everyone would respect the injunction, whether they agree with it or not.
"The people of Hong Kong have, of course, the right to criticise judgements. But I would emphasise that the criticism must be based on facts and must be as objective as possible, and should not involve personal attacks on members of the judiciary," Kwok said.
An injunction against doxxing police was issued last year after the force complained that officers and their families were being intimidated and harassed by people who supported the anti-government protest movement.
New injunction bans doxxing, harassment of judges
2020-10-30 HKT 17:14
2020-11-17 HKT 17:35
2020-11-17 HKT 16:17
2020-11-17 HKT 13:40
2020-11-16 HKT 17:03
2020-11-16 HKT 15:01
2020-11-16 HKT 08:58
2020-11-13 HKT 17:54
2020-11-13 HKT 16:35
2020-11-09 HKT 16:42
2020-11-08 HKT 17:16
2020-11-06 HKT 18:28
2020-11-06 HKT 16:57
2020-11-06 HKT 16:56
2020-11-06 HKT 11:47
2020-11-05 HKT 16:22
2020-11-04 HKT 17:31