Ad space (banner)
🖥️Linux Lessons
Lesson 6 / 61

Moving Around with cd

cd is for when "I want to move to another folder and work there." cd stands for Change Directory, and it moves your current location (the current directory).

Use it in the form cd folder-name, giving the destination path. cd .. moves up one level, and just cd alone takes you back to your home directory.

Running cd project moves you into a folder named project inside your current location. Building the habit of checking with pwd afterward gives you peace of mind.

A common early mistake is a typo in the folder name, or pointing at a path that doesn't exist, producing a "No such file or directory" error. Checking contents with ls first prevents this.

In real work, this is one of the most basic operations you'll use constantly — moving into project folders, moving to a deployment directory, and more.

Linux
Try it (type this into the pseudo terminal)
cd project

🧑‍💻 You can type this command into the Linux pseudo terminal to try it yourself (this page itself has no interactive terminal).

Ad space (banner)
Ad space (in-article)