Home > How to Tips

(Full Guide) Remove 'The default interactive shell is now zsh.'

Updated on Wednesday, April 24, 2024

iBoysoft author Jenny Zeng

Written by

Jenny Zeng
Professional tech editor

Approved by

Jessica Shee

English

How to Remove 'The default interactive shell is now zsh.' on Mac?

Summary: This post explains what "The default interactive shell is now zsh." on Monterey/Big Sur/Catalina is and three ways to remove the message, including steps to change shell to zsh.

Mac Terminal says that the default interactive shell is now zsh

If you just changed from zsh to bash or updated to macOS Catalina/Big Sur/Monterey, you may receive the message reading "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." whenever you open Terminal.

Apple has changed the default interactive shell from bash to zsh since macOS Catalina. Later macOS versions like macOS Monterey/Big Sur also have the default shell configured to zsh. If your Mac's default shell is still the old bash or you set Terminal to open with bash or other shells when running these operating systems, you will see the warning.

You must be confused if you are unfamiliar with Terminal and the interactive shells. But worry not, we will help you understand the "The default interactive shell is now zsh." message, remove it and change the default interactive shell on Mac if you want.

What does 'The default interactive shell is now zsh.' mean?

There are several interactive shells that interpret and execute the commands we enter in Terminal on Mac. Among them, zsh(Z shell) and bash(Bourne again shell) are used more often.

On macOS Mojave and earlier, bash is the default interactive shell. But Apple has been stuck with version 3.2 of bash(released in 2006) for a long time as new bash versions are licensed under GPLv3, which is restrictive to companies like Apple that sign their own code. I guess that's part of the reason why they want to change the macOS default shell.

Starting from macOS Catalina, zsh replaced bash as the default shell on Mac for it is most compatible with bash and closer to bash's functionality. Apple also embedded a warning in Terminal to remind users who haven't switched to zsh the adjustment and promote the update.

If your user account was created before macOS Catalina, which still has bash as the default shell, or you invoke the bash shell while your Mac is set to use zsh, you will see the message that reads "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." in Terminal.

How to remove 'The default interactive shell is now zsh.'?

If you don't use Terminal that often, you can ignore the message. Otherwise, you can remove "The default interactive shell is now zsh." on Monterey/Big Sur/Catalina with the methods below.

  • Way 1: Change default shell to zsh
  • Way 2: Hide 'The default interactive shell is now zsh.' and continue using bash
  • Way 3: Switch to the bash shipped by Homebrew

You click the button below to share these solutions to your favorite platform.

 

Way 1: Change default shell to zsh

Besides the situations we stated above, you can also encounter "The default interactive shell is now zsh." on Mac when running Python or certain files under the folders in VSCode. If you are ready to embrace zsh as many others have done, you can change default interactive shell on Mac using the command the "The default interactive shell is now zsh." warning suggests. 

Follow the steps below to switch shell to zsh using Terminal:

  1. Open Terminal if you haven't already.
  2. Input the following command and hit Enter.chsh -s /bin/zsh
  3. Type in your password and press Enter again.
  4. Restart your Mac for the change to take effect.

Alternatively, you can change bash to zsh from the Users & Groups preference pane.

How to switch to bash from zsh from System Preferences:

  1. Click the Apple menu > System Preferences > Users & Groups.
  2. Tap on the padlock on the lower left, enter your password, and click Unlock.
  3. Right-click on your account and select "Advanced Options."Click Advanced Options to change default shell on Mac
  4. Choose /bin/zsh from the drop-down menu next to "Login shell."Change default interactive shell to zsh on Mac
  5. Click OK.
  6. Reboot your Mac.

Now that you have managed to change default interactive shell on Mac to zsh, you will no longer receive the messages saying, "The default interactive shell is now zsh."

Way 2: Hide 'The default interactive shell is now zsh.' and continue using bash

If you know the benefits of zsh, such as more customization and smarter auto-completion, but still prefer the familiar bash, you can hide 'The default interactive shell is now zsh.' by adding a line of code(export BASH_SILENCE_DEPRECATION_WARNING=1) to one of the following files: ~/.bash_profile, ~/.profile, or ~/.bashrc.

