Skip to content
TextRuns in your browser

Text Trimmer

Shorten text to an exact word or character limit without splitting words.

Input
No upload needed — instant
Privacy
Nothing is uploaded
Cost
Free · no sign-up · no watermark

Loading tool…

The tool is loading its code on your device. This happens once and is cached for later visits.

Processed entirely on your device

Everything you type or paste is handled by JavaScript running in this tab. No request is sent, nothing is logged and nothing is stored. Close the page and it is gone.

Overview

About the Text Trimmer

Trim text to an exact word or character limit. Cut on a word boundary, add an ellipsis, and see the before and after counts — perfect for meta tags and posts.

A limit turns writing into a puzzle. A meta description that gets cut off in the search results, an abstract that must fit 250 words, a tweet that will not post at 281 characters, a bio field that rejects anything over 160 — in each case you need to lose content without losing sense, and you need to know precisely how much you have left.

Trimming is not just slicing

The naive way to shorten a string is text.slice(0, limit), and it produces exactly the ugly result you would expect: a description that ends “...how to improve your core web vit”, or a word chopped into “improv”. A useful trimmer has to respect the shape of the text.

Word boundaries. In character mode the cut backs off to the last space, so the output ends on a complete word. This is what makes a 155-character meta description read naturally in the SERP.

Code points, not units. Counting by code point means an emoji or an accented letter counts as one, not two, so the limit you set is the limit you get.

Trailing whitespace. Spaces and line breaks left at the cut are trimmed before the ellipsis is added, so you never get “word …” with a gap.

Words or characters?

ModeCountsTypical use
CharactersEvery code point incl. spacesMeta tags, tweets, SMS, field limits
WordsWhitespace-separated tokensAbstracts, essays, summaries

Most platform limits are character-based, and Google’s are really pixel-based — but a character cap is the reliable proxy. For academic and editorial limits, word mode matches how those limits are defined.

The ellipsis question

An ellipsis signals “this continues”, which is honest for a truncated preview and wrong for a field that must simply be short. Because the ellipsis is added after the cut, a hard cap that includes it needs the limit set one lower. For meta descriptions many people prefer no ellipsis at all, since Google truncates by pixel width and appends its own; for in-app previews the ellipsis is the clearer choice.

Step by step

How to use the Text Trimmer

  1. Paste the text you need to shorten.

  2. Set the limit and choose whether it counts words or characters.

  3. Decide if the cut should land on a word boundary and whether to add an ellipsis.

  4. Read the trimmed text and the live before/after counts, then copy it.

Why use it

Benefits and common use cases

What this tool is good for, and what it deliberately does not try to do.

Never slices a word in half

In character mode the cut backs off to the last space, so a 155-character meta description ends on a whole word instead of stopping mid-word with a dangling fragment.

Counts words or characters

Switch between a word cap for abstracts and summaries and a character cap for meta descriptions, tweets, SMS and form fields, with the count shown live.

Surrogate and whitespace aware

Characters are counted by code point, so emoji and accented letters are not over-counted, and trailing whitespace is trimmed from the result before the ellipsis is added.

See exactly what was removed

The stats show the original length, the trimmed length and whether the text was actually shortened, so you know how much you lost to the limit.

Questions

Frequently asked questions

Short, honest answers about quality, limits and privacy.

What does “cut on a word boundary” mean?

In character mode, instead of stopping exactly at the limit and splitting whatever word is there, the tool backs off to the last space before the limit. A 160-character description trimmed to 155 might end at 148 characters so that it finishes on a complete word.

Does the ellipsis count towards the limit?

The ellipsis (…) is appended after the cut, so the final string can be one character longer than the numeric limit. If you need the total including the ellipsis to fit a hard cap, set the limit one lower or turn the ellipsis off.

How are words counted versus characters?

Word mode counts whitespace-separated tokens and stops after the limit-th word. Character mode counts individual code points, including spaces and punctuation, and stops at the limit. Switch between them with the “Count by” control.

What limits should I use for SEO and social?

A meta description is usually kept to about 155–160 characters, a title tag to roughly 50–60, an X/Twitter post to 280, and an SMS segment to 160. Character mode with an ellipsis suits all of these.