How to Enable “Open Command Window Here” Option in Context Menu in Windows Vista and Later

In Windows Vista and later, if you press <SHIFT> key and right-click on any folder, you get some extra options like “Open Command Window Here”, etc. But if you don’t press the SHIFT key, you don’t get those extra options.

In this tutorial, we’ll tell you how to permanently enable that hidden “Open Command Window here” option in context menu so that it always shows in context menu without any need to press <SHIFT> key.

Simply follow these simple steps:

Advertisement

1. Type regedit in RUN or Start Menu search box and press Enter. It’ll open Registry Editor.

2. Now go to following keys one by one:

HKEY_CLASSES_ROOT\Directory\shell\cmd
HKEY_CLASSES_ROOT\Drive\shell\cmd

Enable_Open_Command_Prompt_Here.png

3. In right-side pane, you’ll get a String value Extended. Delete it and the option will get enabled permanently in folders as well as drives context menus.

PS: If you want to enable this option in Desktop context menu as well, follow the same steps for following key:

HKEY_CLASSES_ROOT\Directory\Background\shell\cmd

Advertisement

Now you’ll always get “Open Command Window Here” option in context menu and you’ll not need to press SHIFT key any more.

Published in: Windows 7, Windows Vista

About the author: Vishal Gupta (also known as VG) has been awarded with Microsoft MVP (Most Valuable Professional) award. He holds Masters degree in Computer Applications (MCA). He has written several tech articles for popular newspapers and magazines and has also appeared in tech shows on various TV channels.

Comments

NOTE: Older comments have been removed to reduce database overhead.

  1. This works superb for Windows 8 as well, especially since they took out the shift + rightclick cmd window in the first place.

  2. Great tip, but for the paranoid among us, can you say whether this change to the registry affects anything other than the โ€œOpen Command Window Hereโ€ context menu option? I ask because the registry entries mentioned in the article sound very generic.

  3. Thanks. This works fantastic in Windows 8. +right-click works as well to add the “Open cmd window here” option to the context menu.

  4. nice tip, but the problem is I don’t even have that “open command window here” in regular way. can anyone tell me why?

  5. Oops! forget to tell you I’m running Windows 7 Ultimate with Administrator (I mean REAL Administrator) privilledge.

  6. Sorry but it’s now fixed. My bad I hold shift and right-click, right on the file I want to run with command line. I should click it on empty space in the folder.

  7. Thank you very much.
    This was very useful and worked fine on W10.
    Just in case I exported the registry keys before changing them.
    Better safe than sorry!
    ๐Ÿ™‚

  8. Great tip! Had forgotten how to do it, and it was too easy! Thanks!

  9. Doesn’t work on windows 10 x64 pro.

    I can’t editing nothings on HKCR\drive\shell\cmd……………..

  10. I’m not able to delete even with administrator privilege.
    On Windows 10 Enterprise 64bit version 1607 build 14393.351.

  11. there is a another solution to this problem on windows 10.
    Press alt+f then release and then press P to open with regular privilege.
    OR
    Press alt+ then release and then press M then release it too and press A to open with Administrative privilege.

  12. Hy,

    on Windows 10 the owner of that key ist ‘Trusted Installer’ and ‘Administrators’ are only allowed to read it.
    If you like to change it, you must take the ownership of this key.
    Than you can give Administrators full access.
    After that done, you should give the ownership back to
    NT SERVICE\TrustedInstaller

    Bye, Frank

Leave a Comment

Your email address will not be published. Required fields are marked *

NOTE: Your comment may not appear immediately. It'll become visible once we approve it.