Analyze your source code: count lines, comments, blank lines, and words. Supports 10 programming languages with comment-style detection.
The tool uses regex-based parsing to detect single-line comments (e.g., // in JavaScript, # in Python) and multi-line comments (e.g., /* ... */ in JavaScript, <!-- ... --> in HTML). A line with both code and a comment is counted as a code line.
A blank line is any line that contains no characters or only whitespace (spaces and tabs). Blank lines are important for code readability and are typically 10-20% of well-formatted code.
The tool detects string literals (single and double-quoted) and counts words within them. Template literals and multi-line strings in supported languages are also detected.
There is no universal standard, but many teams aim for 10-30% comment lines. Self-documenting code with clear naming often needs fewer comments. Over-commenting can be as problematic as under-commenting.
No. All analysis runs entirely in your browser. Your code never leaves your device.