Not sure which PowerShell version you're running? One command gives you the exact version of your open session. Windows PowerShell and PowerShell 7 install alongside each other, so start with the window you want to check.
Run the quick version check
In your open PowerShell window, run $PSVersionTable.PSVersion by typing it and pressing Enter. The result shows the PowerShell engine version used by that session.
For a version number on a single line, run $PSVersionTable.PSVersion.ToString().
If the command fails, try it in Windows PowerShell opened through Start, using the steps below.
Open Windows PowerShell from Start
Search Start for Windows PowerShell. To check the separate 32-bit host where it's installed, search for Windows PowerShell (x86) instead.
Launch your chosen result by selecting Open.
Run $PSVersionTable.PSVersion to check that session's engine version.
Repeat these steps with the other search result to check both hosts separately.
Understand why two windows show different versions
Two windows running different PowerShell installations report their own version numbers.
PowerShell 7 installs alongside Windows PowerShell 5.1 without replacing it. Run $PSVersionTable.PSVersion in each session to check them separately.
For more detail, run $PSVersionTable.
Read PSVersion for the engine version. The PSEdition entry distinguishes Desktop from Core.
Don't mistake PSCompatibleVersions for a list of installed versions. Your running engine's version is under PSVersion.
Check PowerShell 7 directly
From a command shell, run pwsh -Version. It prints the version of the executable the command finds, then exits. The shorter command pwsh -v does the same thing.
That result identifies one executable. To check a particular side-by-side installation, launch pwsh.exe from that installation's directory.
Run $PSVersionTable.PSVersion in the window that opens.
If pwsh -Version fails because the executable isn't found, try launching pwsh.exe from its installation directory as described above. If PowerShell 7 isn't installed, follow Microsoft's PowerShell installation instructions.
Choose the right profile in Windows Terminal
In Windows Terminal, open the profile dropdown using the down arrow beside +. With the default keyboard bindings, Ctrl+Shift+Space opens the same dropdown.
Select the PowerShell profile you want to check. Profile names are customizable. The default shortcut Ctrl+Shift+1 opens the first configured profile, which isn't always PowerShell.
Run $PSVersionTable.PSVersion to confirm the engine version in that tab.
Repeat the check in the Windows PowerShell and PowerShell 7 profiles when both are installed. Each result describes only its own session.
Use Command Prompt without switching windows
Already working in Command Prompt? Check Windows PowerShell from that window using the command below. Its quotation marks are written for Command Prompt.
Run powershell.exe -NoProfile -Command "$PSVersionTable.PSVersion". It launches Windows PowerShell, prints the engine version, and exits.
Don't substitute powershell.exe -Version. That parameter selects an engine version to start; it doesn't report the installed version.
For PowerShell 7, run pwsh -Version.
Frequently Asked Questions
Can I use Get-Host or $Host.Version to check PowerShell?
Both report the host's version. In embedded or third-party hosts, that isn't necessarily the engine version. Use $PSVersionTable.PSVersion for an unambiguous engine check.
Can WinGet show which PowerShell versions are installed?
Run winget list PowerShell and read the Version column. Available shows an available update, not the installed version. The results aren't a complete inventory: portable ZIP copies aren't reliably included, and WinGet doesn't reliably inventory built-in Windows PowerShell.
Does the same version command work on macOS and Linux?
Yes. In a PowerShell 7 session, run $PSVersionTable.PSVersion. From another command shell, use pwsh -Version when pwsh is on PATH, or invoke the executable by its full path with -Version.
Do I need to change execution policy to check my version?
No. The basic version check requires no execution policy changes, Windows Terminal settings changes, or PowerShell 2.0 activation.