When executing a .ps1 PowerShell script, you may encounter an error message stating, “.ps1 is not digitally signed. The script will not execute on the system.”

To resolve this issue, follow these steps:

  • Run the following command to set the Execution Policy using Set-ExecutionPolicy:
Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass

This command specifically adjusts the execution policy to “Bypass” for the current PowerShell session only. Once the PowerShell window is closed, the subsequent sessions will revert to the default execution policy. Setting the policy to “Bypass” essentially allows unrestricted execution without any blocking, warnings, prompts, or messages.

By implementing this change, you ensure that the .ps1 script can be executed without encountering the digitally signed restriction.