How Regedit Displays System Environment Variables
This article explains how the Windows Registry Editor (Regedit) displays and structures system environment variables located under the Session Manager key. It covers the specific registry path, the visual column layout within the tool, the underlying data types used for different values, and how Regedit handles variable expansion compared to the standard Windows user interface.
The Registry Location
System-level environment variables are permanently stored in the Windows Registry at the following path:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Environment
When you navigate to this path in the left-hand navigation tree of Regedit, the right-hand pane populates with every global environment variable defined for the operating system.
Visual Display and Columns
Regedit displays these variables in a standard list view consisting of three distinct columns:
- Name: The variable identifier (such as
Path,TEMP,OS, orComSpec). - Type: The underlying registry data type defining how Windows treats the value.
- Data: The actual string, path, or list assigned to the variable.
Value Types Used for Variables
Unlike higher-level Windows configuration panels that abstract data formats, Regedit explicitly displays the exact registry type for each variable. Environment variables under the Session Manager key are represented by two primary types:
REG_SZ(String Value): Used for static text or fixed directory paths that do not contain references to other environment variables (e.g.,NUMBER_OF_PROCESSORS = 8).REG_EXPAND_SZ(Expandable String Value): Used for values that contain variable placeholders enclosed in percent signs, such as%SystemRoot%or%USERPROFILE%. Regedit displays the unexpanded text containing the percent signs in the Data column, rather than resolving the absolute path.
Editing and Propagation Behavior
Double-clicking any variable name in Regedit opens an “Edit String” dialog box where you can modify the variable’s value data.
Modifying environment variables directly within Regedit changes the
raw registry data immediately. However, unlike changing variables via
the System Properties control panel, Regedit does not broadcast a
WM_SETTINGCHANGE message to running applications.
Consequently, active programs will not recognize modified or newly added
variables until the system is restarted or the application is launched
anew from a refreshed process tree.