Before reformatting, it helps to know how many lines actually exceed your target width.
Line Width Formatter wraps text to a maximum width and reports how many input lines were over the limit.
How to use Line Width Formatter
- Paste the text you want to check and reflow into the input box.
- Set the maximum width, and Line Width Formatter wraps the text and counts the lines that were too long.
- Copy the width-limited text, or download it as a text file.
Use cases
- Enforcing a strict line length for a README or changelog.
- Checking how many lines break a terminal-width limit.
- Reflowing source comments to a maximum column.
Good to know
Line Width Formatter wraps the text to your maximum width at word boundaries and shows a count of how many original lines exceeded that width before wrapping. It is aimed at enforcing a hard line-length rule.
Frequently asked questions
What does the over-width count mean?
It is the number of input lines whose length was greater than your target width before any wrapping was applied.
Does it split long words to meet the width?
No. Wrapping happens at spaces, so an over-long single token stays on its own line even if it exceeds the width.
Which width is common for code?
Many projects use 80 or 100 columns, so set the width to the limit your project enforces.