how to update powershell Reading Time: 4 minutes

If you manage devices, handle cybersecurity workflows, or build automated scripts, knowing how to update PowerShell is essential for maintaining system security, performance, and compatibility. Outdated versions of PowerShell pose risks—missing features, outdated security modules, and reduced support for modern scripts. Updating PowerShell allows IT managers, security professionals, and business leaders to operate with confidence, ensuring every command runs on a modern, secure shell.

This comprehensive guide explains how to update PowerShell across Windows, macOS, and Linux, why upgrading matters, common issues, and how to verify installation. Whether you’re maintaining enterprise endpoints or optimizing your own machine, this article provides everything you need.

Why Updating PowerShell Matters More Than Ever

PowerShell is now a core automation engine in business environments. Understanding how to update PowerShell ensures you benefit from:

1. Stronger Security

New versions patch exploits, strengthen credential handling, and block dangerous legacy functions.

2. Better Performance

The platform gets faster with nearly every release.

3. Cross-Platform Support (Windows, macOS, Linux)

PowerShell 7+ uses .NET 6/7+, enabling uniform scripting across operating systems.

4. New Modules & Tools

Cloud management, endpoint security, and DevOps pipelines all rely on up-to-date modules.

5. Future-Proof Automation

Legacy Windows PowerShell 5.1 is no longer being enhanced. PowerShell 7+ is where improvements happen.

These advantages highlight why learning how to update PowerShell is a must-have skill for modern IT operations.

Understanding PowerShell Versions (Important Before Updating)

Before jumping into update steps, it’s helpful to know the difference between versions:

Windows PowerShell (5.1 and earlier)

  • Built into Windows
  • Uses the .NET Framework
  • No feature updates—only security updates

PowerShell 7+ (PowerShell Core)

  • Cross-platform: Windows, macOS, Linux
  • Actively developed
  • Better performance and modern scripting
  • Supports parallelization, improved error handling, and cloud compatibility

When updating, you NEVER overwrite Windows PowerShell. You install modern PowerShell side-by-side, keeping both available.

How to Update PowerShell on Windows (Recommended for IT Teams)

Updating PowerShell on Windows can be done in several ways, depending on environment, permissions, and workflow.

Method 1: Update via Windows Store (Fastest & Easiest)

If PowerShell was installed through Microsoft Store:

  1. Open Microsoft Store.
  2. Go to Library from the left panel.
  3. Click Get updates.
  4. Store will automatically update PowerShell to the latest version.

This is the easiest ongoing method because updates install automatically.

Method 2: Update PowerShell Using Winget (Preferred for IT Pros)

Microsoft’s “winget” tool allows instant updates.

To check installed versions:

winget list Microsoft.PowerShell

To update to the latest version:

winget upgrade --id Microsoft.PowerShell

To clean-install (if needed):

winget install --id Microsoft.PowerShell --source winget

Winget is ideal for mass deployment across enterprise environments.

Method 3: Update PowerShell Manually (MSI Installer)

If you prefer manual installation:

  1. Visit the PowerShell install page (no links added as per your rule).
  2. Download the latest PowerShell-7.x.x-win-x64.msi installer.
  3. Run the MSI installer.
  4. Choose:
    • Add PowerShell to PATH
    • Enable PowerShell remoting (optional)
    • Add “Open here” context menu
  5. Finish installation.

You’ll now have the latest version, typically found at:

C:\Program Files\PowerShell\7\

Method 4: Update via PowerShell Script (Automated Environments)

For automated systems, use:

Start-Process msiexec.exe -ArgumentList '/i PowerShell.msi /qn' -Wait

This method is used in enterprise environments with automated deployments or remote devices.

How to Update PowerShell Using PowerShell Itself

Check Your Version:

$PSVersionTable.PSVersion

Install Latest Using PowerShellGet:

(Older method—not always recommended)

Install-Module -Name PowerShellGet -Force
Update-Module PowerShellGet

This updates modules, not the PowerShell executable itself, but is crucial for modernization.

How to Update PowerShell on macOS

PowerShell on macOS is increasingly common for DevOps engineers and cybersecurity professionals.

You can install/update using:

Method 1: Homebrew (Recommended)

Check if PowerShell installed via Homebrew:

brew list --cask powershell

Update to latest version:

brew update
brew upgrade powershell

Run PowerShell:

pwsh

Method 2: Manual PKG Installer

  1. Download the .pkg release from PowerShell distribution page.
  2. Double-click and install.
  3. Launch using pwsh.

How to Update PowerShell on Linux

Most Linux distros support PowerShell via package managers.

Ubuntu / Debian

sudo apt-get update
sudo apt-get install powershell

CentOS / RHEL

sudo yum update powershell

Fedora

sudo dnf update powershell

Arch Linux

sudo pacman -Syu powershell

Linux allows fast updates with very minimal setup.

How to Verify a Successful PowerShell Update

After installation, open PowerShell and run:

$PSVersionTable

Look for:

  • Major version 7 or higher
  • Up-to-date Build and GitCommit values

Additionally, confirm:

which pwsh

or on Windows:

Get-Command pwsh.exe

Best Practices for Updating PowerShell in Enterprise Environments

1. Document Versions

Maintain version baselines for compliance.

2. Test Before Deployment

Run updates in a staging environment.

3. Automate Monitoring

Use endpoint management tools to push updates.

4. Configure Execution Policies Properly

Avoid overly permissive policies like Unrestricted.

5. Secure Your Scripts

Digitally sign internal scripts to prevent tampering.

Working knowledge of how to update PowerShell is vital for IT leaders who oversee fleets of machines and enforce strict governance.

Common Problems and Their Fixes

Problem 1: “pwsh is not recognized”

Add PowerShell to your PATH manually or reinstall.

Problem 2: Update Fails Due to Permissions

Run installer or winget as Administrator.

Problem 3: Execution Policy Blocks Scripts

Use:

Set-ExecutionPolicy RemoteSigned

Problem 4: Modules Not Updating

Clear NuGet cache:

Clear-Host

Then retry.

Problem 5: Old PowerShell Launches Instead of New

Update your shortcuts or use:

pwsh

FAQ: Updating PowerShell

1. Does updating PowerShell remove the older version?

No. Windows PowerShell remains installed. You get multiple versions side-by-side.

2. Is PowerShell 7 better than Windows PowerShell 5.1?

Yes—it’s faster, cross-platform, and more secure.

3. Can I update PowerShell without admin rights?

Only if installed via Microsoft Store. MSI installs require admin privileges.

4. Will my old scripts still work?

Most scripts do, but very old modules may need updating.

5. How often should I update PowerShell?

Every major release (2–3 times per year) for security and performance improvements.

Final Thoughts

Understanding how to update PowerShell empowers you to maintain secure, modern, and efficient workflows across all devices you manage. Whether you’re automating tasks, analyzing security logs, or maintaining enterprise endpoints, keeping PowerShell updated ensures your environment stays stable and future-ready.

Upgrade today and strengthen your organization’s endpoint security strategy.

Boost your endpoint protection and streamline device management with Comodo’s advanced endpoint management and device hygiene platform. Start here.

START FREE TRIAL GET YOUR INSTANT SECURITY SCORECARD FOR FREE