{"id":503075,"date":"2022-10-23T00:05:00","date_gmt":"2022-10-22T21:05:00","guid":{"rendered":"https:\/\/en.buradabiliyorum.com\/how-to-change-the-default-shell-to-bash-on-macos\/"},"modified":"2022-10-23T00:05:00","modified_gmt":"2022-10-22T21:05:00","slug":"how-to-change-the-default-shell-to-bash-on-macos","status":"publish","type":"post","link":"https:\/\/buradabiliyorum.com\/en\/how-to-change-the-default-shell-to-bash-on-macos\/","title":{"rendered":"#How to Change the Default Shell to Bash on macOS"},"content":{"rendered":"<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_84 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<p class=\"ez-toc-title\" style=\"cursor:inherit\">Table of Contents<\/p>\n<label for=\"ez-toc-cssicon-toggle-item-6a253855450b3\" class=\"ez-toc-cssicon-toggle-label\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #dd3333;color:#dd3333\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #dd3333;color:#dd3333\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/label><input type=\"checkbox\"  id=\"ez-toc-cssicon-toggle-item-6a253855450b3\" checked aria-label=\"Toggle\" \/><nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-1'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-change-the-default-shell-to-bash-on-macos\/#%E2%80%9CHow_to_Change_the_Default_Shell_to_Bash_on_macOS%E2%80%9D\" >&#8220;How to Change the Default Shell to Bash on macOS&#8221;<\/a><ul class='ez-toc-list-level-2' ><li class='ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-change-the-default-shell-to-bash-on-macos\/#From_the_Terminal\" >From the Terminal<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-change-the-default-shell-to-bash-on-macos\/#From_System_Preferences\" >From System Preferences<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/buradabiliyorum.com\/en\/how-to-change-the-default-shell-to-bash-on-macos\/#Bash_on_macOS_Is_Still_Outdated\" >Bash on macOS Is Still Outdated<\/a><\/li><\/ul><\/li><\/ul><\/nav><\/div>\n<h1><span class=\"ez-toc-section\" id=\"%E2%80%9CHow_to_Change_the_Default_Shell_to_Bash_on_macOS%E2%80%9D\"><\/span>&#8220;How to Change the Default Shell to Bash on macOS&#8221;<span class=\"ez-toc-section-end\"><\/span><\/h1>\n<div>\n<img loading=\"lazy\" decoding=\"async\" class=\"type:primaryImage alignnone wp-image-444634 size-full\" data-pagespeed-no-defer=\"\" src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da794546f243.jpg?width=1198&amp;trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Terminal window on a macOS Catalina desktop.\" width=\"650\" height=\"300\"\/><\/p>\n<p>Run &#8220;chsh -s \/bin\/bash&#8221; in a Terminal Window to switch your shell from Zsh to Bash, then restart your Terminal. New terminal windows will open using Bash. You can also change the login shell to Bash in a user&#8217;s advanced options page.<\/p>\n<p><a href=\"https:\/\/buradabiliyorum.com\/en\/category\/download-scripts-themes-apps\/\" data-internallinksmanager029f6b8e52c=\"9\" title=\"Download Scripts &amp; Themes &amp; Apps\" target=\"_blank\" rel=\"noopener\">App<\/a>le is\u00a0<a rel=\"nofollow noopener\" target=\"_blank\" class=\"c-link\" tabindex=\"-1\" href=\"https:\/\/support.apple.com\/en-us\/HT208050\" data-stringify-link=\"https:\/\/support.apple.com\/en-us\/HT208050\" data-sk=\"tooltip_parent\" data-remove-tab-index=\"true\">now using<\/a>\u00a0Zsh as the default shell on macOS.\u00a0We love Zsh, but the trusty old Bash shell is still included with macOS, and you can quickly switch back to Bash if you prefer. Zsh became the default in macOS Catalina.<\/p>\n<p>Zsh is only the default shell on newly created user accounts, so any existing accounts you have on an upgraded\u00a0 Mac will still use Bash by default unless you change it. Each user account has its own default shell preference.<\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"From_the_Terminal\"><\/span>From the Terminal<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>To change a user account\u2019s default shell on macOS, simply run the <code>chsh -s<\/code> (change shell) command in a Terminal window.<\/p>\n<p>Change the default shell to Bash by running the following command:<\/p>\n<pre>chsh -s \/bin\/bash<\/pre>\n<p>You\u2019ll have to enter your user account\u2019s password. Finally, close the Terminal window and reopen it. You\u2019ll be using Bash instead of Zsh.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444627 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da7924c44e87.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Changing the default shell to Bash on macOS Catalina.\" width=\"650\" height=\"135\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Change the default shell back to Zsh by running this command:<\/p>\n<pre>chsh -s \/bin\/zsh<\/pre>\n<p>Enter your password when prompted. After you close the terminal window and reopen it, you\u2019ll be using Zsh.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444626 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da79235d0eb8.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Changing the default shell to Zsh on macOS Catalina.\" width=\"650\" height=\"179\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>You can see a list of included shells you can select by running the following command:<\/p>\n<pre>cat \/etc\/shells<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444630 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da792f9dbe48.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Listing available shells in macOS Catalina's terminal.\" width=\"650\" height=\"276\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"From_System_Preferences\"><\/span>From System Preferences<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>You can also change this option graphically from System Preferences if you prefer.<\/p>\n<p>Head to System Preferences &gt; Users &amp; Groups on your Mac. Click the lock icon and enter your password. Hold the Ctrl key, click your user account\u2019s name in the left pane, and select \u201cAdvanced Options.\u201d<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444623 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da791c0c8c3f.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Opening Advanced Options in Users &amp; Groups on macOS.\" width=\"650\" height=\"244\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>Click the \u201cLogin Shell\u201d dropdown box and select \u201c\/bin\/bash\u201d to use Bash as your default shell or \u201c\/bin\/zsh\u201d to use Zsh as your default shell. Click \u201cOK\u201d to save your changes.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444625 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da79219c40ee.jpg?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Changing the default login shell graphically in macOS Catalina.\" width=\"650\" height=\"565\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<h2 role=\"heading\" aria-level=\"2\"><span class=\"ez-toc-section\" id=\"Bash_on_macOS_Is_Still_Outdated\"><\/span>Bash on macOS Is Still Outdated<span class=\"ez-toc-section-end\"><\/span><\/h2>\n<p>Note that the version of Bash (Bourne Again SHell) included with macOS is still pretty outdated, however. If you run <code>bash --version<\/code>\u00a0 on macOS Catalina, for example, you\u2019ll see that Catalina includes Bash 3.2.57 when Bash 5.0 is the latest version. Newer versions are licensed under the GPLv3 license, while Apple still distributes a version licensed under GPLv2.<\/p>\n<p>In contrast, the version of Zsh (Z shell) included with macOS (check with <code>zsh --version<\/code> ), is Zsh 5.7.2, which is the latest version at the time of Catalina\u2019s release.<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-444631 size-full\" data-pagespeed-lazy-src=\"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da7933c2a2d3.png?trim=1,1&amp;bg-color=000&amp;pad=1,1\" alt=\"Viewing the versions of Bash and Zsh on macOS Catalina.\" width=\"650\" height=\"166\" src=\"\/pagespeed_static\/1.JiBnMqyl6S.gif\" onload=\"pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\" onerror=\"this.onerror=null;pagespeed.lazyLoadImages.loadIfVisibleAndMaybeBeacon(this);\"\/><\/p>\n<p>If you want the latest version of Bash, you can <a rel=\"nofollow noopener\" target=\"_blank\" href=\"https:\/\/itnext.io\/upgrading-bash-on-macos-7138bd1066ba\">install it yourself via Homebrew<\/a>.<\/p>\n<\/div>\n<p><script>\n setTimeout(function(){\n  !function(f,b,e,v,n,t,s)\n  {if(f.fbq)return;n=f.fbq=function(){n.callMethod?\n  n.callMethod.apply(n,arguments):n.queue.push(arguments)};\n  if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';\n  n.queue=[];t=b.createElement(e);t.async=!0;\n  t.src=v;s=b.getElementsByTagName(e)[0];\n  s.parentNode.insertBefore(t,s) } (window, document,'script',\n  'https:\/\/connect.facebook.net\/en_US\/fbevents.js');\n   fbq('init', '335401813750447');\n   fbq('track', 'PageView');\n  },3000);\n<\/script><\/p>\n<blockquote><p><strong><span style=\"color: #ff6600;\">If you liked the article, do not forget to share it with your friends. Follow us on\u00a0<span style=\"color: #ff0000;\"><a style=\"color: #ff0000;\" href=\"https:\/\/news.google.com\/publications\/CAAqBwgKMLG0nwswvr63Aw\" target=\"_blank\" rel=\"nofollow noopener noreferrer\">Google News<\/a><\/span>\u00a0too, click on the star and choose us from your favorites.<\/span><\/strong><\/p><\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\">For forums sites go to <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/forum.buradabiliyorum.com\/\" target=\"_blank\" rel=\"noopener\">Forum.BuradaBiliyorum.Com<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<blockquote>\n<p style=\"text-align: center;\"><strong>If you want to read more like this article, you can visit our <span style=\"color: #ff9900;\"><a style=\"color: #ff9900;\" href=\"https:\/\/en.buradabiliyorum.com\/technology\/\" target=\"_blank\" rel=\"noopener\">Technology category.<\/a><\/span><\/strong><\/p>\n<\/blockquote>\n<p><span style=\"color: black;\"><a style=\"color: #ff9900;\" href=\"https:\/\/www.howtogeek.com\/444596\/how-to-change-the-default-shell-to-bash-in-macos-catalina\/\" target=\"_blank\" rel=\"noopener\">Source<\/a><\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8220;How to Change the Default Shell to Bash on macOS&#8221; Run &#8220;chsh -s \/bin\/bash&#8221; in a Terminal Window to switch your shell from Zsh to Bash, then restart your Terminal. New terminal windows will open using Bash. You can also change the login shell to Bash in a user&#8217;s advanced options page. Apple is\u00a0now using\u00a0Zsh&#8230;<\/p>\n","protected":false},"author":1,"featured_media":503076,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"fifu_image_url":"https:\/\/www.howtogeek.com\/wp-content\/uploads\/2019\/10\/img_5da794546f243.jpg?height=200p&trim=2,2,2,2","fifu_image_alt":"","footnotes":""},"categories":[18],"tags":[],"class_list":["post-503075","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-technology"],"_links":{"self":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/503075","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/comments?post=503075"}],"version-history":[{"count":0,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/posts\/503075\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media\/503076"}],"wp:attachment":[{"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/media?parent=503075"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/categories?post=503075"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/buradabiliyorum.com\/en\/wp-json\/wp\/v2\/tags?post=503075"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}