Easy Tutorial
❮ Linux Command Manual Linux Comm Enable ❯

Linux cd Command

Linux Command Manual

The Linux cd (short for "change directory") command is used to switch the current working directory.

The dirName can be an absolute path or a relative path. If the directory name is omitted, it changes to the user's home directory (the directory where you are when you first log in).

Additionally, ~ represents the home directory, . represents the current directory, and .. represents the parent directory of the current directory.

Syntax

cd [dirName]

Examples

Navigate to /usr/bin/:

cd /usr/bin

Navigate to your home directory:

cd ~

Navigate to the directory two levels up:

cd ../..

Linux Command Manual

❮ Linux Command Manual Linux Comm Enable ❯