Skip to contentGo to the directory tree
  1. C:
  2. Windows
  3. System32
  4. WindowsPowerShell\v1.0
FolderRisk: Do not touch

WindowsPowerShell\v1.0 C:\Windows\System32\WindowsPowerShell\v1.0

Windows PowerShell 5.1 installation folder ($PSHOME): powershell.exe, powershell_ise.exe, built-in modules, all-users profiles; the "1.0" is historical.

Updated on By AltF4 Formation

What it’s for

Folder of Windows PowerShell 5.1, the version built into Windows; the $PSHOME variable points to it. The “v1.0” dates from the first release and never changed, which surprises people on 5.1. PowerShell 7 is a separate installation in C:\Program Files\PowerShell\7, with its own $PSHOME.

What it contains

  • powershell.exe and powershell_ise.exe, the type and format files (*.types.ps1xml, *.format.ps1xml) and the help.
  • The Modules subfolder: built-in modules and those of roles and features (ActiveDirectory, Hyper-V, DnsServer, DhcpServer…).
  • The all-users profiles: profile.ps1 (all hosts) and Microsoft.PowerShell_profile.ps1 (console host). They do not exist by default; this is where you create them for every user of the machine.

Risks and best practices

  • The files belong to TrustedInstaller and are serviced by Windows Update: do not modify them, a script copied there gets overwritten by an update.
  • A global profile.ps1 runs for every account, scheduled tasks included: an error in it breaks jobs elsewhere. For customization, prefer the user profile ($PROFILE) or a module.
  • To install your own modules, use C:\Program Files\WindowsPowerShell\Modules, not the Modules folder here.
  • $env:PSModulePath combines three default folders: the user profile, Program Files and $PSHOME\Modules.

Useful commands

Fenêtre de terminal
# Install folder and version of the running engine
$PSHOME
$PSVersionTable.PSVersion
# Profile paths (existing or not)
$PROFILE | Select-Object *
# Module folders in effect
$env:PSModulePath -split ';'

Folder contents

Report a mistake