How to Add Menu Items Under the Right-Click or Context Menu

This tutorial explains how to add programs to the right-click menu.

Note: I will be adding a link for or a DOS prompt since that is what was specifically requested, but any application can be added in similar fashion.

Right-click on File:.

    -Open regedit. (Go to Start\Run; type regedit.)
    -Expand until you are in HKEY_CLASSES_ROOT\*\shell.
    -If the key ‘shell’ does not exist, right-click on * and add a new key. Name it “shell.”
    -To add the item, right-click on shell, and create a new key. The name of this key will be what appears in the menu. I named mine “cmd.”
    -Next, right-click your newly created key, and create another key under it named “command.”
    -Double-click the default entry in this folder, and type in command.exe.
    -(If you are doing a different program, you would do the complete path to that program instead of command.exe.)
    Now, when you right-click on a file, the option to open a command prompt will be there.

Right-click on Folder addition:

    (I realize there is a tech-recipe for this already, but now it is all in one place.)
    -Open regedit.
    -Expand until you are in HKEY_CLASSES_ROOT\Folder\shell.
    -If the key ‘shell’ does not exist, right-click on Folder and add a new key. Name it “shell.”
    -To add the item, right-click on shell, and create a new key. The name of this key will be what appears in the menu. I named mine “cmd.”
    -Next, right-click your newly created key, and create another key under it named “command.”
    -Double-click the default entry in this folder, and type in command.exe.
    Now, when you right-click on a folder, the option to open a command prompt will be there.

Enjoy addition of any program you wish.
As always questions may be sent to

-William. ยง (marvin_gohan)

The Conversation

Follow the reactions below and share your own thoughts.

27 Responses to “How to Add Menu Items Under the Right-Click or Context Menu”

  1. December 10, 2008 at 11:30 am, misha said:

    Thank you.


  2. July 01, 2009 at 6:35 am, Hobsyllwin said:

    Oh thank you so much, this is what i was searching.


  3. August 04, 2009 at 3:07 pm, Anonymous said:

    It was useful. However I couldn’t add another where parameters needed to be passed in:
    1. I added “mvn clean install” as a key to shell
    2. I added “command” as a new key
    3. Under value for this key i added the command I usually run on dos prompt
    mvn clean install -Dmaven.test.skip=true

    It keeps presenting browse dialog and asks me to select the app to use to run.


  4. September 30, 2009 at 7:29 pm, Name said:

    The right-click on window configuration is under HKEY_CLASSES_ROOTDirectory


  5. November 22, 2009 at 3:23 am, Name said:

    how do i add icons to the menus? please email me at


  6. February 12, 2010 at 11:50 pm, Anonymous said:

    this is all over the internet if you just found this out its simple for me there are usful to people like me to find out what registry keys are/do and to find out how we use it in programs

    1. This is not a HACK
    2. This is not an Easter egg
    3. Dont be suprised


  7. March 06, 2010 at 5:27 am, Anonymous said:

    Thank is great Tut. Now i wounder how i pass on the file name information onto my pointed program. I will appreciate any helping idea.


  8. March 10, 2010 at 12:55 pm, Ghis said:

    thx;) I’ve been looking for this. I’ve already made the key for the item I needed.

    Windows Registry Editor Version 5.00

    [HKEY_CLASSES_ROOT*shellEdit with Gimp]

    [HKEY_CLASSES_ROOT*shellEdit with Gimpcommand]
    @=”"C:\Program Files\GIMP-2.0\bin\gimp-2.6.exe” “%1″”



    • March 10, 2010 at 11:28 pm, TheRealSatan said:

      thx Ghis;)

      I finally found something that works.

      Can you make one that copy a pic from the browser and send it directly to any photo editor (instead of copy/cut/paste+open editor+paste/from/clipboard ?)

      this would be great if you can do this and as easy to put to work as that key you made!! ;) )


  9. March 24, 2010 at 4:08 pm, tesh said:

    hey dude…i am trying to add “Play with VLC” in context menu…when i do that and select a “.rar” file it only plays the first rar…rather than playing the entire movie which is the case when u select Open with VLC. dunno why it wont play the entire movie…wierd any suggestiosn ?


  10. July 22, 2010 at 11:27 pm, kas1943 said:

    How can we ADD Advanced Find (Ctrl-Shift-F) to a right Click Context Menu in Outlook 2007. Specifically, when I place Mouse Mounter over an Outlook Folder, I want to Right Click and have Advanced Find Option like in Outlook 2003.


  11. February 17, 2011 at 6:06 pm, Sre said:



  12. February 27, 2011 at 6:19 am, Richard Greens Boult said:

    Using windows 7: Within Picasa, I want to add a right click option to use an EXIF/IPTC/Metadata editor. Damned if I can find out how to do it. any ideas ?


  13. March 06, 2011 at 5:30 am, Dnlray2020 said:

    Thanks a lot that was so helpful of you.


  14. July 16, 2011 at 9:36 pm, Guest Vest said:

    nice info, thanks


  15. August 10, 2012 at 6:20 am, Farid said:

    what if i like to make some child of “cmd”. Means i have more then one options and i like to add to right click menu, so i like to add them in such a way. that i will make a parent option to right click menu and then add all others as child,
    Please give me a quick response …. thanks in advance.


  16. October 20, 2012 at 4:50 pm, gurudev said:

    Thank you,was searching for a way to add a “dos prompt” item to the right click menu of folders ;i knew the registry had to be modified ;just did not know which key to create or modify as messing with registry can be disasterous.this post helped .


  17. January 02, 2013 at 10:41 am, casino online said:

    I absolutely love your blog.. Excellent colors & theme.
    Did you build this amazing site yourself? Please reply back as I’m hoping to create my own personal site and want to learn where you got this from or exactly what the theme is named. Cheers!


  18. January 05, 2013 at 6:20 pm, Builder said:

    Thank you. I have been waiting to find a way to do this for a long time. Your explanation was easy.


    • January 06, 2013 at 12:53 am, David Kirk said:

      You are welcome. Thanks for the kind words.


  19. May 01, 2013 at 4:32 am, Raul said:


    I would like to create an option in my context menu that allows me to open a link with internet explorer. I have set Firefox as default browser but I have certain type of links that I need to open with IE.
    Is that possible?



  20. June 21, 2013 at 3:38 pm, Ian said:


    I found I already had one existing for ‘Open with SublimeText’ and learned it needs to take an argument for the file name. For example ‘Open with Canary’ command needs to know what file or it will just open Chrome Canary but not open the file you right clicked on.

    C:\Users\lotus\AppData\Local\Google\Chrome SxS\Application\chrome.exe “%1″

    Now my default browser is Chrome but for new devtools I can right click and open a html page with Canary :-)


  21. June 25, 2013 at 3:19 am, safiyullah said:

    it not working at just displaying the given string key value


  22. July 22, 2013 at 12:03 am, azzzzz said:

    when this added key will work? i closed the regedit but the new menu does not show.


  23. August 17, 2013 at 1:26 am, mojtaba said:

    Hi. How can I send path of the folder that I right click on it to the program that will be execute as an arguman.Tnx with big regards


  24. November 30, 2013 at 9:15 am, darkgener said:

    a million thanks


  25. March 01, 2014 at 6:10 pm, Vlad said:



Leave a Reply