Wrap text to a fixed width

Wrap text to width inserts hard line breaks so no line is longer than the target column count. The wrap is word-aware by default: a long word that would push the line past Width moves to the next line whole. Toggle Break Words on to split words longer than the width. Toggle Leading Space on to preserve indentation when wrapping continues a line. To take rectangular slices instead, use slice text with Per Line.

Input
Line 1:1 LF cloud_done Saved locally
Result Wrap Text to Width
0 lines 0 chars

Hard wrap with word-aware breaks

Width is the column ceiling, between 10 and 200 inclusive. The wrap walks word by word: it accumulates the current line, and when adding the next word (plus its separator space) would push past Width it flushes the current line and starts a new one. Single-line and multi-line input are both supported; existing line breaks are honoured as paragraph boundaries.

Break Words off (the default) leaves words longer than Width untouched, even though they overshoot the limit. Turn the toggle on to split long words into Width-sized chunks before continuing the wrap. This is useful for hard-wrapping log lines or URLs.

Leading Space off (the default) starts every wrapped continuation line at column 0. Turn it on to copy the original line's leading whitespace onto each continuation, so a bullet item indented with stays visually indented after wrap.

How to use wrap text to a fixed width

  1. 1Paste your text into the input panel on the left.
  2. 2Set Width to the column ceiling (10 to 200).
  3. 3Toggle Break Words on if very long words should be split rather than overflow.
  4. 4Toggle Leading Space on if continuation lines should copy the original leading whitespace.
  5. 5Click Copy or Download in the output header.

Keyboard shortcuts

Drive TextResult without touching the mouse.

Shortcut Action
Ctrl FOpen the find & replace panel inside the input Plus
Ctrl ZUndo the last input change
Ctrl Shift ZRedo
Ctrl Shift EnterToggle fullscreen focus on the editor Plus
EscClose find & replace, or exit fullscreen
Ctrl KOpen the command palette to jump to any tool Plus
Ctrl SSave current workflow draft Plus
Ctrl PRun a saved workflow Plus

What this tool actually does

Word-aware wrap on space boundaries

The line is split on single spaces. Words are accumulated into the current output line; when the next word would push past Width the current line is flushed and a new one started with that word.

Break Words handles oversized tokens

With the toggle off, a word longer than Width is placed on its own line and overshoots the limit. With it on, the word is sliced into Width-sized chunks; each chunk becomes its own line.

Leading Space preserves indentation

The leading whitespace of each input line is captured (regex /^[ \t]+/). With the toggle on, that prefix is prepended to every continuation line, keeping bulleted or indented blocks visually aligned after wrap.

Existing line breaks are paragraph boundaries

The wrap runs line by line: each input line is wrapped independently, then results are joined with \n. Hard line breaks in your input are preserved as separators between wrapped paragraphs.

Width is bounded 10 to 200

The registry caps Width between 10 and 200. Common picks: 72 for plain-text email, 80 for Unix-style code, 100 or 120 for modern editors.

Worked example

Width 25, Break Words off, Leading Space off. Each line stays at or below 25 characters; words are not split.

Input
The quick brown fox jumps over the lazy dog. Pack my box with five dozen liquor jugs.
Output
The quick brown fox jumps
over the lazy dog. Pack my
box with five dozen liquor
jugs.

Settings reference

Behaviour Effect on output
Width (10-200) Column ceiling. Each output line is at or below this length, except for oversize words when break-words is off.
Break Words off (default) Words longer than Width stay whole and overshoot the limit on their own line.
Break Words on Long words are sliced into Width-sized chunks before the wrap continues.
Leading Space off (default) Continuation lines start at column 0.
Leading Space on Continuation lines copy the original line's leading spaces or tabs (regex /^[ \t]+/).
Existing line breaks Treated as paragraph boundaries; each input line is wrapped independently.
Spaces between words Single space is the word separator. Multiple spaces are kept as part of the wrapped tokens.

FAQ

Will it ever split a word?
Only when Break Words is on. Off, a word longer than Width sits on its own line and exceeds the limit; on, it is sliced into Width-sized pieces.
How do I keep my Markdown indentation through the wrap?
Turn Leading Space on. The leading spaces or tabs of each input line are copied to every continuation, so list items stay aligned.
What is a good width for plain-text email?
72 characters is the conventional plain-text email width. 80 is the classic Unix code width. 100 or 120 fit modern editor windows comfortably.
Does it preserve my paragraph breaks?
Yes. Each input line is wrapped independently, then rejoined with \n. Hard line breaks in your input become paragraph boundaries.
Does anything upload?
No. The wrap runs in your browser. Your text never leaves the page.