Skip to main content

    Line Counter

    Paste your text to count its lines, including how many have text and how many are blank.

    Windows, Mac and Unix line endings are all recognised, so text pasted from any system gives the same count.

    The text you enter is counted in your browser and is not saved or sent to a server by this tool.

    Counts

    Lines
    0
    Lines with text
    0
    Blank lines
    0
    Paragraphs
    0

    All statistics

    Characters
    0
    Characters without spaces
    0
    UTF-16 length (JavaScript length)
    0
    UTF-8 bytes
    0
    Letters
    0
    Digits
    0
    Punctuation marks
    0
    Words
    0
    Unique words
    0
    Average word length
    0 characters
    Longest word
    None
    Sentences
    0
    Average sentence length
    0 words
    Longest sentence
    None
    Paragraphs
    0
    Lines
    0
    Lines with text
    0
    Blank lines
    0
    Reading time (estimate)
    0 sec
    Speaking time (estimate)
    0 sec

    To check your text against social media and search limits, use the platform meters on the character counter.

    Reading and speaking speed

    words per minute
    words per minute

    Times are estimates. The defaults are the average silent reading speed for non-fiction (238) and the average reading aloud speed (183) in Brysbaert (2019). Speeds from 50 to 1000 are accepted.

    Top words

    Words you enter appear here, most frequent first.

    How to use it

    1. Paste or type your text in the box, or open a .txt file from your device.
    2. Read the total lines, lines with text and blank lines in the first tiles.
    3. Check the paragraph count to see how many blocks of text there are.
    4. Use Copy summary to copy every count as a plain text block.

    Lines, paragraphs and wrapped lines

    • A line ends at a line break. Text that wraps onto the next row because the box is narrow is still one line, so resizing the window never changes the count.
    • A paragraph is a block of lines with text, separated from the next block by at least one blank line.
    • A blank line is empty or holds only spaces or tabs.

    Line endings

    Windows ends lines with a carriage return and a line feed (\r\n), Linux and macOS use a line feed (\n), and classic Mac OS used a carriage return (\r). Each counts as one line break here, and a text that mixes them is counted the same way.

    The total is the number of line breaks plus one, so text that ends with a line break has an empty last line. Tools that count line break characters instead report one less.

    Uses for a line counter

    • Lists: check how many items a list has, one per line.
    • CSV data: each row is usually one line, but a quoted field can contain a line break, so the row count can be lower than the line count.
    • Logs: count entries in a log that writes one entry per line, and use the blank lines figure to spot gaps.
    • Poems and lyrics: count lines, and stanzas, which appear here as paragraphs.
    • Code: get a quick count of lines in a snippet, blank ones included.

    Notes

    • Empty text has 0 lines. Any text, even a single space, has at least 1.

    More text counters

    Frequently asked questions

    Does wrapped text count as more than one line?

    No. Only a line break starts a new line, so text that wraps on screen stays one line however narrow the box is.

    Do blank lines count?

    They count toward the total, and the blank lines figure shows how many there are. A line with only spaces or tabs is treated as blank.

    Why does another tool show one line fewer?

    Text that ends with a line break has an empty last line here. Tools that count line break characters instead of lines report one less for that text.

    Does it work with Windows line endings?

    Yes. \r\n, \n and \r each count as one line break, even when a text mixes them.

    Can I count rows in a CSV file?

    Paste the CSV text and read the line count, then subtract 1 for a header row. A quoted field with a line break inside it spans more than one line.

    Related Tools