---
title: "How to Change Default Shell In Ubuntu"
description: "Here's a simple command that you can use to change shells. It's useful to work with multiple shells at a time."
url: https://srinimf.com/2021/10/18/heres-the-top-command-to-change-shells-in-ubuntu-quickly/
date: 2021-10-18
modified: 2026-10-10
author: "Srini"
image: https://i0.wp.com/srinimf.com/wp-content/uploads/2021/10/pexels-photo-6084078.jpeg?fit=1880%2C1253&ssl=1
categories: ["Shell scripts"]
tags: ["Change Shells in Linux"]
type: post
lang: en
---

# How to Change Default Shell In Ubuntu

Here’s the command to change default shell. Changing default shell in the Ubuntu (Linux) operating system is a little tricky.

You can manage many shells in a single system. The only thing you need to ensure is path for each shell should be different.

**What is a path?**

In Ubuntu, the / tells the root directory. If you give $cd /, you can see the directory changed to root.

The directory name appended to** / **is a path to that directory. Best example is **/srini/bannu/vasu.**

- [Shell Script Tricky Question – Duplicate Functions](https://srinimf.com/2021/10/09/shell-script-tricky-question-duplicate-functions/)

## Check shells present in your system

Here is a screen from the actual Ubuntu system. Just display all shells using cat command from/etc/shells

![How to see the shells present in your system](https://i0.wp.com/srinimf.com/wp-content/uploads/2021/10/bash.jpg?resize=730%2C393&ssl=1)

## Current Shell

Firstly, you need to identify the current shell. Then, type $ echo $SHELL. It prints the default shell. In this case, it’s already pointed to bash.

- [How to Write a Script in UNIX](https://srinimf.com/2017/11/01/ksh-script-steps-to-create-awesome-way/)

### Change Default Shell

The next step is to chang

Related[A Step-by-Step Guide to Running a Scala Program](https://srinimf.com/2021/09/03/scala-shell-how-to-run-commands-useful-video/)

The next step is to change the shell from bash to ksh. See the screen for how you can do it.
Just type ksh. It switches to ksh shell. You can also do vice versa that means ksh to bash.

![bash to ksh](https://i0.wp.com/srinimf.com/wp-content/uploads/2021/10/ksh-version.jpg?resize=727%2C199&ssl=1)

After changing the shell, just check ksh version. That’s it – [how to](https://srinimf.com/2016/11/03/how-to-select-language-during-creating-dclgen/) change shells.

Related posts

- [How to Run Jobs in Crontab: A Beginners Guide](https://srinimf.com/2022/07/30/crontab-in-ubuntu-the-top-features/)DateJuly 30, 2022
- [How to Set Environment Variables in Linux](https://srinimf.com/2022/03/21/linux-environment-variables-what-to-know/)DateMarch 21, 2022
- [Microland Interview: 2 Tricky Linux Shell Scripts](https://srinimf.com/2023/12/24/microland-interview-2-tricky-linux-shell-scripts/)DateDecember 24, 2023

References

- How to Change Shells in Linux

Get new content delivered directly to your inbox.

Type your email…

Sign up

### Share this:

-
- [Tweet](https://twitter.com/share)
- [![](https://i0.wp.com/assets.pinterest.com/images/pidgets/pinit_fg_en_rect_gray_20.png)](https://www.pinterest.com/pin/create/link/?url=https%3A%2F%2Fsrinimf.com%2F2021%2F10%2F18%2Fheres-the-top-command-to-change-shells-in-ubuntu-quickly%2F&media=https%3A%2F%2Fi0.wp.com%2Fsrinimf.com%2Fwp-content%2Fuploads%2F2021%2F10%2Fpexels-photo-6084078.jpeg%3Ffit%3D1200%252C800%26ssl%3D1&description=How%20to%20Change%20Default%20Shell%20In%20Ubuntu)
-
- [Share on Tumblr](https://www.tumblr.com/share)
- [Share on WhatsApp (Opens in new window) WhatsApp](https://srinimf.com/2021/10/18/heres-the-top-command-to-change-shells-in-ubuntu-quickly/?share=jetpack-whatsapp)
- [More](#)
-

- [Print (Opens in new window) Print](https://srinimf.com/2021/10/18/heres-the-top-command-to-change-shells-in-ubuntu-quickly/?share=print)
- [Share on Reddit (Opens in new window) Reddit](https://srinimf.com/2021/10/18/heres-the-top-command-to-change-shells-in-ubuntu-quickly/?share=reddit)
- [Share on Telegram (Opens in new window) Telegram](https://srinimf.com/2021/10/18/heres-the-top-command-to-change-shells-in-ubuntu-quickly/?share=telegram)
- [Email a link to a friend (Opens in new window) Email](mailto:?subject=%5BShared%20Post%5D%20How%20to%20Change%20Default%20Shell%20In%20Ubuntu&body=https%3A%2F%2Fsrinimf.com%2F2021%2F10%2F18%2Fheres-the-top-command-to-change-shells-in-ubuntu-quickly%2F&share=email)
-

### Like this:

Like Loading…
