Install PowerShell on Linux

PowerShell can be installed on several different Linux distributions. Most Linux platforms and distributions have a major release each year, and provide a package manager that's used to install PowerShell. PowerShell can be installed on some distributions of Linux that aren't supported by Microsoft. In those cases, you may find support from the community for PowerShell on those platforms.

For more information, see the PowerShell Support Lifecycle documentation.

This article lists the supported Linux distributions and package managers. All PowerShell releases remain supported until either the version of PowerShell or the version of the Linux distribution reaches end-of-support.

For the best compatibility, choose a long-term release (LTS) version.

Alpine

The following table lists the supported PowerShell releases and the versions of Alpine they're supported on. These versions are supported until either the version of PowerShell reaches end-of-support or the version of Alpine reaches end-of-life.

  • The Supported icon indicates that the version of the OS or PowerShell is still supported
  • The Out of Support icon indicates the version of PowerShell is no longer supported on that version of the OS
  • The In Test icon indicates that we haven't finished testing PowerShell on that OS
  • The Not Supported icon indicates that the version of the OS or PowerShell isn't supported
  • When both the version of the OS and the version of PowerShell have a Supported icon, that combination is supported
Alpine 7.2 (LTS-current) 7.3 7.4 (preview)
Supported 3.15 In Test In Test In Test
Supported 3.14 Supported Supported Supported

Alpine 3.15 is in the process of being tested.

PowerShell is supported on Alpine for the following processor architectures.

Alpine 7.2 (LTS-current) 7.3 7.4 (preview)
All supported versions x64 x64 x64

PowerShell hasn't been tested on Alpine using Arm processors.

For more information, see Install PowerShell on Alpine.

Debian

Debian uses APT (Advanced Package Tool) as a package manager.

The following table is a list of currently supported PowerShell releases and the versions of Debian they're supported on. These versions remain supported until either the version of PowerShell reaches end-of-support or the version of Debian reaches end-of-life.

  • The Supported icon indicates that the version of the OS or PowerShell is still supported
  • The Out of Support icon indicates the version of PowerShell is no longer supported on that version of the OS
  • The In Test icon indicates that we haven't finished testing PowerShell on that OS
  • The Not Supported icon indicates that the version of the OS or PowerShell isn't supported
  • When both the version of the OS and the version of PowerShell have a Supported icon, that combination is supported
Debian 7.2 (LTS-current) 7.3 7.4 (preview)
Supported 11 Supported Supported Supported
Supported 10 Supported Supported Supported

PowerShell is supported on Debian for the following processor architectures.

Debian 7.2 (LTS-current) 7.3 7.4 (preview)
Version 9+ x64 x64 x64

For more information, see Install PowerShell on Debian.

Red Hat Enterprise Linux (RHEL)

RHEL 7 uses yum and RHEL 8 uses the dnf package manager.

The following table is a list of currently supported versions of PowerShell and the versions of RHEL they're supported on. These versions remain supported until either the version of PowerShell reaches end-of-support or the version of RHEL reaches end-of-support.

  • The Supported icon indicates that the version of the OS or PowerShell is still supported
  • The Out of Support icon indicates the version of PowerShell is no longer supported on that version of the OS
  • The In Test icon indicates that we haven't finished testing PowerShell on that OS
  • The Not Supported icon indicates that the version of the OS or PowerShell isn't supported
  • When both the version of the OS and the version of PowerShell have a Supported icon, that combination is supported
RHEL 7.2 (LTS-current) 7.3 7.4 (preview)
Supported 9 Supported Supported Supported
Supported 8 Supported Supported Supported
Supported 7 Supported Supported Not Supported

PowerShell is supported on RHEL for the following processor architectures.

RHEL 7.2 (LTS-current) 7.3 7.4 (preview)
All supported versions x64 x64 x64

For more information, see Install PowerShell on RHEL.

Ubuntu

Ubuntu uses APT (Advanced Package Tool) as a package manager.

The following table is a list of currently supported PowerShell releases and the versions of Ubuntu they're supported on. These versions remain supported until either the version of PowerShell reaches end-of-support or the version of Ubuntu reaches end-of-support.

  • The Supported icon indicates that the version of the OS or PowerShell is still supported
  • The Out of Support icon indicates the version of PowerShell is no longer supported on that version of the OS
  • The In Test icon indicates that we haven't finished testing PowerShell on that OS
  • The Not Supported icon indicates that the version of the OS or PowerShell isn't supported
  • When both the version of the OS and the version of PowerShell have a Supported icon, that combination is supported
Ubuntu 7.2 (LTS-current) 7.3 7.4 (preview)
Supported 22.04 (LTS) Supported Supported Supported
Supported 20.04 (LTS) Supported Supported Supported
Supported 18.04 (LTS) Supported Supported Supported

Only the LTS releases of Ubuntu are officially supported. Microsoft does not support interim releases or their equivalent. Interim releases are community supported. For more information, see Community supported distributions.

PowerShell is supported on Ubuntu for the following processor architectures.

Ubuntu 7.2 (LTS-current) 7.3 7.4 (preview)
All supported versions x64, Arm32 x64, Arm32 x64, Arm32

For more information, see Install PowerShell on Ubuntu.

Community supported distributions

PowerShell can be installed on many distributions of Linux that aren't supported by Microsoft. In those cases, you may find support from the community for PowerShell on those platforms

To be supported by Microsoft, the Linux distribution must meet the following criteria:

  • The version and architecture of the distribution is supported by .NET Core.
  • The version of the distribution is supported for at least one year.
  • The version of the distribution isn't an interim release or equivalent.
  • The PowerShell team has tested the version of the distribution.

For more information, see Community support for PowerShell on Linux.

Alternate installation methods

There are three other ways to install PowerShell on Linux, including Linux distributions that aren't officially supported. You can try to install PowerShell using the PowerShell Snap Package. You can also try deploying PowerShell binaries directly using the Linux tar.gz package. For more information, see Alternate ways to install PowerShell on Linux.