Open Command prompt as administrator

Command Prompt (CMD) is a built-in Windows tool that lets you run commands to troubleshoot problems, manage system settings, check network connections, and repair system files. However, some commands require administrator privileges to make changes to Windows or access protected system resources. If you run these commands in a standard Command Prompt window, you may see an error stating that administrator privileges are required or that access is denied. Windows 11 and Windows 10 offer several ways to do this, including Windows Search, the Run dialog, and the Start menu. Here’s how to open an elevated Command Prompt and run commands with administrative privileges.

1. Run CMD as Administrator Using the Start Menu

The Start menu is one of the easiest ways to open Command Prompt with administrator privileges in Windows 11 and Windows 10. You don’t need to remember any commands or change system settings.

Follow these steps:

  • Press the Windows key on your keyboard to open the Start menu.
  • Type cmd or Command Prompt in the search box.
  • Select Run as administrator from the Command Prompt options. Alternatively, right-click the Command Prompt search result and select Run as administrator.
Run CMD as Administrator Using the Start Menu
  • Click Yes when the User Account Control (UAC) prompt appears.
User account control permission

If prompted, enter the password for an administrator account if you’re using a standard Windows account.

A Command Prompt window will open with elevated privileges. Confirm this by checking the window title, which typically displays Administrator: Command Prompt.

Open CMD as administrator

You can now run commands that require administrator access, such as sfc /scannow or DISM /Online /Cleanup-Image /RestoreHealth.

2. Run CMD as Administrator Using the Run Dialog

The Run dialog lets you launch Command Prompt quickly without navigating through the Start menu. You can also use a keyboard shortcut to open it with administrator privileges.

  1. Press Windows + R to open the Run dialog.
  2. Type cmd in the text box.
  3. Press Ctrl + Shift + Enter instead of Enter.
  4. If the User Account Control prompt appears, click Yes.
CMD as administrator using Run Dialog

Windows will open an elevated Command Prompt window, allowing you to run commands that require administrator permissions.

Tip: Pressing Enter after typing cmd opens a regular Command Prompt. Use Ctrl + Shift + Enter to launch it as an administrator.

3. Run CMD as Administrator Using Windows Terminal

In Windows 11, you can run Command Prompt inside Windows Terminal. Open Windows Terminal with administrator privileges, then switch to a Command Prompt tab. This method is useful if you already use Windows Terminal to run PowerShell or other command-line tools.

  1. Press Windows + X to open the Quick Link menu.
  2. Select Terminal (Admin).
  3. Click Yes if the User Account Control prompt appears.
  4. In Windows Terminal, click the arrow next to the new tab button.
  5. Select Command Prompt from the menu.
Run CMD as Administrator Using Windows Terminal

If Command Prompt isn’t listed, you can type cmd in the Terminal window and press Enter.

The Command Prompt session runs with administrator privileges because you opened Windows Terminal as an administrator.

On Windows 10: You may see Windows PowerShell (Admin) in the Quick Link menu instead. Open it, type cmd, and press Enter to start an elevated Command Prompt session.

4. Run CMD as Administrator Using Task Manager

You can also open Command Prompt with administrator privileges through Task Manager. This method is particularly useful if File Explorer or the Start menu isn’t responding properly.

  1. Press Ctrl + Shift + Esc to open Task Manager.
  2. Click Run new task. In Windows 10, you may need to select File > Run new task instead.
  3. Type cmd in the text box.
  4. Select the option Create this task with administrative privileges.
  5. Click OK.
  6. Approve the User Account Control prompt if it appears.
Run CMD as Administrator Using Task Manager

An elevated Command Prompt window will open, ready to run commands that require administrator access.

Note: If you don’t see the administrative privileges checkbox, make sure you’re using an account with the necessary permissions. On a managed or restricted computer, your organization may also limit access to elevated command-line tools.

5. Run CMD as Administrator Using File Explorer

If you prefer using File Explorer, you can locate the Command Prompt executable and launch it with elevated privileges. This method works in both Windows 11 and Windows 10.

  1. Press Windows + E to open File Explorer.
  2. Navigate to the following folder:

