← All tools
Text cleanup
Trim each line
Remove surrounding whitespace from each line without dropping lines.
Input
Runs entirely in your browser. Input is not uploaded.
Output
Live resultAlpha Beta
How to use
Enter your text or numeric values. The result updates immediately. Copy the output or reset the example. Everything is computed locally in your browser.
Related tools
Trim textRemove whitespace only at the beginning and end of text.Collapse whitespaceReplace runs of whitespace including line breaks with one space.Collapse spaces per lineCollapse spaces and tabs while retaining line boundaries.Remove blank linesDrop empty or whitespace-only lines; keep other line content unchanged.Deduplicate linesKeep the first occurrence of each exact line.Sort linesSort lines lexicographically by Unicode code units, preserving duplicates.