this is my first question here. I just revived an old pc to play dos games. I couldn't rename a folder, but I can rename files. Any idea why? Q2: How to see the full folder name in dir command? I see something like this : folderna~1 instead of foldername.


  • Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.
    – Community Bot
    Commented Apr 7, 2022 at 18:08

2 Answers 2


I'm sure you tried to use REN oldname newname to rename a folder.

The REN command is only for renaming files. In order to rename a folder, you have to use the MOVE command.

So you would want to use the following command:

MOVE oldfolder newfolder

A bit counterintuitive, but that's how you have to do it in DOS or Command Prompt.

See also: Information about the MOVE command

As for names with ~1 and such, the old MS-DOS only had support for filenames with 8 characters and extensions with 3 characters or less.

A filename that has either 9 characters or more for its name, or 4 characters or more for the extension will automatically be renamed by systems that support longer filenames such as Windows to the first 6 characters of the filename, followed by a ~ and a number. If there's only one name, then its always ~1, but if two files or folders that share the same first 6 characters, then one of them will have ~1, the other will have ~2 and so on.

On old systems that only have short filenames, it is simply not possible to create files or folders with a longer name. For backwards compatibility, new implementation allows for both types. In Command Prompt, one can use Dir /x too see both the long and short filename/foldername. On old systems, you have to guess which is which.

  • I included a picture, can't you see it? Anyway, when I tried move I've got bad command Commented Apr 7, 2022 at 18:44
  • @nonamedelete no, can't see a picture. I edited your post to reveal it. I've now changed your question to show the image.
    – LPChip
    Commented Apr 7, 2022 at 18:46
  • @kofifus if that is true, then explain why it doesn't work in the example screenshot. Keep in mind that using REN to rename folders was added somewhere on windows dos, not MSDOS, which is what this question is about.
    – LPChip
    Commented Jul 4, 2023 at 6:32

If you are using an old DOS OS it might only support 8.3 names. Eight characters for the name and 3 for the extension. Thus names that are longer than 8.3 are shown as folderna~1

Long Filename

  • All versions of DOS (including the command prompt under Windows 95 and 98) were limited to short filenames, and LFNs from the GUI would appear truncated and numbered. Commented Apr 7, 2022 at 18:20
  • @JeffZeitlin: command.com did support LFNs in Win98 out of the box (you could see them in dir or load into edit.com). I've heard of LFN drivers for older MS-DOS, but have no clue about how they work. Commented Apr 7, 2022 at 18:31
  • 1
    @user1686 - I recall that COMMAND.COM supported LFNs in Win98SE, but I'm fairly sure that the original release of Win98 still used 8.3 in COMMAND.COM. The change from 98 to 98SE was also the change from Windows being a "DOS supershell" to Windows "running native". Commented Apr 7, 2022 at 19:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .