Find the largest files
Lists every regular file over 100MB anywhere under a directory tree, skipping directories, symlinks and other non-file entries entirely.
Last updated
find . -type f -size +100M
How it works
-type f restricts matches to regular files only, so directories, symlinks and device entries never show up in the results. -size +100M matches anything strictly LARGER than 100 megabytes — the leading + means "greater than," which matters because a bare 100M without it would only match files whose size rounds to exactly that unit, which almost nothing does in practice.
Together this answers "what's actually eating disk space here" without any extra tools — just find's own flags, no piping to du or awk required for the search itself.
Watch out for
- →This doesn't sort the output by size — results come back in whatever order find walks the tree, not biggest-first. Piping through something like -exec ls -lh {} \; combined with sort gets you a ranked list.
- →-printf, which some recipes use to format size and path together for sorting, is a GNU find extension — it doesn't exist on BSD find (macOS's default), where you'd pipe to xargs stat -f%z instead, or install GNU find (gfind) via Homebrew's findutils formula.
- →Symlinked files aren't followed into their targets by default — find reports a symlink's own tiny size, not the size of whatever it points to; add -L before the path to follow links if that's what you actually want measured.
Part by part
- -type f
- Regular files only, excluding directories and symbolic links. Without it, directory entries appear in the results and confuse the reading.
- -size +100M
- Larger than 100 megabytes. The plus means greater-than; a bare 100M means exactly 100M, which almost never matches anything.
Common mistakes
find . -type f -size 100MWithout the plus this matches files of exactly 100 megabytes after rounding up, which is almost nothing. The command appears to work and reports no results, so it looks like there are no large files.
find . -type f -size +100Mfind . -type f -size +100With no unit, find counts 512-byte blocks, so this means larger than about 51 kilobytes and returns nearly every file. The unit suffix is not optional in practice.
find / -type f -size +100MStarting at the root scans every mounted filesystem, including network shares and virtual filesystems, and floods the output with permission errors. Start from a real directory, or add -xdev to stay on one filesystem.
Questions
How do I sort the results by size?
find does not sort. Pipe through something that does: find . -type f -size +100M -exec du -h {} + | sort -rh puts the biggest first, with human-readable sizes.
What units does -size accept?
c for bytes, k for kilobytes, M for megabytes and G for gigabytes. Sizes are rounded up to the next whole unit, which is why exact matches behave unintuitively and the plus form is the useful one.
How do I find large directories rather than files?
du is the right tool: du -h --max-depth=1 | sort -rh shows what is consuming space one level down. find works on individual files and cannot total a tree.
Why do I get permission denied errors?
find reports every directory it cannot read. Append 2>/dev/null to hide them, but only once you are satisfied you are not silently skipping the area you actually wanted to search.