= Unicode normalization
{c}
<Unicode normalization> maps text to a specified standard representation while respecting a chosen equivalence relation between <Unicode> sequences. Canonical normalization uses <canonical equivalence>; compatibility normalization additionally uses <compatibility equivalence>. NFD decomposes canonical combinations, NFC then composes where permitted, and NFKD/NFKC additionally apply compatibility decompositions.<Unicode Normalization Forms by the Unicode Consortium>[§1.1, canonical and compatibility equivalence; §1.2, normalization forms]{ref}
For example, `U+00E9` and `U+0065 U+0301` represent canonically equivalent accented text. NFD produces the second sequence from either input, while NFC produces the first. NFKC also changes the circled digit `U+2460` to the ordinary digit `U+0031`; NFC preserves that compatibility distinction. The choice consequently depends on which distinctions an application intends to retain. <Unicode normalization> is different from choosing a <character encoding> or a <font>, and it does not make every visually similar pair of <strings> equal.
Back to article page