Install PowerShell 7 on Windows with winget or the MSI package
In short
- PowerShell 7 installs to a new directory and runs side by side with Windows PowerShell 5.11.
- From the PowerShell 7.6.0 package on, winget installs the MSIX package by default, and --installer-type wix installs the MSI1.
- From the PowerShell 7.7.0 release on, there is no MSI package, and winget only installs the MSIX package1.
- After the install, start PowerShell 7 with the pwsh command or the PowerShell 7 item in the Start menu1.
- winget isn't available on Windows Server 2022 or earlier1.
To install PowerShell 7 on Windows, open a command shell and run winget install --id Microsoft.PowerShell --source winget1. WinGet is Microsoft's recommended way to install it on Windows clients. You can also download and run the MSI package1. PowerShell 7 doesn't replace Windows PowerShell 5.1. It installs to a new folder and runs side by side with it1. Start it with pwsh.
Before you start
PowerShell 7 doesn't replace Windows PowerShell 5.1. It installs to a new directory and runs side by side with it. Some Windows PowerShell modules work in PowerShell 7 through its Windows Compatibility feature, but others still need Windows PowerShell 5.11.
You need WinGet for the main method. It comes with Windows 11, modern versions of Windows 10 and Windows Server 2025 as part of App Installer2. WinGet is supported on Windows 10 version 1809 (build 17763) or later2. It isn't available on Windows Server 2022 or earlier, and Windows Server 2025 includes it only for Windows Server with Desktop Experience1.
Pick a package type. Microsoft recommends WinGet for Windows clients. The MSI package is the best choice for Windows Server and enterprise deployment. The MSIX package is easy for casual users but has limits1.
Steps
Open a command shell. Open Command Prompt, Windows PowerShell or PowerShell. You can run
wingetfrom any of them1.Check the latest version. Search for the PowerShell package by its exact ID1.
winget search --id Microsoft.PowerShell --exactMicrosoft shows this output1:
Name Id Version Source ----------------------------------------------------------------- PowerShell Microsoft.PowerShell 7.6.6.0 wingetInstall PowerShell 7. Run this command. From the PowerShell 7.6.0 package on, winget installs the MSIX package by default1.
winget install --id Microsoft.PowerShell --source wingetOr install the MSI package with winget. Add
--installer-type wixto get the MSI instead1. From the PowerShell 7.7.0 release on, there is no MSI package, and winget only installs the MSIX package1.winget install --id Microsoft.PowerShell --source winget --installer-type wixOr download the MSI yourself. Microsoft's install page links to the latest stable MSI for x64 and Arm64 processors. Download the one for your PC, double-click the installer file and follow the prompts1.
Start PowerShell 7. Run
pwsh, or open PowerShell 7 from the Start menu. The installer creates the Start menu shortcuts1.pwsh
Check it worked
Open the Start menu. You should see an item labeled PowerShell 7. The Windows PowerShell 5.1 entries stay there too, because they are installed with Windows by default1.
In PowerShell 7, check where the session runs from. The $PSHOME variable always points to the directory that holds the PowerShell for the current session1.
$PSHOMEIf the value is $Env:ProgramFiles\PowerShell\7, PowerShell was probably installed with the MSI package. If it starts with $Env:ProgramFiles\WindowsApps\, it was installed with the MSIX package1.
To see whether a newer version is waiting, run this command. If there is an upgrade, the output shows the latest available version1.
winget list --id Microsoft.PowerShell --upgrade-availableCommon problems
winget isn't available. On Windows Server 2022 or earlier, WinGet isn't available. Use the MSI package there1. On a new PC, WinGet appears only after the first sign-in. If you just signed in for the first time, open PowerShell and run Add-AppxPackage -RegisterByFamilyName -MainPackage Microsoft.DesktopAppInstaller_8wekyb3d8bbwe to request its registration2.
Windows asks for elevation. Without administrator rights, some apps need elevation to install. If you choose not to elevate, the install fails2.
Remoting or machine-wide settings don't work. These are limits of the MSIX (Store-based) install. It installs for a single user, doesn't support PowerShell remoting, and doesn't support commands such as Set-ExecutionPolicy -Scope LocalMachine1.
A module doesn't load in PowerShell 7. Some modules work through the Windows Compatibility feature. Others must run in Windows PowerShell 5.11.
Windows PowerShell ISE still runs the old version. Windows PowerShell ISE is a different application. It only works with Windows PowerShell 5.11.
You want a newer version than Microsoft Update offers. Use the same install method you used the first time. Newer versions of PowerShell 7 replace earlier ones1. With winget, run winget upgrade --id Microsoft.PowerShell1.
Questions
- Does PowerShell 7 replace Windows PowerShell 5.1?
- No. PowerShell 7 installs to a new directory and runs side by side with Windows PowerShell 5.1. Some older modules still need Windows PowerShell 5.11.
- How do I update PowerShell 7 later?
- PowerShell 7 supports updates through Microsoft Update. To update sooner, use the same method you installed with. For winget, that is winget upgrade --id Microsoft.PowerShell1.
- Should I pick the MSI or the MSIX package?
- Microsoft calls the MSI the best choice for Windows Server and enterprise deployment. The MSIX package is an easy install for casual users, but it has limits, such as no PowerShell remoting1.
- How do I uninstall PowerShell 7?
- If you installed it with winget, run winget uninstall --id Microsoft.PowerShell. If you used the MSI, remove it in the Programs and Features Control Panel1.
17 Sept 2026: Published.