To fix “System error 5” in Microsoft Windows, you must run Command Prompt and Windows PowerShell as an administrator. The instructions below will walk you through multiple ways to open both command-line interpreters with elevated rights.
Run Command Prompt and Windows PowerShell as Administrator
Run Command Prompt and Windows PowerShell as Administrator
It’s impossible to run commands in Command Prompt or Windows PowerShell with default user privileges. If the command output results in “System error 5,” you must launch your preferred command-line interpreter as an administrator.
Open Command Prompt as Administrator
Open Windows PowerShell as Administrator
Both Windows 10 and 11 feature the option to open Windows PowerShell as an administrator via the Windows + X (a.k.a. Power User) menu.
Always Run an Elevated Command Prompt and Windows PowerShell Console
Always Run an Elevated Command Prompt and Windows PowerShell Console
It’s possible to build a desktop shortcut in Windows capable of automatically opening Command Prompt or Windows PowerShell as an administrator. That eliminates the chances of mistakenly launching a console with standard user privileges and encountering “System error 5.”
Disable UAC Prompts for Command Prompt and Windows PowerShell
Disable UAC Prompts for Command Prompt and Windows PowerShell
User Account Control (UAC) is a security feature in Windows Vista, 8, 8.1, 10, and 11 that prevents programs from making changes to the system without permission. However, dealing with UAC prompts each time you want to open Command Prompt or Windows PowerShell with admin rights is distractive. The quickest way to deal with that is to disable UAC altogether. However, that poses a significant security risk. Or, you can bypass the prompt only for Command Prompt or Windows PowerShell. That’s safer but takes time to set up.
Disable User Account Control Completely
Bypass UAC for Command Prompt and Windows PowerShell Only
Fix System Error 5 on Standard Windows Accounts
Fix System Error 5 on Standard Windows Accounts
Suppose you encounter “System error 5 has occurred” in a non-administrator account on your PC. In that case, you can still run an enhanced Command Prompt or Windows PowerShell console using the instructions above by inserting an administrator password. If you don’t know it, ask for permission from a user with administrative privileges to the PC. Alternatively, you can change a standard account to an admin account (assuming that you’re the owner of your PC) to avoid having to type in an administrator password each time you want to open a command-line interpreter with elevated rights. The steps below apply to Windows 10 and 11.
Fixed: System Error 5 Has Not Occurred
Fixed: System Error 5 Has Not Occurred
To reiterate, simply running Command Prompt and Windows PowerShell as an administrator will fix the “System error 5” error code in Microsoft Windows. If you use both consoles regularly, taking the time to set up shortcuts that always launch them with elevated privileges (preferably without an annoying User Account Control prompt to deal with) will likely save hours in the long run.