Learn how to measure file size in lines, words and bytes with a single tiny tool. 28.05.2026 | reading time: 2 min Few commands are as small and useful as `wc`: he reads input and reports counts for lines, words and bytes or characters, so he can quickly check file sizes, pipeline results or batch summaries. Start with a sample file Create a tiny file and run `wc` to see all counts at once: ```bash\nprintf "Alpha beta\nGamma\nDelta Epsilon\n" > report.txt\nwc report.txt\n# shows: 3 5 31 report.txt\nwc -l report.txt\n# shows: 3 report.txt\nwc -w report.txt\n# shows: 5 report.txt\nwc -c report.txt\n# shows: 31 report.txt\n``` Beyond basic counts Use `-l` to get lines, `-w` for words, `-c` for bytes and `-m` for characters when UTF-8 matters; remember that bytes and characters can differ for multibyte encodings, and combine `wc` with pipes like `grep -i error logfile | wc -l` to count matches across streams. Scale up with other commands Count many files with `find . -type f -name "*.log" -print0 | xargs -0 wc -l` to get per-file lines and a total; pair `wc` with `awk` or `sort` to build summaries, or use process substitution to compare outputs quickly. Neighbors on the command line In real workflows `wc` often sits beside filtering and text-processing tools: use it after `grep` to count matches, after `sed` to check edits, or with `awk` to produce structured reports before exporting results. Wrap-up and next steps Practice by integrating `wc` into short scripts and pipelines to feel how fast checks catch issues early; if he wants to go deeper into Linux administration, consider studying for CompTIA Linux+ or LPIC-1 and try intensive exam preparation at bitsandbytes.academy. Join Bits & Bytes Academy First class LINUX exam preparation. utilities scripting filesystem troubleshooting