In Windows 11, you can give a file a 200-character name, full of spaces and emojis. However, if you dare to name a file or folder simply “CON,” File Explorer will flatly refuse. CON, PRN, AUX, NUL, COM1 through COM9, and LPT1 through LPT9 are reserved device names. According to Microsoft engineer Raymond Chen, their origins can be traced back to DOS 1.0 — a version that didn’t even have folders…
Windows 11 still treats CON, NUL, and COM1 as devices and not as file names.
| Name | What is he doing |
|---|---|
| CON | Console (keyboard and screen) |
| PRN | Printer |
| AUX | Auxiliary device |
| NUL | Null device (discards output) |
| COM1 to COM9 | Serial ports |
| LPT1 to LPT9 | Parallel (printer) ports |
Microsoft's documentation on file naming is very clear: “Do not use the following reserved names for file naming.” These rules also apply to folders, as Windows treats folders as a special type of file.
Adding a file extension supposedly doesn't help (although, in fact, it does!). According to Microsoft, “NUL.txt and NUL.tar.gz are equivalent to NUL.” Even exponents are no exception, as Windows recognizes ¹, ², and ³ as digits; thus, COM¹ and LPT³ are reserved “in every directory.”
Architecturally, COM1 is a link to the serial port within the Windows kernel—what Microsoft calls an “MS-DOS device name.” So, typing COM1 directs the command to the port, not to a file.
Raymond Chen explains why a rule from DOS 1.0 remains in effect in Windows 11.
In a 2003 post on his blog, “Old New Thing,” Chen explains that “DOS 1.0 did not support subdirectories, lowercase characters, or filenames longer than 8.3” — a limitation that accounts for the older system filenames in Windows 11.
Back then, if an assembler asked where to save a listing and you wanted it printed, you typed “PRN” as the filename. Typing NUL would discard the output, while typing CON would direct it to the screen.
Since there was only one directory on the disk, there was no other place where these “special” names could work. When folders were later introduced, Chen states that if these names did not work within folders, it would not be possible to go to a folder, run the interpreter, and use NUL to discard the output. Thus, these names acquired their special property in each folder.
However, we have come a long way from the DOS era. So why do such rules still exist in 2026?
“Because everyone still relies on them,” Chen writes. Batch files hide output by redirecting it to >NUL, scripts check for the existence of a folder with the command “if exist directoryname\nul,” and older guides recommend creating files with the command “copy CON.”
It is noteworthy that, if this rule were removed, any command script that redirects to NUL would start creating real files.
In Windows 11 26H2, if you try to name a new folder to CON, you will see the message: “The specified device name is not valid.” The same will happen with PRN, AUX, NUL, and COM1.
However, NUL.txt will be created without any problems, as will CON.txt, even though Microsoft's documentation still states that NUL.txt is identical to NUL.





0 reviews
iGuRu.gr