๐Ÿ“ Text Wrapper

Wrap long lines of text to a specific column width. Word-boundary wrapping, never splits words. Great for code comments, terminal output and emails. Free, private, no signup.

Ruler
Output
Your wrapped text will appear here...
โ€”

About the Text Wrapper

This tool reformats text by inserting line breaks so that no line exceeds your chosen column width. It always wraps at word boundaries, ensuring words are never split across lines. The ruler above the output shows exactly where your chosen column width falls.

Preserve Line Breaks vs Reflow

  • Default (Reflow) โ€” joins all input lines into a single block and rewraps from scratch at the new width. Best for reformatting a paragraph or prose
  • Preserve Line Breaks โ€” treats each existing line independently and only wraps lines that are too long. Best for code, lists or text where intentional line breaks should be kept

Common Use Cases

  • Formatting plain-text emails to fit a 72 or 80 character width
  • Wrapping long comment blocks in code to match a style guide
  • Reformatting terminal output or log text to a narrower width
  • Preparing text for fixed-width fonts in documentation or READMEs
  • Fitting text into SMS or other character-per-line-limited mediums

Frequently Asked Questions

Text wrapping inserts newline characters so that no line in the output exceeds the specified column width. Wrapping always occurs at word boundaries โ€” words are never split. This is useful for formatting plain text for terminals, code comments, emails and documentation that must fit a fixed width.

Reflow first joins all lines into a single block and then rewraps everything at the new width โ€” ideal for reformatting prose. Preserve Line Breaks treats each existing line independently and only wraps lines that are too long โ€” ideal for code, lists and formatted text where intentional breaks should stay.

Common conventions: 80 characters is the classic terminal and code standard. 72 characters is the standard for plain-text email bodies. 100 or 120 characters is common in modern codebases with wider monitors. PEP 8 (Python style guide) recommends 79 characters.

A word that is longer than the column width is placed on its own line without being broken. Breaking words mid-character would produce unreadable output, so the tool always outputs the complete word even if it exceeds the width on that single line.