AbraCalc

Lines of Code Counter

Count total lines, non-empty lines, and blank lines in code or text. Free, instant.

Embed this tool on your site

How to use this tool

  1. Enter code or text in the fields above.
  2. Results update instantly as you type — or click Calculate.
  3. Read your total lines and the full breakdown beneath it.

Quickly count total lines, non-empty code lines, and blank lines in any snippet — useful for estimating project size or documentation density.

Frequently asked questions

What counts as a blank line?
A blank line is one containing only whitespace (spaces and tabs). Comments are counted as non-empty lines.

References & sources