As a Windows user, you'll often find the need to add executables and other files to your system PATH. This means you can access them from any location in the command prompt.
Often, program installers will do this for you. For example, the Python installer has a checkbox to add Python to your PATH variable automatically.
In the case you need to manually add to your PATH, here are some simple instructions:
Make/find a folder
You can't directly add files to the PATH variable, only folders. So, start off by finding the folder where your file is located.
If you simply downloaded the file, it's recommended that you make a folder in another location such as your Documents folder.
Get the folder path
By clicking on the "address bar" in the file explorer, you can get the folderβs path.
Navigate to "Advanced system settings"
Right-click on the Windows logo to show a new menu. Choose the "System" option. Once the Settings app opens up, choose the "System info" link.
This will open up a Control Panel page where you can view information about your device, and more importantly, change a few advanced settings. Click the appropriate link to visit that menu.
Once here, click on the button at the bottom to open the Environment Variables menu. With this new menu open, select the PATH variable in the first list and click the Edit button.
Press the New button, paste in the folder path from earlier, and press Enter. Press OK a few times and you're done!
Now that you've added your folder to the PATH variable, any files you add there will be accessible from the command prompt no matter where you are on your computer.
Top comments (0)