PowerShell, a robust command-line shell and scripting language developed by Microsoft, serves as a powerful tool for system administrators and IT professionals. Its capabilities extend from automating mundane tasks to managing complex configurations efficiently. With PowerShell, users can streamline administrative processes, execute intricate scripts, and interact with various system components seamlessly. The need to check PowerShell versions arises from the constant evolution of features and security enhancements, ensuring users harness the full potential of this indispensable tool in the Windows environment. Regularly verifying and updating PowerShell guarantees optimal performance, empowering users to stay ahead in system administration and automation tasks.
Find PowerShell in windows
Before diving into version checks, it’s crucial to locate PowerShell on your system. Follow these simple steps:
- Windows 10:
- Press
Win + X
and select “Windows PowerShell” or “PowerShell” from the menu.
- Press
- Windows 11:
- Utilize the search bar and type “PowerShell.” Click on the application when it appears in the results.
3 Ways to Check PowerShell Version in Windows
Now that you’ve found PowerShell, let’s explore three distinct methods to check its version:
Check Your PowerShell Version by The Get-Host command
Using the Get-Host
command is indeed a quick and effective way to find out the version of PowerShell you’re currently using. Simply type the following command in the PowerShell console:
- Open PowerShell:
- Press
Win + X
to open the Power User menu. - Select “Windows PowerShell” or “PowerShell” from the list.
- Press
- Type the Command:
- In the PowerShell console, type the following command:
Get-Host
- In the PowerShell console, type the following command:
- Press Enter:
- Press the
Enter
key to execute the command.
- Press the
- Review the Output:
- Look for the information related to the PowerShell version in the output. The version details are usually displayed along with other host-related information.
Example Output:
Name : ConsoleHost
Version : 7.1.1
In this example, the PowerShell version is 7.1.1.
By following these steps, you can quickly and easily determine the version of PowerShell currently active on your system.
Check Your PowerShell Version by The $host.Version command
You can use the $host.Version
command to check the PowerShell version. Here are the steps:
- Open PowerShell:
- Press
Win + X
to open the Power User menu. - Select “Windows PowerShell” or “PowerShell” from the list.
- Press
- Type the Command:
- In the PowerShell console, type the following command:
$host.Version
- In the PowerShell console, type the following command:
- Press Enter:
- Press the
Enter
key to execute the command.
- Press the
- Review the Output:
- Look for the information related to the PowerShell version in the output. The version details will be displayed.
Example Output:
Major Minor Build Revision
----- ----- ----- --------
7 1 1 0
In this example, the PowerShell version is 7.1.1.0.
By using $host.Version
, you can easily retrieve the version information of the PowerShell host on your system.
Check Your PowerShell Version in the Windows Registry
Method 1: Command-Line Approach
If you prefer a quick and straightforward method to discover your PowerShell version, you can utilize a specific command. Open PowerShell and type the following command:
(Get-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\PowerShell\3\PowerShellEngine -Name 'PowerShellVersion').PowerShellVersion
This command fetches the PowerShell version directly from the Registry, providing you with a rapid result.
Method 2: Registry Editor Exploration
For a more visual approach, you can use the Registry Editor:
- Open Registry Editor:
- Press
Win + R
, typeregedit
, and hitEnter
. - Confirm any prompts to allow changes.
- Press
- Navigate to PowerShell Version:
- In the Registry Editor, locate the following path:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\3\PowerShellEngine
- Click through the folders: Software > Microsoft > PowerShell > 3 > PowerShellEngine.
- In the Registry Editor, locate the following path:
- Find Version Information:
- On the right-hand side, look for a key named ‘PowerShellVersion.’ The corresponding value will indicate your PowerShell version.
This method allows you to visually inspect the Registry entries and confirm the PowerShell version on your system.
Update PowerShell Version
Keeping PowerShell up-to-date is essential for accessing the latest features and security enhancements. Follow these steps to update:
- Windows Update:
- Navigate to “Settings” > “Update & Security” > “Windows Update.”
- Check for updates and install any available updates for PowerShell.
- PowerShell Gallery:
- Run the following command in PowerShell to update modules:
Update-Module -Name PowerShellGet
- Run the following command in PowerShell to update modules:
Conclusion
In the dynamic landscape of Windows operating systems, understanding and managing your PowerShell version is a key aspect of maintaining system proficiency. With the insights gained from this guide, you’re now equipped to seamlessly find, check, and update PowerShell on both Windows 10 and Windows 11.
By regularly staying on top of PowerShell updates, you ensure that your system is optimized for efficiency and security. Unleash the full potential of PowerShell and elevate your Windows experience to new heights.