Murelio

Loading the features you need.

Line Counter

Count lines separated by LF or CRLF newline characters.

How to use

  1. Paste text and run to read the line count.

Capabilities and scope

The implementation splits on explicit newline characters; an empty string still produces one array element and therefore one line.

How it works

The input is split with /\r?\n/ and the resulting array length is returned.

Example

a b c is counted as three lines.

Useful for

  • Count lines in logs, lists, or code snippets

Before you use it

  • An empty input currently reports one line, and visual soft wrapping is not counted.

Frequently asked questions

Are wrapped screen lines counted?

No. Only actual newline characters create new lines.

Related tools