Skip to content
100% local

Minimum words filter

Remove lines that have fewer words than a threshold you set.

Input

Minimum words filter

Paste a list of lines and this tool filters out the ones that don't carry enough words to be useful — one-word fragments, stray labels, truncated rows from a scrape, or noise left over from copying a table into plain text. Set a minimum word count and keep only lines that meet it, or flip the mode to do the opposite and pull out just the short lines instead.

Word count is measured by splitting each line on whitespace, so runs of multiple spaces or tabs between words don't inflate the count and an empty line always counts as zero words. The threshold is inclusive: with a minimum of three, a line with exactly three words is kept in the default "keep long" mode. Switch to "keep short" when you want the inverse — for example to isolate incomplete rows so you can review or fix them separately, rather than deleting them outright.

This is useful for cleaning scraped text, log exports, CSV columns pasted as plain text, or any list where genuinely short lines are junk rather than data — a URL slug list, a set of tags, or notes where a lone word usually means an incomplete entry. It handles both Windows (CRLF) and Unix (LF) line endings the same way, and the tally under the output shows how many lines remain, how many were removed and the resulting character count, so you can check the result at a glance.

Everything runs locally in your browser. Your text is never uploaded to a server, so it's safe to use on internal notes, unpublished drafts or anything else you'd rather keep private. Once you're happy with the result, copy it, download it as a .txt file, or send it straight into another tool to continue cleaning up your text.

FAQ

What counts as a "word"?
Any run of non-whitespace characters separated by spaces or tabs. Multiple spaces between words are treated as a single separator, so they don't affect the count.
What happens to empty lines?
An empty line has zero words, so in the default "keep long" mode it is always removed. Switch to "keep short" and empty lines are always kept.
Is the minimum inclusive or exclusive?
Inclusive in "keep long" mode: a line with exactly the minimum number of words is kept. "Keep short" mode is the exclusive inverse — a line right at the threshold is removed.
Can I use this to find short lines instead of removing them?
Yes. Switch the mode to "keep short" and the tool keeps only the lines below your threshold, so you can review them instead of just discarding them.
Is my text uploaded anywhere?
No. This tool runs entirely in your browser — your text is never sent to a server.