Change user password in Ubuntu [Compelete Guide]

Learn how to change your Ubuntu password with our easy, step-by-step guide. Secure your system now!

Updated: 30 Apr, 24 by Lisa P 9 Min

List of content you will read in this article:

Ever forgotten your login, only to remember it right after resetting your password? We've all been there. But what if you could easily change your Ubuntu password beforehand, avoiding the potential scramble? This blog post will guide you through different methods for changing your password in Ubuntu, whether you're comfortable using the Settings app or prefer the command line. So, ditch the password panic and keep your account secure!

Need help with your Ubuntu password settings? Our experts cover everything you need to know about the 🛠️ ubuntu default root password.

If you want to know how to change your password in Ubuntu 20.04 using the terminal, here we tell you what to do. Some folks criticize Linux because it relies a lot on the terminal, which can seem tricky at first. But once you get the hang of it, it's a real time-saver. Instead of clicking through menus, you can quickly change the Ubuntu password terminal. Here's How to change the password in Ubuntu 20.04 using the terminal:

  • Press Control + Alt + T on your keyboard to open the terminal.

  • Once the terminal window pops up, type "passwd" and hit Enter.
  • It'll ask for your current password to confirm your identity. Then, you'll be prompted to enter a new password. Type it in.

  • You'll need to type the new password again to make sure you got it right.
  • Hit Enter, and you're all set! Your password is updated.

Now you know How to change password in Ubuntu 20.04 successfully.

Here's how to change a user's password in Ubuntu using GUI:

Press the Windows or Super key to open the Overview, then search for "Settings."

In Settings, scroll down until you find "Users." This is where you'll see all the users on your system.

Before you can make any changes, you'll need to unlock the users. Just use the password of the user currently logged in.

Once you're in the Users section of Ubuntu GNOME settings, choose the user whose password you want to change. Even your main admin account is accessible here. Click on the password field.

Now, select the "Set password Now" option in the dialog box that appears. Type in the new password and confirm it. If you're changing your password, you'll also have to enter your current password.

Remember, when changing the current user's password in Ubuntu, you'll need to type in the existing password too.

When you're all set, click on the "Change" button at the top. That's it! You've successfully updated the user's password in Ubuntu.

Here's how you can reset your password on Ubuntu using recovery mode:

  • Reboot Your Computer: Start by rebooting your computer. When the system starts up, press and hold the Shift key to bring up the GRUB menu. If you're using UEFI instead of BIOS, you might need to hold down the Esc key instead.
  • Access Recovery Mode: In the GRUB menu, select the "Advanced options for Ubuntu" entry and then choose the option that says "recovery mode" or something similar.
  • Enter Root Shell: Once in recovery mode, you'll see a list of options. Choose the one that says "root" to drop into a root shell prompt.
  • Remount Filesystem: Your filesystem will likely be mounted as read-only, so you'll need to remount it as read-write to make changes. Enter the command:

   mount -o remount,rw /

  • Reset Password: Now, you can reset the password for any user by typing:

   passwd username

Replace "username" with the username for which you want to reset the password. Follow the prompts to enter a new password.

  • Restart Your Computer: After resetting the password, type `reboot` to restart your computer. Once it boots up again, you should be able to log in with the new password.

If you're not a fan of changing Ubuntu password terminal, you can easily change your password on Ubuntu using the Settings app. Just follow these steps:

Open the Settings app on Ubuntu. You can find it in the Applications Menu or on the dock.

In the left panel of the Settings app, scroll down until you see the "Users" option. Click on it to open up the user settings.

Once you're in the Users menu, find the "Password" field and click on it.

A window will pop up asking you to confirm your current password. Type it in, and then type your new password in the field below.

When you're finished, click on "Change" to update your password successfully.

That's it! Your password is now updated, all without touching the terminal. Easy, right?

Now, you know how to change password in Ubuntu, but what if you forget your password and can't log in at all? Don't worry, the terminal has a solution for that too. Here's how to change the Ubuntu password without the current password:

Start by restarting your computer from the log-in screen. Click on the power button at the top-right corner and choose "Restart."

While the system is restarting, press the Shift and Esc keys on your keyboard together to access the Grub bootloader menu.

In the bootloader menu, use the arrow keys on your keyboard to select "Advanced options for Ubuntu," then press Enter to enter the Recovery Menu.

In the recovery menu, choose the "root" option and press Enter.

You'll see a command-line interface at the bottom of the screen. Type the following command and press Enter:

mount -n -o remount,rw /  

This command lets you make changes to the root file system, which is necessary for changing the password.

 Now, type "passwd [username]" into the command-line interface, replacing "[username]" with your username in Ubuntu. Press Enter.


 Enter your new password and press Enter. You'll be asked to re-enter it for confirmation.

 If everything goes well, Ubuntu will confirm that your password was updated successfully. Type "reboot" into the command-line interface and press Enter.

 After your computer restarts, you'll see the login screen. Enter your new password, and you're all set.

Changing your password on Ubuntu might seem daunting, but it's pretty straightforward, just like most things in Linux. If you're new to Linux, consider checking out a beginner's guide to get the hang of things. Now you know how to change your Ubuntu password without your current password.

If your Ubuntu password isn't working, it can be frustrating, but there are a few things you can try to resolve the issue:

  • Check for Typos: Make sure you're typing the password correctly. Check for any accidental caps lock or num lock settings that might be affecting your input.
  • Try a Different Keyboard Layout: Sometimes, the keyboard layout might have changed unintentionally. Try typing your password using a different keyboard layout to see if that helps.
  • Use the On-Screen Keyboard: If you suspect a keyboard issue, you can use the on-screen keyboard to input your password. This can help determine if the problem lies with your physical keyboard.
  • Reset Your Password: If you're still unable to log in, you may need to reset your password. You can do this using the methods described earlier, either through the Settings app or via the terminal in recovery mode.
  • Check for Caps Lock in Recovery Mode: If you're resetting your password in recovery mode, be mindful of the caps lock key. It's easy to overlook, and it can cause your new password to be different from what you intend.
  • Consider Data Loss Prevention: If you're unable to reset your password using the methods above and you're worried about data loss, you may need to seek assistance from a professional or consider reinstalling Ubuntu. Be aware that reinstalling will erase any data stored on the system unless you have backups.

If none of these steps work, it might be a more complex issue, and you may need to seek further assistance from the Ubuntu community or a technical support professional.


Forgetting your Ubuntu password can be a frustrating experience, but there are several methods available to reset it and regain access to your system. With these tips in mind, you can navigate password-related challenges with confidence and maintain a secure computing environment on your Ubuntu system. Whether you're a seasoned Ubuntu user or just starting out, familiarizing yourself with the command line offers a powerful and efficient way to manage your system, including changing your password. Remember, a strong password is crucial for maintaining the security of your system. So, embrace the power of the change Ubuntu password terminal, follow these simple steps, and keep your Ubuntu account secure!

Lisa P

Lisa P

Hello, everyone, my name is Lisa. I'm a passionate electrical engineering student with a keen interest in technology. I'm fascinated by the intersection of engineering principles and technological advancements, and I'm eager to contribute to the field by applying my knowledge and skills to solve real-world problems.