Resolve "Cannot be loaded because the execution of scripts is disabled on this system" in PowerShell

Home > Search

This error typically appears when the execution policy on the PC is set to Restricted. Use the Get-ExecutionPolicy cmdlet to view the current execution policy.

PS C:\Users\username> Get-ExecutionPolicy


The Set-ExecutionPolicy cmdlet can be used to set the execution policy. There are 4 execution policies:

  • Restricted
  • Unrestricted
  • AllSigned
  • RemotedSigned
PS C:\Users\username> Set-ExecutionPolicy

PS C:\Users\username> Get-ExecutionPolicy


Add a Comment

We will never share your name or email with anyone. Enter your email if you would like to be notified when we respond to your comment.

Please enter in the box below so that we can be sure you are a human.