zsh terminal mac 12.0

zsh terminal mac 12.0

Zsh (Z Shell) is the default login and interactive shell for Terminal Application since macOS Catalina, before Catalina the default shell used to be bash (Mojave and before).

How to know which is your current shell on macOS Terminal?

There are multiple ways you can know currently which shell you have been using, the easiest way is by doing an echo command with $0.

% echo $0


How to switch between shells on macOS Terminal?

Switching between shells on macOS Terminal is very easy, just type the shell name that you want to get into and press the return (Enter) key.

code2care@mac ~ % bash

The default interactive shell is now zsh.
To update your account to use zsh, please run `chsh -s /bin/zsh`.
For more details, please visit https://support.apple.com/kb/HT208050.

bash-3.2$ zsh

code2care@mac ~ % ksh
$ zsh

code2care@mac ~ % 

Note: As you move from zsh shell to bash, you will be prompted with a messaging saying "The default interactive shell is now zsh."

How to change the default login shell on macOS Terminal?

Though zsh is the recommended default shell for macOS, if you want to switch to some other shell as a default one, you can do that by following the below steps,

macOS Change the default Login Shell
  • Click on the Apple logo on the Menu - 
  • Now go to System Preferences..,
  • Select Users & Groups,
  • Click on the lock - you will be prompted to enter your username and password,
  • Control + Click on your user-name and select Advanced Options
  • Under login-shell select the shell you want to move to - ksh, bash, csh, tsch etc.
Try Out Code2care Dev Tools:


Code2care is an initiative to publish and share varied knowledge in programming and technical areas gathered during day-to-day learnings and development activities.

Students and software developers can leverage this portal to find solutions to their various queries without re-inventing the wheel by referring to our easy to understand posts. Technical posts might include learnings, tutorials, trouble-shooting steps, video tutorials, code snippets, how-to, blogs, articles, etc.

🎉 We are celebrating the 10th years of Code2care! Thank you for all your support!

We strongly support Gender Equality & Diversity.