How to Get PowerShell Version with These Easy Commands

As a patch of light Orion’s sword finite but unbounded the only home we’ve ever known white dwarf To ensure scripts and modules work as expected when managing IT environments, you need to get PowerShell version information. Checking your version prevents issues when deploying scripts and ensures alignment with system requirements.

This guide shows you simple commands to get PowerShell version information, helping you maintain an efficient, reliable environment and support consistent, high-quality operations. 

How to check PowerShell version

Each new version of PowerShell comes with improved features, performance, and security. There are several ways to check which version of PowerShell you’re using. 

Here’s a step-by-step approach to each and when it makes sense to use them: 

The $PSVersionTable command

Using the $PSVersionTable command directly queries the PowerShell engine. This command provides critical details like PSEdition and Platform, while other commands may show only host versions. It gives you a clear breakdown of the version and features available, which helps confirm compatibility before rolling out any scripts. Note: Some older versions of PowerShell may still be installed and will not show Platform information.

This immediately below is PS5, it does not contain Platform. You can have multiple versions of PS installed on one computer. PS7.4.6 is the most up-to-date version and may not be the version that opens with the WIN+R command provided. 

Dialogue box of Windows PowerShell prompting users to install the latest powershell features

This is how you can open whatever version is latest and installed on the computer

Win + R > pwsh.exe > Enter

Here’s how it works:

  1. Open PowerShell from the start menu or by pressing Win + R, typing PowerShell, and hitting enter.
  2. Type $PSVersionTable and press enter
  3. You’ll see a table displayed in the console. Look for the PSVersion field, which shows the exact version number of the PowerShell engine you are currently running. 

The $PSVersionTable command also works across Windows, Linux, and macOS.

$PSVersionTable command box


The Get-Host and | Select-Object Version commands

The Get-Host | Select-Object Version command helps verify that your setup matches what you need for troubleshooting or ensuring compatibility with your current tools. It’s a quick step to keep things aligned and working efficiently.

When you use | Select-Object Version, you narrow the output to display only the “Version” property. Instead of seeing a full set of details, you’ll get just the version number. 

Open PowerShell (step 1 above), type Get-Host | Select-Object Version and press enter.

Keep in mind that this version refers to the interface or environment where PowerShell runs. It’s different from the version of the core engine itself.

Windows Registry

If you don’t have direct access to PowerShell, you can check the PowerShell version through the Window Registry. This method works well for situations where scripts need to align with specific compliance requirements or internal policies. It’s also helpful when confirming consistency across devices, ensuring automation scripts perform as expected. This reliable approach helps you manage multiple systems while maintaining the compatibility your organization depends on for seamless operations.

1. Open the Registry Editor

  1. Press Win + R to bring up the Run dialog box.
  2. Type regedit and hit enter. This opens the Registry Editor.
  3. If a User Account Control prompt appears, select Yes to proceed.

2. Navigate to the PowerShell Registry key

Within the Registry Editor, locate the following path using the navigation pane on the left:

HKEY_LOCAL_MACHINE

SOFTWARE

Microsoft

PowerShell

3

PowerShellEngine

NOTE: the below screenshot is from a computer with both PS5 and PS7 installed. This Registry entry is only partially accurate. It may be easier to omit this path as the Registry has changed a lot with Window 10 and 11. This shows “a” version of PowerShell, but not all versions of PS.

Registry editor entry showing powershell version

3. Find the PowerShellVersion key

Once inside the PowerShellEngine folder, look in the right-hand pane. Locate a key labeled PowerShellVersion. The value displayed here tells you the installed PowerShell version. This approach allows you to verify version details stored at the system level. Use precaution when working in the registry, as changes can affect how your system operates.

Checking remotely

If you’re remote monitoring and managing multiple systems, here’s a quick and efficient way to check compatibility and ensure everything is up-to-date:

  1. Open PowerShell on your local machine. This will be your starting point for running commands. 
  2. Enable remote management by running the Enable-PSRemoting command on the target machines. 
  3. Use the following command to query the remote computer, replacing <ComputerName> with the name of the computer you’re targeting: Invoke-Command -ComputerName <ComputerName> -ScriptBlock {$PSVersionTable.PSVersion}

After running the command, you’ll see the PowerShell version installed on the remote system.

Note: The above guidance is specifically relevant for devices connected on the same network. The steps   would be different than what we would offer via Syncro, but does work for intra-office type functions.

For instance, “$PSVersionTable” works fine through Syncro, but our partners would have to write the output to a Custom Field or in the output file in PowerShell.

How to update to the latest PowerShell version

Here’s how to install the latest version of PowerShell based on your preferred method and platform:

Via GitHub

Visit the PowerShell GitHub releases page to find the installer that matches your system’s architecture (x64 or x86). Download the appropriate MSI package, run the file, and follow the instructions displayed during setup. Once installed, open a new PowerShell session and use $PSVersionTable to confirm the updated version.

Using Microsoft Store

Search for PowerShell in the Microsoft Store under Developer Tools. Install it directly from there to enable automatic updates. New versions will be installed as they become available.

Using Winget

Type winget install Microsoft.Powershell in a terminal, and the latest version will be downloaded and installed. This approach is efficient for those comfortable with command-line interfaces.

Direct Microsoft Download (they have to choose download version). This is the same as the GitHub repository but from Microsoft’s documentation page so it gives the reader more context.

OS-specific instructions

Windows

After installation through any method above, open a new PowerShell session to ensure the latest version is in use. 

macOS

For macOS users, Homebrew makes updates simple: 

  1. Run brew update
  2. Next, type brew upgrade powershell
  3. Confirm the installation by entering pwsh –version in your terminal.

Linux

Update PowerShell using your package manager. 

For Debian-based systems, run sudo apt-get update and sudo apt-get install -y powershell. Then, confirm the update by entering pwsh –version.

On Red Hat-based systems, use sudo yum update powershell followed by sudo yum install -y powershell.

How to get PowerShell version with Syncro

You can automate PowerShell updates using Syncro’s scripting tools. This involves creating a script that runs the right commands to update PowerShell using methods like GitHub installation or Winget.

Once your script is ready, deploy it across multiple systems using Syncro’s automation features. This ensures client devices stay current with the latest PowerShell version. Syncro’s ability to handle remote tasks efficiently helps you maintain systems with less manual effort, saving time while improving consistency.

Keeping PowerShell updated brings you the latest features, improved performance, and stronger security for your IT systems. Syncro lets you automate this task, saving time and ensuring uniformity across all your managed systems. 

Looking for a simpler way to manage IT and increase efficiency? Explore what Syncro can do for you with a free trial.

PowerShell versions FAQ

What’s the difference between Windows PowerShell and PowerShell Core?

Windows PowerShell works specifically within Windows, leveraging its unique features and tools. PowerShell Core works with macOS, Linux, and Windows. This makes it a great option if you’re managing a mix of environments and need tools that work well everywhere.

Why does the Get-Host command show a different version than $PSVersionTable?

The Get-Host command shows the version of the PowerShell host application. This is different from the engine version you’ll see in $PSVersionTable since each represents a separate part of how PowerShell is set up.

What is PowerShell ISE?

The Windows PowerShell Integrated Scripting Environment (ISE) is a Microsoft product that simplifies and improves your PowerShell experience. You can write, test, debug scripts, and run commands in one place. With features like multiline editing and syntax highlighting, your scripting process becomes easier and more efficient. 

The ISE also lets you execute specific sections of code and receive helpful, context-aware suggestions as you work. It also provides support for languages written from right to left.