How to get rid of the notification when the Mac terminal shows 'The default interactive shell is now zsh.':

  1. Open Terminal.
  2. Input the command below and press Enter to add the line to ~/.bash_profile.touch ~/.bash_profile && echo "export BASH_SILENCE_DEPRECATION_WARNING=1" >> ~/.bash_profile

If modifying the ~/.bash_profile didn't do the trick, replace ~/.bash_profile in the code with ~/.profile or ~/.bashrc and rerun the command. Strangely, some users who are already using zsh may also get the warning when opening a new console. In which case, becoming root and adding the line to /etc/profile is more reliable.

Remove "The default interactive shell is now zsh." on Monterey/Big Sur/Catalina:

  1. Open Terminal.
  2. Type in the following command and hit Enter to edit /etc/profile as root.sudo nano /etc/profile
  3. Enter your password and press Enter.
  4. Tap on the down arrow to move the cursor to the line under "# System-wide .profile for sh(1)".
  5. Copy and paste the text below to the line.export BASH_SILENCE_DEPRECATION_WARNING=1Remove the default interactive shell is now zsh message by editting etc profile
  6. Press Control + X, then type "y" to confirm the change.
  7. Press Enter to exit nano.
  8. Close Terminal.
  9. Restart your Mac.

Way 3: Switch to the bash shipped by Homebrew

If you want to use a newer bash and get rid of 'The default interactive shell is now zsh.' on Monterey/Big Sur/Catalina, you can switch to the bash that comes with Homebrew, which doesn't have the code included in Apple's bash to show the warning. After installing Homebrew on Mac, you can use bash in Homebrew, then update to the latest bash(currently 5.1.16).

How to remove "The default interactive shell is now zsh." on Catalina/Big Sur/Monterey by updating bash:

  1. Open Terminal.
  2. Type in the command below and hit Enter to install Xcode.xcode-select --install
  3. Click Install to confirm the installation.
  4. Wait for it to complete.
  5. Input the following command in Terminal and press Enter to install Homebrew./bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
  6. It may take a while for Homebrew to install and update.
  7. If you receive a warning that /opt/homebrew/bin is not in your PATH, copy and paste the command Homebrew suggests and hit Enter to add Homebrew to your PATH.
  8. Run the command below to update bash:brew update && brew install bash && sudo chsh -s /usr/local/bin/bash $(whoami)

Which solution did you choose? Click the button below to share this post with your friends!

 

bash vs. zsh for Mac

Like bash, zsh also derives from the "Bourne" family of shells, so they look similar out of the box. But zsh is more customizable and expandable than bash as you can add new functionalities easily on it and have more choices of plugins.

Zsh is designed to improve user interaction. Therefore, it has many features that either don't exist on bash or work less efficiently on bash, such as autocompletion, syntax highlighting, autocorrection, floating-point arithmetic, and many more. However, bash has the advantage of being the default shell of most Linux machines and servers, for which it is still widely used by programmers.

If you are an average Mac user who uses Terminal once in a while, you can either ignore the message or change shell to zsh as Apple advised. If you work with different platforms where bash is the common shell, you should consider getting an updated bash with Homebrew. If you fall in between, you can suppress the warning and continue using the familiar bash.

FAQ about 'The default interactive shell is now zsh.' on Mac

A

Apple switched the macOS default shell from bash to zsh since macOS Catalina.

A

Apple made the decision to change the default shell on Mac because Mac's bash is stuck at version 3.2 for years while the current latest version of bash is 5.1 and they don't plan to update it as the new version of bash is licensed under the business-unfriendly GPLv3. Zsh has similar functions as bash but is more interactive and customizable than it, so Apple chose to change default shell to zsh.

A

You can chang default interactive shell on Mac using either Terminal or the Users & Groups system preferences pane. For instance, if you want to change zsh to bash on Mac, execute this command: chsh -s /bin/bash in Terminal will do the job. Alternatively, you can open System Preferences > Users & Groups > right-click on your account name > select Advanced Options > choose bin/bash for Login Shell.

A

The quickest way to make zsh your macOS default shell is to execute the command: chsh -s /bin/zsh in Terminal.