Windows Environment Variables: Use Commands to Access Folders

%appdata%

You can use a command to get to specific system directories. This can save your time: you can use these as shortcuts to get to these locations in File Explorer. The following are the instructions on how to use these variables, and, more importantly, what variables you can use.

1. How to use these variables

There are two ways you can use the environment variables:

#1: The Run box

Step 1: Press the Win and R keys on your keyboard.

Step 2: Enter the command you want to use.

A File Explorer window will open, and you’ll be at the location your command specifies.

#2: The address bar in File Explorer

Step 1: Open File Explorer (Win and E on your keyboard)

Step 2: Enter the command you want to use in the address box.

This should brings you to the location your command specifies

Now let’s look at what variables you can use.

2. The Windows environment variables list

Here is a list of environment variables you can use:

Note: The following locations assume that your system drive is the C drive.

VariablesLocations
%systemdrive%
%homedrive%
Your system drive (C:\)
%systemroot%
%windir%
C:\Windows
%programfiles%C:\Program Files
%programfiles(x86)% C:\Program Files (x86)
%commonprogramfiles%C:\Program Files\Common Files
%commonprogramfiles(x86)%C:\Program Files (x86)\Common Files
%userprofile%
%homepath%
Your user folder (C:\Users\{your username})
%appdata%C:\Users\{your username}\AppData\Roaming
%localappdata% C:\Users\{your username}\AppData\Local
%temp%C:\Users\{your username}\AppData\Local\Temp
%public%C:\Users\Public
%programdata%
%allusersprofile%
C:\ProgramData
%onedrive%C:\Users\{your username}\OneDrive

These should give you shortcuts, and with the Run box or File Explorer, you can quickly navigate to the locations they lead to.

Spread the love