Updated · Built and checked by the PlinzoTools team, formulas tested against published sources
Truncate text to a max length with an ellipsis, optionally at whole words.
This is a longer piece of text that we want to...This tool truncates text to a maximum character length, appending a suffix (like "...") -- the same logic behind meta-description previews, excerpt generation, or any UI that needs to show a shortened preview of longer text. It can optionally break at the last whole word rather than cutting mid-word.
Enter text, a max length, and a suffix. Toggle "whole words only" to avoid cutting a word in half. The truncated result appears instantly.
Text longer than the max length is cut at that position. In whole-words mode, the cut point backs up to the last space before the limit, so the result never ends mid-word -- at the cost of the final output sometimes being a few characters shorter than the strict max.
To check a meta description's actual pixel-width truncation in search results specifically, see the existing SERP Snippet Previewer.
The tool counts characters, including spaces and punctuation, as JavaScript sees them. If your text is already as short as the max length or shorter, it is returned unchanged and no suffix is added. Otherwise the text is cut at exactly the max length. With "Break at whole words only" ticked, the tool then looks for the last space inside that cut and removes everything after it. Finally the suffix is attached. A stat tile reports the length of the final output so you can see the effect of the suffix.
The sample text is "This is a longer piece of text that we want to truncate to a specific length for a preview or excerpt." That is 102 characters. With a max length of 50 and the suffix "...", the raw cut ends with the letters "tru". The last space before that point comes after the word "to", so in whole-words mode the tool returns "This is a longer piece of text that we want to..." with 46 characters of text plus 3 for the suffix, a total of 49. With whole-words mode off, the result would be "This is a longer piece of text that we want to tru..." at 53 characters. The output can therefore be longer than the max length by the suffix length, and in whole-word mode it may still land below the limit.
Because the suffix is added after the cut, it is not included in the max length you enter. If your target has a hard ceiling, subtract the suffix length first. For a 160-character limit and a three-character suffix, enter 157. The output stat tile lets you confirm the final size at a glance.
Output length = characters kept (at most the max length) + suffix length
Use it to draft excerpts for cards, summaries under headings, table cells with limited room and preview text for notifications. For search snippets, remember that engines often decide length by display width rather than character count, so treat any character limit as a rough guide.
Only in whole-words mode -- backing up to the last complete word before the limit means the final text (before the suffix) can end up a bit shorter than the strict character cutoff, avoiding an awkward mid-word cut.
No -- the suffix is appended after truncating to the max length, so the total output (text + suffix) can be slightly longer than the max length number itself.
Yes -- enter any suffix text you want, including an em dash, "(more)", or nothing at all.
It is returned unchanged, and no suffix is added because nothing was cut.
Subtract the suffix length from your limit before entering the max length, since the suffix is added afterward. Check the Output Length tile to confirm.
No. It only looks for a plain space, so text separated by newlines or tabs may still be cut in the middle of a word.
Yes. Clear the suffix field and the tool returns just the truncated text with nothing appended.
Reference: MDN Web Docs