Skip to content
ToolDesk

Counting Characters — Bytes vs. Code Points vs. Graphemes

Updated 2026-07-28

"How many characters is this?" sounds simple, but there are several ways to count. With non-English text or emoji, tools and languages can disagree. The reason is three different units of counting: bytes, code points, and graphemes. Let’s look at each.

Bytes: the storage and transfer size

A byte is the unit of size when a computer stores or sends data. When text becomes bytes, UTF-8 is the widely used scheme. In UTF-8, ASCII letters and digits are 1 byte, while many CJK characters are 3 bytes. Database column limits and payload sizes are often measured in bytes, not characters.

Code points: Unicode’s numbers

Unicode assigns every character a unique number (code point). "A" is one code point, but emoji and combined characters can be made of several code points. A program’s string length is often counted in these units, which is one reason it diverges from the visible character count.

Graphemes: what a person sees as one character

A grapheme (grapheme cluster) is what a person perceives as a single character. For example, a family emoji 👨‍👩‍👧 is built from multiple code points but looks like one character, so it counts as one grapheme. Combined accented characters behave the same way. This is the count closest to human intuition.

Why the numbers differ

  • "あ" → 1 grapheme / 1 code point / 3 bytes (UTF-8)
  • Emoji 😀 → 1 grapheme / 1 code point / 2 UTF-16 units (surrogate pair)
  • Family emoji 👨‍👩‍👧 → 1 grapheme, but multiple code points
  • Whether a social limit or form cap counts in which unit depends on the spec

Our character counter shows graphemes, code points, UTF-16 units, and UTF-8 bytes together, so you can find the "right" count for your purpose. Understanding it alongside Base64 (carrying text as bytes) and URL encoding makes the relationship between characters and bytes click.