Skip to main content

Software And Utilities

by
Last updated on 2 min read

Your PowerShell scripts won’t run and Task Scheduler refuses to trigger them? I’ve seen this happen when the execution policy is too restrictive. Here’s the fastest way to fix it.

Quick Fix: Run Set-ExecutionPolicy RemoteSigned -Scope CurrentUser in PowerShell as Administrator. Confirm with Y. Then try .\yourScript.ps1 again.

What’s causing this issue?

PowerShell blocks unsigned scripts by default for security. Even in 2026, the default policy remains “Restricted,” which stops all scripts from running. Admins face this too—PowerShell won’t execute .ps1 files until you change the policy to “RemoteSigned” or “Unrestricted.”

How do you fix it step by step?

  1. Open PowerShell as Administrator.

    Hit Win + X, then select Windows Terminal (Admin) or PowerShell (Admin).

  2. Check your current policy.

    Type:

    Get-ExecutionPolicy

    If it shows Restricted, you’ll need to adjust it.

  3. Switch to RemoteSigned (lets local scripts run; downloaded ones need signatures).

    Run:

    Set-ExecutionPolicy RemoteSigned -Scope CurrentUser

    Type Y and press Enter to confirm.

  4. Double-check the change:

    Get-ExecutionPolicy

    You should now see RemoteSigned.

  5. Run your script.

    Head to your script folder:

    cd C:\Scripts

    Execute it:

    .\yourScript.ps1

Still not working? Try these troubleshooting steps

  • Bypass temporarily: Run powershell -ExecutionPolicy Bypass -File "C:\Scripts\yourScript.ps1" from Command Prompt to test once.

  • Unblock the file: If you downloaded it from the internet, right-click the file → Properties → check Unblock → Apply → OK.

  • Check your PowerShell version: Run $PSVersionTable.PSVersion. Anything below 5.1? Upgrade via PowerShell install page. Older versions handle execution policies poorly.

How can you prevent this from happening again?

  • Keep execution policy consistent: Set RemoteSigned in Group Policy for enterprise machines (gpedit.msc → Computer Configuration → Administrative Templates → Windows Components → Windows PowerShell → Turn on Script Execution → Enabled → “Allow local scripts and remote signed scripts”).

  • Sign your scripts: Use Set-AuthenticodeSignature to sign scripts before sharing them. This keeps others from hitting the same policy wall.

  • Use profiles to enforce policies: Add a logon script that runs Set-ExecutionPolicy RemoteSigned -Scope CurrentUser -Force if you manage multiple users.

This article was researched and written with AI assistance, then verified against authoritative sources by our editorial team.
TechFactsHub Desktop & Web Team
Written by

Covering Windows, macOS, browsers, and general tech troubleshooting.

What Address Do You Use For Chase Bank?What Are Benchmarking Reports?