Home/Guides/Character Encodings Explained: UTF-8, UTF-16, ASCII, and Windows-1252
Back to Knowledge Base
Architecture

Character Encodings Explained: UTF-8, UTF-16, ASCII, and Windows-1252

How character sets, Byte Order Marks (BOM), and Unicode code points work, and how to avoid mojibake text corruption.

TxtCraft Team
Editorial Team
•2026-08-22•10 min read

What is Character Encoding?

Computers do not store letters, emojis, or hieroglyphs; they only store binary zeros and ones (0 and 1). A character encoding is a standardized key table that translates integer numbers (known as Code Points) into sequences of bytes.

You can create, test, and save files with custom character encodings using our TXT File Maker, and format text strings with the Text Case Converter.


The Evolution of Character Sets

#

1. ASCII (1963)

- 7 bits per character (Range: 0x00 to 0x7F). - Total 128 characters. - Sufficient only for American English.

#

2. Windows-1252 / ANSI

- 8 bits per character (Range: 0x00 to 0xFF). - Included accented vowels (é, à, ü) and typographical symbols (£, €, ©). - Flaw: Incompatible with Cyrillic, Greek, Arabic, and Asian scripts.

#

3. Unicode & UTF-8 (1993 - Present)

- Universal character repertoire exceeding 1,114,112 code point slots. - UTF-8: Variable length from 1 to 4 bytes. - ASCII characters (A-Z) = 1 byte. - Greek, Arabic, Latin Extended = 2 bytes. - CJK (Chinese, Japanese, Korean) = 3 bytes. - Emojis and historical scripts = 4 bytes. - Over 98% of the modern internet is powered by UTF-8.


Preventing Text Corruption (Mojibake)

When sharing files across global environments or legacy spreadsheet software (like Microsoft Excel), always save with UTF-8 or UTF-8 with BOM using the TXT File Maker. For batch file provisioning, verify our Batch TXT Generator.

Ready to Create Plain Text Files?

Open our online notepad and TXT File Maker to write, format, and download .txt files.

Open TXT File Maker →

More Webmaster & Plain Text Tools

Apply these best practices using our dedicated client-side utilities.

Related Plain Text Templates

Download standardized templates implementing these guidelines.

More Technical Guides & Tutorials

Deepen your understanding of file systems, data encoding, and DevOps automation.

Frequently Asked Questions

Find quick answers to common questions about plain text files, encodings, and online tools.

A BOM is a special sequence of bytes at the very beginning of a text file (such as EF BB BF for UTF-8 or FF FE for UTF-16LE) that signals the character encoding and endianness to the software reading the file.