Share via

How do I get Microsoft Code to come up in my right click menu?

William Thompson 125 Reputation points
2024-08-26T16:41:43.1866667+00:00

When I right button click on a folder in Windows Explorer, the option to launch that new and empty folder in Microsoft Visual Studio Code is not available to me as it appears in a youtube tutorial like so. How do I get it there as a menu option If I have this helpful IDE already installed?

Visual-Studi-Code-in-Menu

Developer technologies | Visual Studio | Setup

2 answers

Sort by: Most helpful
  1. Tianyu Sun-MSFT 34,826 Reputation points Microsoft External Staff
    2024-08-27T03:10:50.09+00:00

    Hello @William Thompson,

    You can run the setup.exe file again, but this time check following two options

    Add "Open with Code" action to Windows Explorer file context menu

    Add "Open with Code" action to Windows Explorer directory context menu

     User's image

    Click Next to modify the settings and wait for it finishes. After that you should see the "Open with Code" option in your right-click menu.

    BTW, right-click menu is a little different in Windows 11. If you are using Windows 11, you might see it("Open with Code" option) like following

    User's image

    User's image

    Feel free to let us know if you have any further concerns :D

    Sincerely,

    Tianyu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

    2 people found this answer helpful.

  2. aH 10 Reputation points
    2025-08-12T19:54:19.1233333+00:00

    Method 1: Use VS Code Installer to Repair

    Close VS Code if it’s open.

    Download the latest VS Code installer from https://code.visualstudio.com/.

    Run the installer and choose Repair (or reinstall).

    This usually restores the right-click context menu options.


    Method 2: Enable "Open with Code" from VS Code settings

    Open VS Code.

    Press Ctrl + Shift + P to open the Command Palette.

    Type Shell Command: Install 'code' command in PATH and select it.

    Restart your computer.

    Note: This mostly helps with command line, but sometimes also restores integration.

    Shell Command: Install 'code' command in PATH., NOT VISIBLE

    If “Shell Command: Install 'code' command in PATH” is NOT visible in your VS Code Command Palette, it usually means:

    You are on Windows (this command mostly appears on Mac/Linux).

    Or you might have a custom VS Code installation missing this.


    Method 3: Add "Open with Code" to right-click manually (for Windows)

    You can add it manually via registry or using VS Code’s built-in command:

    Open VS Code as administrator.

    1. Press Ctrl + Shift + P, type and select Shell Command: Install 'code' command in PATH.
    2. Then run this command from your terminal: Method 1: Use VS Code Installer to Repair Close VS Code if it’s open.
        **Download the latest VS Code installer** from [https://code.visualstudio.com/.](https://code.visualstudio.com/)
      
           Run the installer and choose **Repair** (or reinstall).
      
                 This usually restores the right-click context menu options.
      
      Method 2: Enable "Open with Code" from VS Code settings Open VS Code.
        Press `Ctrl + Shift + P` to open the Command Palette.
      
           Type **Shell Command: Install 'code' command in PATH** and select it.
      
              Restart your computer.
      
      Note: This mostly helps with command line, but sometimes also restores integration. Shell Command: Install 'code' command in PATH., NOT VISIBLE If “Shell Command: Install 'code' command in PATH” is NOT visible in your VS Code Command Palette, it usually means: You are on Windows (this command mostly appears on Mac/Linux).
        Or you might have a custom VS Code installation missing this.
      
      Method 3: Add "Open with Code" to right-click manually (for Windows) You can add it manually via registry or using VS Code’s built-in command: Open VS Code as administrator. Press Ctrl + Shift + P, type and select Shell Command: Install 'code' command in PATH.
      1. Then run this command from your terminal: if nothing works the regedit you have to use, which code you find below: https://artisthindustani.blogspot.com/2025/08/method-1-use-vs-code-installer-to.html?spref=pi
    1 person found this answer helpful.

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.