🧀 Learn Linux

Commonly used · Organize files

rm: Delete files or directories

Put in free practice

Syntax

rm [-rfR] path…

Options

-r / -R
Recursively delete directories
-f
Ignore non-existent paths

Examples

rm downloads/old.tmp

Usage and sandbox support

Check the path before deleting. The sandbox is resettable; real rm usually does not have a recycle bin.

Hands-on exercises

Full documentation ↗

Related commands