Microsoft DOS chdir command

Updated: 05/21/2018 by Computer Hope

About chdir

Chdir (change directory) is a command used to switch directories in MS-DOS.

Availability

The chdir command is an internal command and is available in the below Microsoft operating systems.

Chdir syntax

CHDIR [drive:][path]
CHDIR[..]
CD [drive:][path]
CD[..]

Chdir examples

chdir

Typing chdir by itself will display the current directory.

chdir\

Goes to the highest level, the root of the drive.

chdir..

Goes back one directory. For example, if you are in the C:\Windows\COMMAND> directory, this would take you to C:\Windows> directory.

Windows 95, Windows 98 and later versions of Windows allow you to go back more than one directory by using three or more dots. For example, typing "chdir..." with three dots after the cd would take you back two directories.

chdir Windows

If present, would take you into the Windows directory. Windows can be substituted with any other name.

Additional information