Skip to main content
ToolNimbly

Character Counter

Three different character counts, because software and people do not agree on what a character is.

Runs in your browser. Nothing you enter here is uploaded to a server.

Loading the tool…

Embed the Character Counter

Paste this into any page. The tool runs in place, and the credit line below it links back here.

Appearance

Adjust height if your layout needs it.

Please keep the “Powered by” line. It is the only thing we ask in return, and it is what keeps the tool free to embed.

What this tool does

Ask how many characters are in a piece of text and there are at least three defensible answers. This counter gives all of them: the number people perceive, the UTF-16 length that most programming languages report, and the UTF-8 byte size that matters for databases and network payloads. Set a limit and it tracks how much room is left. A family emoji counts as one visible character here, and as eleven UTF-16 units — which is exactly the gap that catches people out.

How to use this tool

  1. Step 1: Paste or type your text

    Counts update live. Nothing needs submitting.

  2. Step 2: Set a character limit if you have one

    Enter the limit your platform enforces and the counter shows characters remaining, switching to an over-limit count once you pass it.

  3. Step 3: Read the count that applies to you

    Use the visible count for human-facing limits, the technical length when a developer tool reports a different number, and the byte size for storage or payload constraints.

Worked example

Why one emoji can be eleven characters

The family emoji 👨‍👩‍👧‍👦 is a single picture built from four people joined by invisible connectors.

Visible characters (graphemes)
1
Technical length (UTF-16 units)
11
UTF-8 bytes
25

A field that allows "100 characters" might mean any of these three. If a form rejects text that looks well within its limit, an emoji or an accented character is usually the reason.

The three ways to count

Each count answers a different question, and none of them is wrong — they are measuring different things.

graphemes  what a reader sees as one character (Intl.Segmenter)
UTF-16     what JavaScript string.length reports
UTF-8      bytes on disk or on the wire (TextEncoder)
  • Most Latin text gives identical numbers for all three, which is why the difference goes unnoticed until an emoji or an accented character appears.
  • A character with a combining accent, such as e followed by a combining acute, is one grapheme but two UTF-16 units.
  • Where Intl.Segmenter is unavailable, the tool falls back to counting Unicode code points and says so, since that splits emoji sequences apart.

Sources and methodology

ToolNimbly performs this work locally in your browser using the method shown above. Read how ToolNimbly tests calculations and generated documents.

A character has more than one technical meaning

What a reader sees as one character can contain several Unicode code points. An accented letter may be stored as one precomposed code point or as a base letter followed by a combining mark, and many emoji are sequences joined together. JavaScript string length counts UTF-16 code units, while a database or API may limit code points, grapheme clusters or encoded bytes. Those totals can legitimately differ.

Use the visible-character count for human-facing limits such as captions. Use UTF-8 bytes when an API, file format or database column specifies a byte limit. Normalising text can make canonically equivalent accents use the same representation, but it should not be done silently because identifiers and signatures may depend on the original bytes. Always match the counter to the definition in the system enforcing the limit.

Limitations and privacy

What this tool does not do

  • Platforms differ in what they count. Some social networks weight certain characters differently or exclude links from the total, so their counter may not match any of these three.
  • Grapheme counting depends on the browser Unicode data. A very new emoji may segment differently on an older browser.
  • Line counting treats a line break as a separator; whether a trailing newline creates an extra empty line is a convention, and this tool does not count it as one.
  • Very large inputs are debounced to keep typing smooth, so counts may briefly lag behind.

Your text never leaves this page. It is held in memory, never uploaded, and cleared on reset or when the tab closes.

Frequently asked questions

Which count should I use for a social media limit?

Start with the visible character count, since most platforms describe limits in terms people can see. If the platform still rejects your text, its counter is probably using UTF-16 length or applying its own weighting — compare against the technical length shown here.

Why does an emoji count as several characters?

Because many emoji are sequences: skin-tone variants, flags and family emoji are built from several code points joined by invisible connectors. They render as one picture but occupy several UTF-16 units and many UTF-8 bytes.

What is the difference between characters and bytes?

Bytes are how the text is stored. In UTF-8, plain English characters take one byte each, most accented and Greek or Cyrillic characters take two, most CJK characters take three, and emoji take four or more. A 255-byte database column therefore holds far fewer than 255 characters of non-Latin text.

Do spaces and line breaks count?

In the main counts, yes. There is a separate figure excluding all whitespace, which is the one to use when a requirement is about content length rather than raw field length.

How do I count characters excluding spaces?

It is shown as its own statistic. It strips spaces, tabs and line breaks, which is usually what an academic word-limit or a printing constraint actually means.

Why does my word processor report a different number?

Word processors usually count the whole document, including headers, footers, footnotes and text boxes, and some exclude them from one figure but not another. They also differ on whether a paragraph mark counts. This tool counts exactly the text in the box and shows each definition separately, so you can see which one matches the limit you have been given.

Read more about this

Other tools people use alongside the character counter.

  • Word Counter

    Count words, sentences and paragraphs as you type, with reading time, speaking time and the most frequent keywords in your text.

  • Case Converter

    Convert text to lowercase, UPPERCASE, Sentence case, Title Case, camelCase, PascalCase, snake_case, kebab-case, CONSTANT_CASE or alternating case.

  • Password Generator

    Generate strong random passwords from 8 to 128 characters using your browser cryptographic random source. Nothing is stored, logged or transmitted.

  • UUID Generator

    Generate up to 100 random version 4 UUIDs at once, with optional uppercase, braces or no hyphens. Copy them all or download them as a text file.

Part of Text & Developer Tools. Last reviewed .