How to change the default shell in Windows Terminal
You may not know it, but there is a piece of code in the settings file of Windows Terminal that decides which shell to open first (the default shell). Thus, by customizing this code, you can change the default shell attached to Windows Terminal, including Command Prompt, Ubuntu (Linux) or Azure Cloud Shell.
To get started, open the 'Start' menu, search for 'Windows Terminal' and click on the corresponding application in the results.
How to change the default shell in Windows Terminal Picture 1
Next, click the down arrow icon at the top of the Windows Terminal window, then select 'Settings'.
How to change the default shell in Windows Terminal Picture 2
Windows will ask you with which application you want to open the settings file. You can choose any code (or plain text) editor from the list, but we recommend using Notepad for simplicity. Please click 'Notepad' in the list and press 'OK'.
How to change the default shell in Windows Terminal Picture 3
When the settings file opens in Notepad, scroll to the shell section that you want to set as default. There is a heading at the top of each section that tells what each particular shell is used for.
For example, the section of PowerShell says 'Make changes here to the powershell.exe profile'. Similarly, the section of the Command Prompt says 'Make changes here to the cmd.exe profile'. The part of Ubuntu has the keyword 'Ubuntu' to the right of the 'name'.
Now copy the text next to 'guid' in the shell you want to select. You don't need to copy both the quotes. Just copy the text inside the quotes, as shown below:
How to change the default shell in Windows Terminal Picture 4
Next, you scroll to the top of the settings file and find the 'defaultProfile' text field. Delete the text next to this field and paste the text you copied above here by pressing Ctrl + V.
How to change the default shell in Windows Terminal Picture 5
Now, click File > Save in Notepad to save the changes.
How to change the default shell in Windows Terminal Picture 6
The shell you selected now becomes the default shell in Windows Terminal.
You should read it
- Windows Terminal will soon become the default terminal emulator in Windows 11
- Notable changes in Windows Terminal ver 0.11
- How to Change Default Folder in Windows Terminal
- How to customize Windows Terminal application
- Windows Terminal is about to have a retro version with a 'classic' interface.
- How to make Windows Terminal the default Terminal application and its benefits
- Microsoft released Windows Terminal with many interesting advantages
- How to delete the user and the machine name in the command prompt on Terminal
- Set up Windows Terminal to always open with Command Prompt on Windows 11
- How to set Windows Terminal to always open with Command Prompt on Windows 11
- How to enable transparent background on Windows Terminal
- How to reset Windows Terminal to default settings on Windows 10
May be interested
How to set up child control on Windows 10
How to fix Windows 10 failure to update error KB5003173
How to Change Default Folder in Windows Terminal
Windows 10 1809 and 1909 officially discontinued support
How to take screenshots, annotate images with Snip & Sketch on Windows 10
How to Factory Reset Windows 10 PC with Command Prompt