I installed PowerShell 7 to test some commands while troubleshooting a Start menu issue. Windows Terminal now shows multiple PowerShell entries, and I'm trying to understand whether they are different PowerShell versions or duplicate installations. Both entries appear to report PowerShell 7.6.1, but one seems to use a path under WindowsApps. I originally installed PowerShell with winget and then also ran the MSI installer because I thought the first installation had not worked. What is the difference between these entries, and which installation should I keep?
3 Answers
Your screenshots may be showing duplicate Windows Terminal profiles rather than two different PowerShell releases. Terminal can create separate profiles for installations from different sources, such as winget, the Microsoft Store, and the MSI package. Open Terminal settings, compare the profile command lines and paths, and delete the duplicate profile you do not want. Since you installed PowerShell through winget and then with the MSI, removing the extra installation should leave one PowerShell 7 profile alongside the built-in Windows PowerShell 5.1.
Windows PowerShell 5.1 and modern PowerShell 7 are different products. The older one is Windows-only and included with the operating system, while PowerShell 7 is newer, open source, and designed to work across Windows, macOS, and Linux. Scripts and modules are often compatible, but not always, so it is normal for both versions to remain installed. You can require a script to run on PowerShell 7 by adding #Requires -Version 7.0 at the top of the .ps1 file.
There are two separate things here. Windows PowerShell 5.1 is built into Windows and remains installed, while PowerShell 7 is the newer, separately installed version. They can coexist and are launched with different executables: powershell.exe for 5.1 and pwsh.exe for 7.x. You can check the version of the session you currently have open with $PSVersionTable.
Also check the executable path with Get-Process -Id $PID | Select-Object Path. That helps distinguish a normal MSI installation from a WindowsApps or Store-based installation.

If both entries report 7.6.1, they are not 5.1 versus 7; they are most likely two PowerShell 7 installations or two profiles pointing to the same version.