"é" in UTF-8 — binary and text

coretwo bytes for one character

Answer

11000011 10101001

Why this example is worth doing

The first character on the page that is not one byte. UTF-8 encodes é as two bytes, and the leading bits of each say how many bytes the sequence has and which are continuations. The page decodes those prefix bits explicitly, because the self-synchronising structure is the clever part of UTF-8 and it is what makes the encoding recoverable from any starting position. It also shows why ASCII text is unchanged under UTF-8.

Try your own input in the Binary ⇄ text / ASCII. Convert text to binary and back, byte by byte, with the full UTF-8 breakdown.

How the answer is reached

UTF-8 encoding of 1 character

UTF-8 (RFC 3629): the leading byte says how many bytes follow, and every continuation byte starts 10.

UTF-8 encoding of 1 character — columns character, code point, decimal, hex, binary, template
charactercode pointdecimalhexbinarytemplate
éU+00E9233C3 A911000011 10101001110xxxxx 10xxxxxx
Three different numbers; the UI must show all three — UTF-8 encoding of 1 character
countvalue
bytes2
code points1
UTF-16 code units1

Source: RFC 3629; WHATWG Encoding Standard

Compare with

Open this example in the Binary ⇄ text / ASCII

The field arrives filled in with this example’s input.

Note:

Notation this page assumes

  • Bit strings are written most significant bit first, and bit 0 is the least significant bit.
  • A width is stated explicitly wherever it changes the answer; nothing is silently sign-extended or truncated.
  • ASCII is the 7-bit set padded to one byte; UTF-8 is shown byte by byte, so a non-ASCII character is more than eight bits.

Sources

  • ANSI X3.4 / ISO-IEC 646, the ASCII character set
  • The Unicode Standard, Annex on the UTF-8 encoding form