10 Most Used Linux Commands

Command Purpose Example
ls List files and folders ls -l
cd Change directories cd Documents
pwd Show the current directory pwd
mkdir Create a new directory mkdir projects
cp Copy files or folders cp file.txt backup.txt
mv Move or rename files mv old.txt new.txt
rm Delete files or folders rm file.txt
cat Display the contents of a file cat notes.txt
grep Search for text inside files grep "error" log.txt
sudo Run a command with administrator privileges sudo apt update

Useful Options

Warning: Be careful when using rm and especially commands such as sudo rm. Deleted Linux files may be difficult or impossible to recover.