Back to Homepage
Wednesday 7 August 2024
22

How to set environment variable in PowerShell

Steps to Set Environment Variable in PowerShell

Need to set an environment variable in PowerShell? Follow these easy steps:

1. Open PowerShell:

  • Press Win + X, then select Windows PowerShell.

2. Set the Environment Variable:

  • Type $env:VariableName = "Value" and press Enter.

3. Verify the Variable:

  • Type echo $env:VariableName to confirm it's set.
Share:
Created by:
Author photo

Jorge García

Fullstack developer