electron - node.js - ng : file path\ng.ps1 cannot be loaded because running scripts is disabled on this system

You have to set your execution policy to Unrestricted not RemoteSigned. According to Set-ExecutionPolicy:

RemoteSigned. Requires that all scripts and configuration files downloaded from the Internet are signed by a trusted publisher. The default execution policy for Windows server computers.

Since 99% of all PowerShell scripts are unsigned, 99% of the time you will not be able to run them under this policy.

  1. Open PowerShell as Adminstrator.
  2. Run:


Set-ExecutionPolicy -ExecutionPolicy Unrestricted

  • Issue

I face the same issue and after some research I found simply bypass the restriction and launch your app thru ng server.

  • IN TERMINAL you can type below:

PS C:\Users\\\ClientApp> Set-ExecutionPolicy -ExecutionPolicy Bypass -Scope CurrentUser

PS C:\Users\\\ClientApp> ng serve

  • Rerun your app :


Try using "npx ng" instead of "ng". I get the same permissions error if I try using any "ng" command, including "ng new". Using this npm package runner solves it for me.