A code point is a numerical position in a coded character space. Unicode defines code points from
U+0000 through U+10FFFF; some are assigned to characters, while others have reserved, private-use, surrogate or noncharacter roles. A Unicode scalar value excludes surrogate code points.[ref]The Unicode Standard Version 17 Core Specification. Chapter3, definitionsD9–D12 andD76
A code point is distinct from an encoded byte and from a displayed grapheme cluster. For example,
U+00E9 encodes as two bytes in UTF-8. The visible accented letter can also be represented by U+0065 U+0301, two code points that may form one grapheme cluster. A code unit is a unit of an encoding form, such as one byte in UTF-8. Counting these units answers different questions from counting user-perceived characters. New to topics? Read the docs here!