How to run CMD or PowerShell as administrator, no right clicks required

CMD and PowerShell running as administrator
(Image credit: Tom's Hardware)

For some important tasks in Windows, you need to open the Command prompt and run it as an administrator. For example, if you want to run Diskpart, which allows you to list, create, or delete partitions at the command line, you need to open CMD (aka the command prompt app) as administrator. For some tasks, you may prefer to use PowerShell, which has all the functionality of the Command prompt but adds in advanced scripting capabilities / cmdlets.

When you run CMD as admin, it's called running an elevated Command prompt, because your privileges are elevated. If you are an administrator of your PC -- likely the case if you bought or built your own computer -- your primary user probably has admin rights (if you were issued a corporate computer from work or school, maybe not). You just need to exercise those rights, because by default, neither the command prompt nor PowerShell runs as admin.

How to Run Cmd as Admin Using Right Click

Latest Videos FromTom's Hardware
Avram Piltch
Managing Editor: Special Projects

Avram Piltch is Managing Editor: Special Projects. When he's not playing with the latest gadgets at work or putting on VR helmets at trade shows, you'll find him rooting his phone, taking apart his PC, or coding plugins. With his technical knowledge and passion for testing, Avram developed many real-world benchmarks, including our laptop battery test.

  • Blitz Hacker
    Where I appreciate the knowledge and information, are you sure posting an article on how to run a terminal/console as a SU/admin is a good idea.
    Generally speaking in my experience, if they don't know how to do that on windows, they probably shouldn't be doing -anything- with the admin console
    Reply
  • das_stig
    Agree if you need admin access you would know these shortcuts from Windows 9x days.

    Can only assume somebody was desperate for an article near deadline day and came up this frelling dren!
    Reply
  • apiltch
    das_stig said:
    Agree if you need admin access you would know these shortcuts from Windows 9x days.

    Can only assume somebody was desperate for an article near deadline day and came up this frelling dren!
    Thanks for the feedback and the Farscape reference. We do not have a "deadline day" and I came up with this because I find myself launching an elevated command prompt very often and I don't like having to right click and select "Run as Administrator" every time. It's an extra click when the only reason I ever open command prompt is to do something that requires permissions.

    So I learned how to configure the CMD shortcut so that it always launches as admin with no right click necessary and thought I could take a few minutes to share the details just in case someone else might find them useful. You're right that MOST people know about right clicking to run as admin, but I bet not everyone knows that there's an option to configure CMD to always run as admin without the right click.
    Reply
  • apiltch
    Blitz Hacker said:
    Where I appreciate the knowledge and information, are you sure posting an article on how to run a terminal/console as a SU/admin is a good idea.
    Generally speaking in my experience, if they don't know how to do that on windows, they probably shouldn't be doing -anything- with the admin console
    Many tasks require an elevated command prompt or PowerShell terminal.
    Reply
  • QChronoD
    Typically I run 'cmd' from the address bar in explorer so i don't have to navigate to wherever I am. Too bad the Shift + Crtl + Enter doesn't work there. (it just opens normal version)
    In Win 10, you could Shift + R-click the file menu and it would give options to run terminal or power shell from that folder, but that also seems to have disappeared in Win11
    Reply
  • USAFRet
    QChronoD said:
    Typically I run 'cmd' from the address bar in explorer so i don't have to navigate to wherever I am. Too bad the Shift + Crtl + Enter doesn't work there. (it just opens normal version)
    In Win 10, you could Shift + R-click the file menu and it would give options to run terminal or power shell from that folder, but that also seems to have disappeared in Win11
    That still exists in Win 11. In Pro, at least.
    Reply