winget upgrade --id Microsoft.PowerShell

sudo dpkg -i powershell_<version>.deb After installation, restart your PowerShell session and run:

brew upgrade powershell Or download the latest .pkg from the GitHub releases page. Using apt with Microsoft repository:

How To Update Power Shell May 2026

winget upgrade --id Microsoft.PowerShell

sudo dpkg -i powershell_<version>.deb After installation, restart your PowerShell session and run: how to update power shell

brew upgrade powershell Or download the latest .pkg from the GitHub releases page. Using apt with Microsoft repository: winget upgrade --id Microsoft