How to switch between CMD and PowerShell in Windows Terminal

tutorial
How to switch between CMD and PowerShell in Windows Terminal

When starting Windows Terminal, the default shell that opens is Windows PowerShell. However, Windows Terminal supports many applications that have a command-line interface, including the venerable Command Prompt (CMD). If you want to switch to CMD in Windows Terminal, or if you want to make CMD the default shell for Windows Terminal, here’s how to do it:

Advertisement

NOTE: This tutorial applies both to Windows 10 and Windows 11. In Windows 11, Windows Terminal is the default application for command-line tools and shells. If you have Windows 10, and the application isn’t installed by default, you can get it for free from the Microsoft Store. Read more here: How to get the Windows Terminal app.

Changing the shell in Windows Terminal using the keyboard

In order to change the shell in Windows Terminal, you first need to launch the program. By default, Terminal starts with a single tab, Windows PowerShell. However, you may find yourself in a situation where the commands you need to input are for Command Prompt, so you need to switch shells. The most straightforward method to change to CMD is by using keyboard shortcuts. Press Ctrl + Shift + 2 while the Terminal window is in focus. This opens a new tab with the Command Prompt shell.

The default keyboard shortcut for opening CMD in Windows Terminal

The default keyboard shortcut for opening CMD in Windows Terminal

You can now close the first tab and start working using CMD. To close the first tab, click on the X button next to the Windows PowerShell tab name.

After opening CMD, you can close the other tabs

After opening CMD, you can close the other tabs

TIP: If you are not very technical and want to know more about shells, terminals, and consoles, I highly recommend this article: What's the difference between a console, a terminal, and a shell?

Advertisement

Changing the shell in Windows Terminal using the application menu

After opening Windows Terminal, click or tap on the button that looks like a V located in the top part of the window, next to the current tab. This opens the Terminal menu. In this menu, choose Command Prompt.

Open a Command Prompt tab by using the Windows Terminal menu

Open a Command Prompt tab by using the Windows Terminal menu

This action opens a new tab with the Command Prompt shell. Now close the first tab by pressing the Close tab (X) button next to the Windows PowerShell tab name.

Starting Windows Terminal with CMD or Windows PowerShell

If you prefer, you can start Windows Terminal directly with the shell you need. To do this, press the Start button and then type “windows terminal” to search for the application. Do not press Enter, instead look for the desired shell in the right pane of the search results list. Click or tap on one of the options and Windows Terminal loads the shell you selected.

Use the Search feature to start Terminal with the shell of your choice

Use the Search feature to start Terminal with the shell of your choice

TIP: For more information, read How to use Search in Windows 11.

How do I set CMD as the default instead of PowerShell in Windows Terminal?

If you use Command Prompt or any other shell apart from Windows PowerShell, you can change your default shell in Terminal. This means that the chosen shell opens automatically each time you start Windows Terminal.

To set CMD as default instead of PowerShell in Windows Terminal, press the button that looks like a V in the top part of the Terminal window. Then, choose Settings.

How to access the Windows Terminal Settings

How to access the Windows Terminal Settings

On the next screen, make sure that Startup (the icon with a screen and an arrow) is selected in the left pane. If the left pane isn’t visible, click on the hamburger button (Open navigation) in the upper left corner of the window.

Advertisement

Now go to Default Profile on the right side and click on the button below it.

Click on the button in the Default profile section of Startup

Click on the button in the Default profile section of Startup

This opens a drop-down list where you can select the desired shell. Click on Command Prompt, then click on the Save button located in the lower right corner of the window.

Choose CMD as the default shell and press Save

Choose CMD as the default shell and press Save

You can do this for any of the installed shells. The next time you start Windows Terminal, it will automatically open a window with Command Prompt (or the shell that you selected).

Do you use Windows PowerShell or Command Prompt? Which one do you prefer?

Command Prompt has been around since the early eighties. It is still our favorite command-line tool, but Windows PowerShell has more functionality, more compatibility, and more connectivity, so it’s clearly a better choice for the future. What command-line tool do you use more often? Also, which of the two did you set as the default for Windows Terminal? We’d love to hear your thoughts in the comment section.

Discover: Productivity Apps CMD PowerShell Recommended Tutorials Windows