PowerShell Executables File System Locations

This page lists the default file system locations of the PowerShell executables on both 32‑bit and 64‑bit Windows. I cover paths to Windows PowerShell versions 1 through 5.1, as well as PowerShell Core / PowerShell 7+ on Windows, Linux, and macOS.

Knowing where PowerShell executables reside is essential for scripting, automation, and troubleshooting across environments.

Do not be confused by the directory name v1.0 — Windows PowerShell stores all versions (1.0–5.1) under this folder for backwards‑compatibility reasons.

Microsoft originally planned to use version‑specific directories, but the idea was abandoned for Windows PowerShell. In PowerShell Core / PowerShell 7+, the directory names finally match the actual version numbers. Click here to learn how to determine your PowerShell version.

This article was originally published some time between 2011 and 2015. Given a makeover in June 2026 to bring it into "today".

Windows PowerShell Executables File System Locations on 64-bit Windows

Note: %SystemRoot% typically resolves to C:\Windows (available as $env:SystemRoot in PowerShell).

Default executable paths for Windows PowerShell and PowerShell ISE on 64‑bit Windows:

Executable type Path
32-bit (x86) PowerShell executable %SystemRoot%\SysWOW64\WindowsPowerShell\v1.0\powershell.exe
64-bit (x64) PowerShell executable %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe
32-bit (x86) PowerShell ISE executable %SystemRoot%\SysWOW64\WindowsPowerShell\v1.0\powershell_ise.exe
64-bit (x64) PowerShell ISE executable %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell_ise.exe

Windows PowerShell Executables File System Locations on 32-bit Windows

Note: %SystemRoot% typically resolves to C:\Windows (available as $env:SystemRoot in PowerShell).

Default executable paths for Windows PowerShell and PowerShell ISE on 32‑bit Windows:

Executable type Path
32-bit (x86) PowerShell executable %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe
32-bit (x86) PowerShell ISE executable %SystemRoot%\system32\WindowsPowerShell\v1.0\powershell_ise.exe

PowerShell Core / 7 File System Location

To locate the PowerShell Core executable (pwsh.exe) on Windows, you can use:


Get-Command pwsh.exe

Example output:

Example of running Get-Command in Windows PowerShell, to find the path to the pwsh.exe executable, in a modern Windows 11 terminal

PS C:\> Get-Command -Name pwsh | Format-Table -AutoSize

CommandType Name     Version Source
----------- ----     ------- ------
Application pwsh.exe 7.6.3.0 C:\Program Files\PowerShell\7\pwsh.exe

PS C:\> $PathToPwsh = (Get-Command -Name pwsh).Source
PS C:\> $PathToPwsh
C:\Program Files\PowerShell\7\pwsh.exe

PS C:\> cd (Split-Path -Parent -Path $PathToPwsh)
PS C:\Program Files\PowerShell\7> 

PS C:\Program Files\PowerShell\7> ls pwsh.*
    Directory: C:\Program Files\PowerShell\7
Mode                 LastWriteTime         Length Name
----                 -------------         ------ ----
-a----         6/10/2026   2:20 AM          84211 pwsh.deps.json
-a----         6/10/2026   2:20 AM         157536 pwsh.dll
-a----         6/10/2026   2:20 AM         301408 pwsh.exe
-a----         6/10/2026   2:20 AM           5024 pwsh.profile.dsc.resource.json
-a----         6/10/2026   2:20 AM          20547 pwsh.profile.resource.ps1
-a----         6/10/2026   2:20 AM            788 pwsh.runtimeconfig.json
-a----         6/10/2026   2:20 AM            617 pwsh.xml

The Longer Story

As of 2020 and onward, PowerShell exists in two major forms: the legacy Windows PowerShell (versions 1–5.1) and the modern, cross‑platform PowerShell Core / PowerShell 7+. PowerShell Core uses the executable pwsh.exe, not powershell.exe.

Windows PowerShell 5.1 is the final version of Windows PowerShell. No new features are being added, and all future development happens in PowerShell Core. PowerShell 7+ is built on .NET Core / .NET 7+, while Windows PowerShell is tied to the .NET Framework.

Click here to see how to list all installed .NET Framework versions - and check out the same project on GitHub for a method for listing installed .NET Core (now just .NET) versions. Nearly half a million downloads from the PowerShell Gallery of that module!

$PSHOME lists where PowerShell was launched from

You can use the PowerShell variable $PSHOME (available in both Windows PowerShell and PowerShell Core / 7) to see the directory from which the PowerShell executable was launched.

Note that $PSHOME points to the installation directory of the PowerShell instance, not the executable file itself.

In PowerShell Core / PowerShell 7, $PSHOME typically looks like this:


PS C:\> $PSHOME
C:\Program Files\PowerShell\7

In Windows PowerShell (1.0–5.1), $PSHOME typically looks like this:


PS C:\> $PSHOME
C:\Windows\System32\WindowsPowerShell\v1.0

Additional PowerShell Core / 7 Notes

PowerShell Core is open‑source and maintained by Microsoft on GitHub: https://github.com/PowerShell/PowerShell

The default installation path is typically:


$Env:ProgramFiles\PowerShell\<version>\pwsh.exe

Note: Early PowerShell Core previews used powershell.exe instead of pwsh.exe, which caused confusion. The rename happened early, but not immediately.

Linux PowerShell Location

On Linux, you can locate PowerShell using which.

On Ubuntu 22.04, the default installation directory is /opt/microsoft/powershell/7/ (as of December 2022).


PS /> which pwsh
/opt/microsoft/powershell/7/pwsh

PowerShell on macOS

When PowerShell is installed via Homebrew (the most common method on macOS), the pwsh executable is symlinked into one of the standard Homebrew binary directories:

- /usr/local/bin/pwsh (Intel Macs)

- /opt/homebrew/bin/pwsh (Apple Silicon)

The actual installation directory is located inside the Homebrew Cellar:

- /usr/local/Cellar/powershell/<version>/

- /opt/homebrew/Cellar/powershell/<version>/

You can verify the active PowerShell executable using the macOS which command, which works the same way as on Linux:


which pwsh

This will show the symlinked path that macOS resolves when you launch PowerShell.

Modules

The default location for shared Windows PowerShell modules is:

$Env:ProgramFiles\WindowsPowerShell\Modules

If you want to reward my efforts

Page generated: 2026-11-11