If you’re a fan of tweaking your Windows setup, you often need to run “elevated” or Administrator-level commands. You’re probably used to doing this by running a Command Prompt as administrator, but it’s about to get a lot easier with sudo on Windows.

What Does the sudo Command Do?

Despite the general focus on configuring everything through the Settings apps and easy-to-use configuration wizards on Windows, every once in a while, you still need to type in commands. Many of these won’t work with your standard user account. Instead, you need to run them as an administrator. Requiring administrator permissions is still a relatively new concept in Windows, but it was prevalent for far longer in older operating systems.

It was so prevalent that operating system developers thought about a solution to the problem decades ago. Unix installations had, and still do have, asucommand, which means “switch user.” This would allow you to switch accounts to any other user, but could also let you run as the administrator, or superuser, account of the system by default.

Enabling sudo on Window in the Settings app

This solution worked, but logging in as the administrator to run one command seemed like overkill. As a solution, developers created the sudo command, which means either “switch user and do,” or “superuser do,” depending on various opinions. Long story short, the sudo command lets you easily run one command with elevated privileges—we’ve coveredthe differences between su and sudoif you’re curious.

This means that the sudo command is roughly equivalent to right-clicking on the Command Prompt app, selectingRun as administrator, and running a command, likedo_something. With the help of the sudo command, you don’t need to worry about remembering to run the Command Prompt as administrator. Instead, simply typesudo do_something, and the command will work in exactly the same way.

Enabling sudo on Windows via PowerShell

Which Windows Versions Can Run the sudo Command?

Microsoft is adding the sudo command to Windows 11, and considering that support for Windows 10 is winding down, we don’t expect to see the command coming there anytime soon. At the time of writing, the sudo command is only available for Windows Insider participants (builds 26045 and later), specifically those on the Developer andWindows Canary channels.

Unlike some features that Microsoft tests in these versions, it seems fairly likely that sudo is going to arrive on the operating system soon.

Running a command on Windows via sudo

How to Enable the sudo Command on Windows

Once you’re running a version of Windows that has the sudo command available, enabling it is a simple process. Open theSettingsapp, then selectSystemon the left andFor developersfrom the main area of the window.

Here, scroll down and enable the checkbox that readsEnable sudo.

Enable sudo via the Command Prompt

If you’re more command-line oriented, you may also enable sudo via the Commmand Prompt. Somewhat ironically, this requires you to run an elevated CMD window. Press theWindowskey, type “command,” then right-click onCommand Prompt(orPowerShell) and selectRun as administrator.

In this prompt, run the following command:

How to Use the sudo Command on Windows

After you’ve enabled the sudo command on Windows, it’s simple to use. Simply prepend thesudocommand to any command you’d typically need to run as an administrator, then accept the prompts that follow.

An example from Microsoft uses thenetstatcommand:

This feature may seem a tad unnecessary—and for many people, it is. That said, if you spend your day running command after command on Windows and wish for the simplicity of the sudo command, its addition will make your life easier.

Microsoft seems committed to its implementation of sudo, even going so far as to releasesudo on GitHubas open source. If reading this entices you to learn more about what goes on under the hood in Windows, ensure to take a look at our list ofcommands every Windows user should know.