ARTASCIIcreate with characters
Practical guide · reproducible examples

ASCII, Unicode and UTF-8: what is the difference?

ASCII is a repertoire of 128 codes. Unicode covers a much wider range of characters. UTF-8 encodes Unicode code points as bytes. None of these terms names a font or guarantees a drawing’s width.

Choose for your drawing

NeedChoiceCheck
TXT, terminalASCIIEspaces / spacing
♥, ─, █Unicode + UTF-8Police / font
Visuel fixe / fixed imagePNGTexte alternatif / alt text

For a logo made of /, _, | and letters, ASCII is enough. For continuous frames using ─ and │, use Unicode and check the reader’s font. Choose according to the characters you need, not a format’s supposed prestige.

Characters and bytes: four concrete cases

TextUnicodeUTF-8 hexBytes
AU+0041411
éU+00E9C3 A92
éU+0065 + U+030165 CC 813
♥U+2665E2 99 A53

First case: A keeps the same numeric code in ASCII and Unicode and uses one UTF-8 byte. Second case: é can be represented by U+00E9 or by e followed by combining accent U+0301. Those two table rows may look identical while containing different code point sequences. You can reproduce the bytes using text.encode("utf-8") in Python.

for text in ["A", "é", "é", "♥"]:
    print(repr(text), text.encode("utf-8").hex(" "))

Why the counter and screen disagree

The ArtASCII diagnostic counts code points, not terminal cells. A combining accent can attach to the preceding character; some characters occupy different widths depending on the font and application. East Asian Width provides a classification, not a universal layout engine on its own. Do not therefore size a Unicode frame solely by string length.

Avoid common mix-ups

A .txt file can contain Unicode: its extension does not define its encoding. A monospace font does not convert ♥ into ASCII. Saving ASCII text as UTF-8 preserves those characters. Removing accents, however, changes the text; do it deliberately and keep the original. For a FIGlet banner, font coverage is a separate issue from file encoding.

Sources and next steps

Unicode FAQ · UTF-8 — RFC 3629

ASCII table · Alignment diagnosis

Explore further