Press "Enter" to skip to content

How To Get Short Directory Name In Windows (8.3 File/Directory Name Format)

In windows if you list directory and files with DIR command in MS Dos prompt then you will get the list of files and directory with long names including spaces and when you want to change the directory with CD command to get into that directory then you may can get error.

Below is the screen shot if you give DIR command:

get short directory and file names in ms dos for windows

To get the short names for files and directories in 8.3 name format in windows give Dir command with X parameter e.g. Dir /x as shown below:

file and directory name in 8.3 format in windows

Like for directory Program Files (x86) the short name is Progra~2.

Vinish Kapoor

Hi, I am a full stack developer and writing about development. I document everything I learn and help thousands of people. is created, written, and maintained by me; it is built on WordPress, and hosted by Bluehost. Connect with me on Facebook, Twitter, GitHub, and get notifications for new posts.


  1. Nice post. I have been reading a lot of stuff on this topic in the last few months, but this article stands out with its simplicity & authenticity. Every passage made profound sense. Thanks a lot for this.
    Best institute chennai

Leave a Reply

Your email address will not be published. Required fields are marked *