Anonymization orders and publication bans are exceptional orders and that several competing interests must be balanced by the judge hearing such an application.
These competing interests were considered at length in the leading case of Sherman Estate v. Donovan, 2021 SCC 25. Sherman Estate
In the Supreme Court of Canada decision of Sherman Estate, the court considered whether a sealing order should be granted with respect to a probate file on grounds of privacy.
The Reasons for judgement stated:
[1) This Court has been resolute in recognizing that the open court principle is protected by the constitutionally entrenched right of freedom of expression and, as such, it represents a central feature of a liberal democracy. As a general rule, the public can attend hearings and consult court files and the press — the eyes and ears of the public — is left free to inquire and comment on the workings of the courts, all of which helps make the justice system fair and accountable.
 Accordingly, there is a strong presumption in favour of open courts. It is understood that this allows for public scrutiny which can be the source of inconvenience and even embarrassment to those who feel that their engagement in the justice system brings intrusion into their private lives. But this discomfort is not, as a general matter, enough to overturn the strong presumption that the public can attend hearings and that court files can be consulted and reported upon by the free press.
 Notwithstanding this presumption, exceptional circumstances do arise where competing interests justify a restriction on the open court principle. …
 With respect to limitations on court openness, as stated at para. 38:
 The test for discretionary limits on presumptive court openness has been expressed as a two step inquiry involving the necessity and proportionality of the proposed order (Sierra Club, at para. 53). Upon examination, however, this test rests upon three core prerequisites that a person seeking such a limit must show. Recasting the test around these three prerequisites, without altering its essence, helps to clarify the burden on an applicant seeking an exception to the open court principle.
In order to succeed, the person asking a court to exercise discretion in a way that limits the open court presumption must establish that:
(1) court openness poses a serious risk to an important public interest;
(2) the order sought is necessary to prevent this serious risk to the identified interest because reasonably alternative measures will not prevent this risk; and,
(3) as a matter of proportionality, the benefits of the order outweigh its negative effects.
Only where all three of these prerequisites have been met can a discretionary limit on openness — for example, a sealing order, a publication ban, an order excluding the public from a hearing, or a redaction order — properly be ordered. This test applies to all discretionary limits on court openness, subject only to valid legislative enactments …
 As the court noted at para. 31, privacy can in some circumstances ground an exception to the openness principle. However, some degree of privacy loss resulting in inconvenience and even upset or embarrassment is inherent in any court proceeding open to the public. The question of when a privacy interest is sufficient to give rise to an exception to court openness is discussed at para. 33:
 Personal information disseminated in open court can be more than a source of discomfort and may result in an affront to a person’s dignity. … Dignity in this sense is a related but narrower concern than privacy generally; it transcends the interests of the individual and, like other important public interests, is a matter that concerns the society at large. A court can make an exception to the open court principle, notwithstanding the strong presumption in its favour, if the interest in protecting core aspects of individuals’ personal lives that bear on their dignity is at serious risk by reason of the dissemination of sufficiently sensitive information. The question is not whether the information is “personal” to the individual concerned, but whether, because of its highly sensitive character, its dissemination would occasion an affront to their dignity that society as a whole has a stake in protecting.
 Specifically, in order to preserve the integrity of the open court principle, an important public interest concerned with the protection of dignity should be understood to be seriously at risk only in limited cases. Nothing here displaces the principle that covertness in court proceedings must be exceptional. Neither the sensibilities of individuals nor the fact that openness is disadvantageous, embarrassing or distressing to certain individuals will generally on their own warrant interference with court openness … These principles do not preclude recognizing the public character of a privacy interest as important when it is related to the protection of dignity. They merely require that a serious risk be shown to exist in respect of this interest in order to justify, exceptionally, a limit on openness, as is the case with any important public interest under Sierra Club. As Professors Sylvette Guillemard and Séverine Menétrey explain, [translation] “[t]he confidentiality of the proceedings may be justified, in particular, in order to protect the parties’ privacy . . . . However, the jurisprudence indicates that embarrassment or shame is not a sufficient reason to order that proceedings be held in camera or to impose a publication ban” (Comprendre la procédure civile québécoise (2nd ed. 2017), at p. 57).
 At paras. 73-76, Justice Kasirer concluded that:
 I am accordingly of the view that protecting individuals from the threat to their dignity that arises when information revealing core aspects of their private lives is disseminated through open court proceedings is an important public interest for the purposes of the test.
 Focusing on the underlying value of privacy in protecting individual dignity from the exposure of private information in open court overcomes the criticisms that privacy will always be at risk in open court proceedings and is theoretically complex. Openness brings intrusions on personal privacy in virtually all cases, but dignity as a public interest in protecting an individual’s core sensibility is more rarely in play. Specifically, and consistent with the cautious approach to the recognition of important public interests, this privacy interest, while determined in reference to the broader factual setting, will be at serious risk only where the sensitivity of the information strikes at the subject’s more intimate self.
 If the interest is ultimately about safeguarding a person’s dignity, that interest will be undermined when the information reveals something sensitive about them as an individual, as opposed to generic information that reveals little if anything about who they are as a person. Therefore the information that will be revealed by court openness must consist of intimate or personal details about an individual …
 The test for discretionary limits on court openness imposes on the applicant the burden to show that the important public interest is at serious risk. Recognizing that privacy, understood in reference to dignity, is only at serious risk where the information in the court file is sufficiently sensitive erects a threshold consistent with the presumption of openness. This threshold is fact specific. …
 The question of whether a serious risk to a privacy interest, sufficiently sensitive to strike at an individual’s biographical core, is made out is a case specific matter to be determined in the full factual context of the case: Sherman Estate at para. 79.