TextArray
100% local

Truncate text

Cut text down to a set number of characters or words and trim line edges.

Input
Output

Truncate text

Paste text and cut it down to a fixed length — a set number of characters or a set number of words. It is the quickest way to fit a meta description into 160 characters, keep a product blurb inside a CMS field limit, shorten a headline for a social post, or clip a long exported column down to preview snippets.

Choose whether the limit counts characters or words, then set the number. "Keep whole words" stops the cut landing in the middle of a word: the text backs off to the last complete word before the limit instead. Turn on the ellipsis and a single … is appended; in character mode it is counted inside the limit, so a setting of 160 really does return at most 160 characters. Switch on per-line truncation to apply the limit to every line on its own, which turns a pasted column into a set of equal-length snippets.

Two extra fields trim the edges. Remove the first few characters of every line to strip a fixed prefix such as a bullet or an ID, and remove the last few to drop a trailing marker. Both run before the length limit is applied. Windows (CRLF) and Unix (LF) line endings are treated the same and the output always uses LF. Characters are counted the way you see them, so an accented letter or an emoji counts as one and is never split in half.

Everything runs in your browser and the text is never uploaded, which makes it safe for unpublished copy or customer data. The tally under the output shows the length before and after and how much was removed. Copy the result, download it as a .txt file, or move it back to the input for another step.

FAQ

Does it limit by characters or by words?
Both — pick the unit in the options. The limit then counts either characters or words, and the tally shows the length before and after the cut.
Will it cut a word in half?
Not with "Keep whole words" enabled: the text backs off to the last full word before the limit. A single word longer than the entire limit is still cut, because there is no earlier boundary to fall back to.
Does the ellipsis count toward the limit?
In character mode, yes. The … is included, so the result never exceeds the number you set — useful for meta descriptions. In word mode it is simply added after the last kept word.
Can I shorten every line to the same length?
Turn on "Truncate each line" and the limit applies to each line on its own. You can also remove a fixed number of characters from the start or end of every line.
Is my text uploaded anywhere?
No. The tool runs entirely in your browser and your text never leaves your device.