

How to Elevate Privileges in Windows Terminal (Image Credit: Russell Smith)

Here’s how to elevate Windows Terminal to run with administrator privileges:

If you are signed in to Windows with a standard user account, launching Windows Terminal using ‘Run as administrator’ doesn’t work. The first account created in Windows is always a Protected Administrator unless your organization has changed the default configuration. Or an administrator account that isn’t protected by UAC (not recommended). I.e., an administrator account that is protected by User Account Control (UAC). This method only works if you are signed in to Windows 10 with a Protected Administrator account. The first method for elevating privileges with Windows Terminal is to run the app as an administrator. But for developers and system administrators who would like to elevate privileges in Windows Terminal, there are a couple of workarounds. “If you had an elevated commandline running in an unelevated window, an untrusted bad actor could execute an elevation-of-privilege attack by driving the unelevated windows that’s running the elevated commandline.”Īnd that has also led to conversations on developing a Unix-style sudo command for Windows to a dead-end. Mike Griese, a software engineer at Microsoft working on the Windows Terminal and the Windows command line experience, says that because of the way Windows is architected: So, elevating privileges in Windows Terminal tabs isn’t on Microsoft’s roadmap. But Microsoft has determined there is a risk, albeit small, that hackers could weaponize elevated tabs to compromise Windows. Users have called for Microsoft to allow tabs in Windows Terminal to optionally run with elevated privileges. But because of the way Windows Terminal is developed and packaged, there are some challenges when it comes to elevating privileges. Windows Terminal is delivered by Microsoft as a packaged app through the Microsoft Store and on GitHub in MSIX format.
