Line counter
Use this text line counter or newline counter to count every line or only non-empty lines, then find the exact longest and shortest entries for writing, code, or data cleanup.
Enter your text
Local and private. Your text stays in this browser tab and is not sent anywhere. A trailing line break counts as an empty final line when empty lines are included.
Ways to use a line counter
Check lists and records. Count names, URLs, inventory items, imported rows, addresses, or any other newline-separated data before moving it into a spreadsheet, database, or form.
Review structured writing. Measure poetry, lyrics, subtitles, transcripts, dialogue, and scripts where line breaks carry meaning beyond the total word count.
Inspect logs and source text. Estimate the size of logs, configuration blocks, code samples, and generated output, then use the longest and shortest values to spot unusual rows.