How to Change PowerShell Execution Policy in Windows 10
How to Change PowerShell Execution Policy in Windows 10
to execute a custom or downloaded PowerShell script, it will throw the “Script cannot be
loaded because running scripts is disabled on this system” error. E-Mail address
Subscribe
This error happens because of the Restricted execution policy. In order to execute scripts, you
need to set different execution policy. In case you are wondering, here’s how to change the
PowerShell execution policy in Windows 10.
Jump to:
Now, even though an execution policy can block certain configuration files or scripts from
running, the policies are not a security measure. In fact, they can be easily bypassed. In
Microsoft words, execution policies are just basic rules. These rules prevent you from
unintentionally violating the policies.
Now that you know what the execution policies actually mean, follow the below steps to
change PowerShell execution policy in Windows 10. The blow steps work in Windows 7 and
Windows 8 too, no matter the PowerShell version.
2. The first thing you need to do is to check the current execution policy. That way, you will
know whether you need to change the execution policy or not. So, execute the below
command and PowerShell will instantly tell which execution policy is currently active. As you
can see, in my case, it is Restricted.
Get-ExecutionPolicy
3. To change or set the execution policy, execute the below command. Of course, if you’d like
to use some other execution policy, replace RemoteSigned with the name of other execution
policies.
Note: If you are regular home or power user who wishes to execute custom or downloaded
PowerShell scripts, I’d recommend you go with the RemoteSigned execution policy.
RemoteSigned execution policy offers a good balance between basic security and ease of use.
Set-ExecutionPolicy RemoteSigned
4. As soon as you execute the above command, you will be asked to confirm your action. Type
A in the PowerShell window and press Enter to confirm the execution policy change.
5. To verify the policy change, execute the Get-ExecutionPolicy cmdlet again and you should
see it return RemoteSigned.
If you like this article, do check how to zoom in and out in PowerShell and how to run
PowerShell scripts on schedule in Windows 10.
How to Enable PowerShell Scripts How to Disable PowerShell How to Find Out Windows
Execution on Windows 10 Completely on Windows 10 (GPO) Update Size via PowerShell in
Windows 10
AMNA
MAY 28, 2021 AT 4:06 PM
what to do if it says
C:\Windows\system32>Get-ExecutionPolicy
‘Get-ExecutionPolicy’ is not recognized as an internal or external command,
operable program or batch file.
Reply
BASHKARLA
MAY 28, 2021 AT 5:55 PM
You should execute it in PowerShell. You can open PowerShell by searching for it in the
Start menu.
Reply
Leave a Comment
Type here..
Website
Post Comment »