[Windows 10 Tip] Remove “Open Linux Shell Here” Option from Folder Context Menu

SUMMARY: This tutorial will help you in removing “Open Linux shell here” option from folder context menu (right-click menu) in Windows 10. It’ll also help you in always showing “Open Linux shell here” option in folder context menu without pressing SHIFT key.

If you are using a newer Windows 10 version and you installed and enabled “Windows Subsystem for Linux” (WSL) (also known as Bash on Ubuntu) feature, you might have noticed a new option “Open Linux shell here” in folder context menus (right-click menus).

The new option appears in context menu when you press and hold SHIFT key and right-click on a folder or empty area (white space) in a folder in File Explorer. It’s called extended context menu option which is only shown if SHIFT key is pressed.

Advertisement

Following screenshots show the new “Open Linux shell here” option in folder context menus:

Option appearing when right-clicked on a folder:

Open_Linux_Shell_Here_Directory_Right_Click_Menu_Windows_10.png

Option appearing when right-clicked on empty area in a folder:

Show_Open_Linux_Shell_Here_Option_Folder_Context_Menu_Windows_10.png

Windows 10 displays this new option only if you have activated and enabled WSL feature, otherwise it’s not shown in context menus.

If you are using WSL feature in Windows 10 but don’t want to use this new option in folder context menus, this tutorial will help you in getting rid of this new option.

Advertisement

You can remove the new “Open Linux shell here” option from folder context menu by modifying Windows Registry.

If you also want to delete theĀ  “Open Linux shell here” option from context menu, check out following steps:

1. Press WIN+R keys together to launch RUN dialog box. Now type regedit in RUN and press Enter. It’ll open Registry Editor.

2. Now go to following key:

HKEY_CLASSES_ROOT\Directory

Under “Directory” key, you’ll see following 2 sub-keys:

  • Background
  • shell

The “Background” key also contains “shell” key under it.

Both “shell” keys i.e. “HKEY_CLASSES_ROOT\Directory\Background\shell\” and “HKEY_CLASSES_ROOT\Directory\shell\” contain a sub-key “WSL“.

Remove_Open_Linux_Shell_Here_Option_Folder_Context_Menu_Windows_10.png

WSL is the main key which is responsible for showing “Open Linux shell here” option in folder context menus.

The WSL key present under “HKEY_CLASSES_ROOT\Directory\Background\shell\” key shows the “Open Linux shell here” option when you right-click on empty area in a folder.

The WSL key present under “HKEY_CLASSES_ROOT\Directory\shell\” key shows the “Open Linux shell here” option when you right-click directly on a folder.

3. To remove “Open Linux shell here” option from folder context menu, we’ll need to delete WSL key present under both keys.

Windows 10 will not allow you to delete the key as you wouldn’t have required permissions.

You’ll need to take ownership and full control of “WSL” (and “command” key present under it) to be able to delete it. You can take help of following guides to take ownership of the Registry key:

[Guide] How to Take Ownership (Permission) of a Registry Key in Windows?

[Windows Tip] Take Ownership (Permission) of Registry Keys from Command Line

After taking ownership and full control, delete WSL key.

That’s it. Close Registry Editor and “Open Linux shell here” option will disappear from folder context menus. You can check by pressing SHIFT key and right-clicking on a folder or empty area in a folder and the “Open Linux shell here” option will no longer appear in context menu.

BONUS TIP: Always Show “Open Linux Shell Here” Option

If you don’t want to delete “Open Linux shell here” option in folder context menu but want to always show it in context menu without any need of pressing SHIFT key, delete “Extended” string present in right-side pane of WSL key. Now the option will always appear when you right-click on a folder or empty area in a folder. You’ll not need to press and hold SHIFT key to make the option available.

Also Check:

[Windows 10 Tip] Restore “Open Command Window Here” Option in SHIFT+Right-Click Menu

Published in: Windows 10

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. Be the first one to start the discussion.

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.