Magical folders

Although the layout of the Windows folders tree is fairly consistent between Windows versions, there are occasional differences.

For example, the Windows folder might be called:

As another example, the Program Files\Common Files folder is usually called:

On the Files, Folders, Shortcuts page, magical folders are indicated with the "starry folder" icon Magical folder icon. They are "magical" because they adapt automatically to the situation on the target system.

For example, the All Users magical folder maps to:

The most important magical folders in the folder tree are shown in the following table. See Standard folders for a complete list and Typical folder paths for different versions of Windows for examples of the corresponding target paths.

Magical folder Purpose Variable
Target System Root folder on the target system. At installation time, it is set to the Windows Volume volume, i.e., the disk volume (or network share) on which the active version of Windows resides. TARGETDIR
All Users

Root folder for common ("All Users") profile information, i.e., application data, shortcuts, and other information that must be maintained for the system as a whole rather than a particular user.

Shortcuts that must be visible to all users should be stored in its subfolders, for example Desktop, Start Menu, and Start Menu\Programs.

If your product must store system-wide application data, for example presets, templates, etc., it should do so in a product-specific subfolder of Application Data, such as Application Data\<Publisher>\<ProductName>

CommonProfileFolder
Current User

Root folder for Current User profile information, i.e., application data, shortcuts, and other information that is specific to the installing user.

Shortcuts that must be visible only to the installing user should be stored in its subfolders, for example Desktop, Start Menu, and Start Menu\Programs.

If your product must store user-specific application data, for example user preferences or customizations, it should do so in a product-specific subfolder of Application Data, such as Application Data\<Publisher>\<ProductName>

ProfileFolder
Program Files (32-bit)

Root folder for 32-bit application programs and their support files. Your product should be installed in a product-specific subfolder. If your product shares files with your other products, they should go into the Common Files subfolder; if it uses files shared with other parties (including system files), they normally go into the Windows\System (32-bit) folder elsewhere in the tree.

Any files stored under Program Files (32-bit) and its subfolders should be considered to be read-only. Do not store application data or user documents that must be written or updated in this part of the folders tree.

Instead, use a subfolder under one of the Application Data folders in the All Users or Current User subtrees for any application data that may be modified (and rewrite your application to access the data there), and store user documents by default into Current User\My Documents.

ProgramFilesFolder
Program Files (64-bit)

Root folder for 64-bit application programs and their support files. Your product should be installed in a product-specific subfolder. If your product shares files with your other products, they should go into the Common Files subfolder; if it uses files shared with other parties (including system files), they normally go into the Windows\System (64-bit) folder elsewhere in the tree.

Any files stored under Program Files (64-bit) and its subfolders should be considered to be read-only. Do not store application data or user documents that must be written or updated in this part of the folders tree.

Instead, use a subfolder under one of the Application Data folders in the All Users or Current User subtrees for any application data that may be modified (and rewrite your application to access the data there), and store user documents by default into Current User\My Documents.

ProgramFiles64Folder
Program Files (native)

Root folder for native application programs and their support files, that is, for any programs that are neither 32-bit nor 64-bit (such as pure CLR applications). Your product should be installed in a product-specific subfolder. If your product shares files with your other products, they should go into the Common Files subfolder.

Any files stored under Program Files (native) and its subfolders should be considered to be read-only. Do not store application data or user documents that must be written or updated in this part of the folders tree.

Instead, use a subfolder under one of the Application Data folders in the All Users or Current User subtrees for any application data that may be modified (and rewrite your application to access the data there), and store user documents by default into Current User\My Documents.

ProgramFilesXFolder
Temp Temporary files folder, used to store scratch files during installation and removal. If you store any files here, you should not rely on them to still be present after the next system restart; on many Windows systems, utilities clean up the Temp folder each time the system starts. TempFolder
Windows

Root folder for the Windows user files. It contains a number of subfolders for the Windows system and program files; on any actual Windows system, these subfolders may or may not be physical subfolders of the Windows folder.

For example, some Windows configurations store the system files (System32 subfolder) on a shared network volume, even though the Windows folder itself is always located on a local disk.

WindowsFolder
System (16-bit) Folder for 16-bit system DLLs; only used on Windows 95, 98, Me System16Folder
System (32-bit) Folder for 32-bit system DLLs and programs, and parent for subfolders such as device drivers. SystemFolder
System (64-bit) Folder for 64-bit system DLLs and programs, and parent for subfolders such as device drivers. Only used on 64-bit Windows systems. System64Folder
System (native) Folder for native system DLLs and programs, and parent for subfolders such as device drivers. This folder is equivalent to System (32-bit) when installing on a 32-bit system, and equivalent to System (64-bit) when installing on a 64-bit system. SystemXFolder

Related topics

File, Folder, Shortcut, Mobile File, Mobile Folder, Mobile Shortcut, Installing Files, Installing Shortcuts, Working with project pages