Boneyard Tools

Text File Statistics

Drop in a text file to count its words, lines, characters, and bytes, like the Unix wc command but in your browser. It also reports blank versus non-empty lines, the line-ending style (LF, CRLF, CR, or mixed), the longest line and its line number, the average line length, and whether the file uses a byte-order mark. The file is read entirely on your device and never uploaded.

How to count words and lines in a text file

  1. Drag a .txt, .log, .md, or .csv file onto the box, or click to browse for one.
  2. Read the stat cards: bytes, characters, words, lines, blank lines, and more.
  3. Check the line-ending and longest-line details to spot formatting issues.

Examples

A server log file

access.log dropped onto the tool
2.4 MB, 18,902 lines, 0 blank lines, line ending LF, longest line 412 chars

Frequently asked questions

Is my file uploaded anywhere?

No. The file is read and analyzed entirely in your browser using JavaScript. Nothing is sent to a server, so logs, drafts, and other sensitive text stay on your device.

How does this work without an upload?

Your browser reads the picked file into memory, decodes it as UTF-8, and counts everything locally. There is no network request, which is also why it works offline once the page has loaded.

How are characters counted versus bytes?

Characters are Unicode code points, so an accented letter or an emoji counts as one character. Bytes are the raw file size, which is larger for multibyte text such as UTF-8 accents or emoji.

What counts as a line, and what about the last line?

A line is the text between line breaks. If the file ends with a newline, that trailing empty segment is not counted as an extra line, so a file ending in a newline reports the number of separators, not one more.

How does it detect line endings?

It scans for Windows (CRLF), Unix (LF), and classic Mac (CR) breaks. If only one style appears it is named directly; if more than one appears the result is mixed, which often signals an editing or merge issue.

What is a BOM and why does it matter?

A byte-order mark is an invisible marker (the bytes EF BB BF) some editors add to the start of UTF-8 files. The tool detects and reports it, and excludes it from the character count so the first line stays clean.

Related tools