Line Counter

0 Total lines0 Non-empty lines0 Blank lines0 Words0 Characters

What is Line Counter?

Line Counter counts the lines in any block of text as you type. It shows total lines, non-empty lines and blank lines separately, plus word and character counts. It is handy for checking code files, lists, poems, scripts and any document where line count matters. The counting is live and runs entirely in your browser.

How to use

  1. Paste or type your text into the input box.
  2. Total, non-empty and blank lines are counted instantly.
  3. Words and characters are counted too.
  4. Click Clear to start over with new text.

Features

  • Live line count as you type or paste.
  • Total lines, non-empty lines and blank lines shown separately.
  • Word and character counts included.
  • Blank lines counted, not ignored.
  • Works with pasted code, lists, poems and documents.
  • Free, private, and no signup required.

Frequently asked questions

How do I count lines in text?

Every line break starts a new line. Lines with only spaces are counted as blank lines, and lines with any other text are counted as non-empty lines. Use it to count lines online in any pasted text.

Does the last line count if it has no line break?

Yes. The final line counts even without a line break at the end. An empty input has zero lines.

What counts as a blank line?

Any line that is empty or holds only spaces or tabs. Lines with any visible character count as non-empty.

Can I count lines in code files?

Yes. Paste code or CSV text and the tool counts every line, including blank lines and comment lines. Each CSV row counts as one line.

Is my text sent to a server?

No. All counting runs in your browser with JavaScript, so your text never leaves your device.

Is this tool free?

Yes, it is free with no signup and no limits.

Related tools