Line Counter

Count the total lines, non-empty lines, the longest line and the average line length in any text.

Result

In short

What is the Line Counter?

The Line Counter reports the total number of lines in your text, how many are not empty, the length of the longest line and the average line length. It is handy for checking lists, logs, code snippets, poems, subtitles and data exports before you import or publish them.

How to use it

  1. Paste your text into the box.
  2. Choose whether spaces around each line count towards its length.
  3. Read the line statistics in the result box.
  4. Edit the text and watch the figures update.
Questions

Line Counter — FAQ

Is a final empty line counted?

No. If your text ends with a line break, the empty space after it is not treated as another line.

How is the average line length worked out?

It is the total length of all non-empty lines divided by the number of non-empty lines, rounded to one decimal place.

Does it count wrapped lines on screen?

No. It counts real lines that end with a line break, not lines created by the screen width.

More Text & Writing tools