C:\Windows\System32

  1. Find cmd.exe in the folder. You can type cmd.exe in File Explorer’s search box to locate it more easily.
  2. Right-click cmd.exe and select Run as administrator. In Windows 11, you may need to click Show more options first.
  3. Click Yes in the User Account Control prompt.
Run CMD as Administrator Using File Explorer

Command Prompt will open with administrator privileges, allowing you to run commands that require elevated access.

Tip: The cmd.exe file is the executable for Command Prompt. You can use this method whenever you need to launch it directly from its installation folder.

6. Run CMD as Administrator Using Windows Search Keyboard Shortcut

If you prefer keyboard shortcuts, you can open an elevated Command Prompt directly from Windows Search. This is one of the quickest methods when you don’t want to navigate through menus.

  1. Press Windows + S to open Windows Search.
  2. Type cmd in the search box.
  3. Press Ctrl + Shift + Enter.
  4. Click Yes when the User Account Control prompt appears.

Windows will launch Command Prompt with administrator privileges.

This method works in both Windows 11 and Windows 10. It is similar to using the Run dialog, but you can launch CMD directly from the search interface.

Examples of Commands to Run in CMD as Administrator

Many Windows troubleshooting commands require an elevated Command Prompt to work correctly. Here are some common examples and what they do.

CommandWhat It Does
sfc /scannowScans for corrupted Windows system files and attempts to repair them.
DISM /Online /Cleanup-Image /RestoreHealthRepairs the Windows component store used for system maintenance and updates.
chkdsk C: /fChecks the C: drive for file system errors and attempts to fix them.
ipconfig /flushdnsClears the local DNS resolver cache to help troubleshoot certain network problems.
netsh winsock resetResets the Windows Winsock catalog to help resolve some network connectivity issues.

To run any of these commands, open Command Prompt as an administrator, enter the command, and press Enter. Wait for it to finish before closing the window.

Note: Some commands may require a restart or additional steps. For example, chkdsk C: /f may ask to schedule the disk check for the next restart if the drive is in use.

What to Do If You Can’t Run CMD as Administrator

If the Run as administrator option is missing or Command Prompt won’t open with elevated privileges, the issue may be related to your account permissions, User Account Control settings, or organizational restrictions.

Try these checks:

  • Check your account type: Open Settings and go to Accounts > Your info to review your account details. A standard account may require administrator credentials to run elevated commands.
  • Use another administrator account: If your current account lacks administrative rights, sign in with an authorized administrator account and try again.
  • Check whether your device is managed: A work or school computer may have policies that restrict access to Command Prompt or administrator tools. Contact your IT administrator if necessary.
  • Restart your PC: A restart can resolve temporary issues that prevent Windows tools from opening correctly.
  • Use Windows Terminal (Admin): Press Windows + X, select Terminal (Admin) in Windows 11, and open a Command Prompt tab if available.

Remember that opening CMD as an administrator does not automatically fix Windows problems. It simply gives commands the elevated permissions they may need to make system-level changes. Only run commands you understand and trust.

Frequently Asked Questions

1. How do I run CMD as administrator in Windows 11?

Press the Windows key, type cmd, and select Run as administrator from the search results. Click Yes when the User Account Control prompt appears.

2. What is the shortcut to open CMD as administrator?

Press Windows + R, type cmd, and press Ctrl + Shift + Enter. This opens Command Prompt with elevated privileges if your account has the necessary permissions.

3. How do I run CMD as administrator in Windows 10?

Open the Start menu, search for cmd, right-click Command Prompt, and select Run as administrator. Approve the UAC prompt to continue.

4. Why do some CMD commands require administrator privileges?

Some commands need elevated permissions to modify system files, change network settings, manage services, or repair Windows. Running Command Prompt as an administrator provides the required permissions when your account is authorized.

5. Can I run CMD as administrator without an administrator account?

You cannot independently elevate a standard account without authorized administrator credentials. You may need to enter an administrator password or sign in with an administrator account

Steve Ballmer
With over 7 years of experience in the IT industry, I have experience in IT support, helpdesk, sysadmin, network admin, and cloud computing. Certified in Microsoft Technologies (MCTS and MCSA) and also Cisco Certified Professional in Routing and Switching.