Compare

du vs df

When you need filesystem-level capacity information and when directory-level usage matters more.

`df` shows free and used space at the filesystem level. `du` shows how much space specific files and directories consume inside that filesystem.

Use df When

You want to know whether a filesystem is full overall.

You need mount-level capacity and availability information quickly.

Use du When

You are tracking down which directories or files are using space.

You need per-path disk usage detail to support cleanup work.

Rule of Thumb

df answers how full the filesystem is. du answers what is filling it.

Want the short version? Browse the compact sheet views and save the commands you use most into a Cheatbook.