Replace PowerShell with Command Prompt in Context Menu in Windows 10

Replace PowerShell with Command Prompt in Context Menu in Windows 10: If you have recently updated to Windows 10 latest Creators Update then you may have already notice that when you press Shift and right-click on any folder the option “Open command window here” has been replaced by “Open PowerShell window here.” While many people don’t know what powershell is, how Microsoft is expecting them to use this functionality? Well, that’s why we have put together this guide which will show you how to add the option “Open command window here” in the File Explorer context menu again.

Replace PowerShell with Command Prompt in Context Menu in Windows 10

Also, the option for Command Prompt in Start Menu is replaced by PowerShell with the latest Creators Update but thankfully it can be restored via Windows Settings. But sadly there is no option/settings to replace the “open command window here” option from the right-click context menu on Windows 10. So without wasting any time let’s see how to actually Replace PowerShell with Command Prompt in Context Menu in Windows 10 with the help of the below-listed guide.

Replace PowerShell with Command Prompt in Context Menu in Windows 10

Make sure to create a restore point just in case something goes wrong.

Method 1: Use Registry Fix

Note: If you don’t want to use this method then you could try the method 2 which lets you manually edit the Registry entries in order to fix the issue.

1.Open empty Notepad file and then paste the following text as it is:

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\shell\cmdprompt]
@="@shell32.dll,-8506"
"Extended"=""
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\Directory\shell\cmdprompt\command]
@="cmd.exe /s /k pushd \"%V\""

[HKEY_CLASSES_ROOT\Directory\Background\shell\cmdprompt]
@="@shell32.dll,-8506"
"Extended"=""
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\Directory\Background\shell\cmdprompt\command]
@="cmd.exe /s /k pushd \"%V\""

[HKEY_CLASSES_ROOT\Drive\shell\cmdprompt]
@="@shell32.dll,-8506"
"Extended"=""
"NoWorkingDirectory"=""

[HKEY_CLASSES_ROOT\Drive\shell\cmdprompt\command]
@="cmd.exe /s /k pushd \"%V\""

2.Click File then Save as from the Notepad menu.

From Notepad menu click File then click on Save As

3.From Save as type drop-down select “All Files.

4.Type the name of the file as cmdfix.reg (.reg extension is very important).

From Save as type drop-down select All Files and then type the name of the file as cmdfix.reg

5.Now navigate to the location where you want to save the file and then click Save.

6.Double-click the file then click Yes to continue and this would add the option “Open command window here” in the context menu.

Double click the reg file to run and then select Yes in order to continue

7.Now if you want to remove the “Open command window here” option from the context menu then open the notepad file and paste the below content in it:

Windows Registry Editor Version 5.00

[-HKEY_CLASSES_ROOT\Directory\shell\cmd2]

[-HKEY_CLASSES_ROOT\Directory\Background\shell\cmd2]

[-HKEY_CLASSES_ROOT\Drive\shell\cmd2]

[-HKEY_CLASSES_ROOT\LibraryFolder\Background\shell\cmd2]

8.Select the Save as type as “All Files.” and name the file as Defaultcmd.reg.

9.Click Save and double click on the file in order to remove the option from the context menu. Now, this would Replace PowerShell with Command Prompt in Context Menu if not then continue to the next method.

Method 2: Manually create registries entries

1.Press Windows Key + R then type regedit and hit Enter to open Registry Editor.

Run command regedit

2.Navigate to the following registry path:

HKEY_CLASSES_ROOT\Directory\shell\cmd

3.Right-click on the cmd folder and then click on Permissions.

Right-click on the cmd folder and then click on Permissions

4.Now under the Security tab click the Advanced button.

Now under the Security tab click the Advanced button

5.On Advanced Security Settings window click Change next to Owner.

click Change under Owner

6.From Select User or Group window again click Advanced.

select user or a group advanced

7.Now click Find Now and then select your user account from the list and then click OK.

Click Find Now on the right-hand side and select the username then click OK

8.Once you have added your user account then check mark “Replace owner on subcontainers and objects.

Once you have added your user account then check mark Replace owner on subcontainers and objects

9.Click Apply followed by OK.

10.You will again be taken to the Permissions window, from there select Administrators and then under permissions check mark Full Control.

Select Administrators and then under permissions check mark Full Control

11.Click Apply followed by OK.

12.Now inside the cmd folder, right-click on the HideBasedOnVelocityId DWORD, and select Rename.

Right-click on the HideBasedOnVelocityId DWORD, and select Rename

13.Rename the above DWORD to ShowBasedOnVelocityId, and press Enter.

Rename the above DWORD to ShowBasedOnVelocityId, and press Enter

14.This would enable the “Open command window here” option as soon as you close the Registry Editor.

15.If you want to revert back then simply rename the DWORD again to HideBasedOnVelocityId. Again check and see if you are able to successfully Replace PowerShell with Command Prompt in Context Menu in Windows 10.

How to remove Open PowerShell window here from the context menu in Windows 10

Even though following above steps seems to bring back the “Open command window here” option in the right click context menu but you would still see the “Open PowerShell window here” option and in order to remove it from the context menu follow the below-listed steps.

1.Press Windows Key + R then type regedit and hit Enter.

Run command regedit

2.Navigate to the following registry path:

HKEY_CLASSES_ROOT\Directory\shell\PowerShell

3.Right-click on PowerShell and then select Permissions.

Right-click on PowerShell and then select Permissions

4.Click Advanced button under permission window.

5.On Advanced Security Settings window click Change next to Owner.

click Change under Owner

6.From Select User or Group window again click Advanced.

select user or a group advanced

7.Now click Find Now and then select your user account from the list and then click OK.

Click Find Now on the right-hand side and select the username then click OK

8.Once you have added your user account then check mark “Replace owner on subcontainers and objects.

Once you have added your user account then check mark Replace owner on subcontainers and objects

9.Click Apply followed by OK.

10.You will again be taken to the Permissions window, from there select Administrators and then under permissions check mark Full Control.

Select Administrators and then under permissions check mark Full Control

11.Click Apply followed by OK.

12.Now inside the PowerShell folder, right-click on the ShowBasedOnVelocityId DWORD, and select Rename.

Now inside the PowerShell folder, right-click on the ShowBasedOnVelocityId DWORD, and select Rename

13.Rename the above DWORD to HideBasedOnVelocityId, and press Enter.

Rename the above DWORD to HideBasedOnVelocityId, and press Enter

14.This would disable the “Open PowerShell window here” option as soon as you close the Registry Editor.

15.If you want to revert back then simply rename the DWORD again to ShowBasedOnVelocityId.

Recommended for you:

That’s it, you have successfully Replace PowerShell with Command Prompt in Context Menu in Windows 10 but if you still have any queries regarding this article then please feel free to ask them in the comment’s section.

2 thoughts on “Replace PowerShell with Command Prompt in Context Menu in Windows 10”

  1. Is it possible to control whether w7+ selects the filename _and_ extension or just the filename when a right click, “Rename” is clicked in the context menu? I’d like to be able to control this. Thanks. Mike

  2. Thank you for information.

    For now, it appears that this is more work, and involves more risk, than I want to pursue today.

    Leave it to M$ to make it so complicated to regain a feature that I have used for years before they decided I “should” not want to use it.

    The notion of “personal computing” brung them to the dance. Now, they seem to discourage non-conformity.

Leave a Comment

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