← Back to all tools

Simple & private

Line Counter

Count total, empty and non-empty lines.

What is this tool?

The Line Counter reports how many lines a block of text contains, including how many are empty and how many contain content. It is a quick way to check the size or shape of pasted text without opening it in a separate editor or spreadsheet.

How to use this tool

  1. Paste your text into the input box.
  2. Click "Run tool".
  3. Read the total, non-empty and empty line counts.
  4. Edit the text and run it again to see the counts update.

Example

A list with 10 lines, two of which are blank, shows "Total: 10", "Non-empty: 8" and "Empty: 2". Pasting a single paragraph with no line breaks always shows "Total: 1", since a line is any text ending at a line break or at the end of the input.

Common use cases

Frequently asked questions

Does it count the last line if there is no line break after it? +

Yes, every line is counted whether or not it ends with a line break.

What counts as an empty line? +

A line with no characters, or only spaces, is counted as empty.

Can I use it on very long text? +

Yes, it works instantly regardless of how many lines you paste.

How is this different from the Word Counter? +

The Word Counter measures words, characters and reading time; the Line Counter focuses specifically on how many lines — including blank ones — a block of text has.

Does a wrapped line on screen count as more than one line? +

No, wrapping is a visual effect of the text box width. A line here means the text between actual line breaks, not what fits on one visual row.