What is root on Linux?

If you click our links and make a purchase, we may earn an affiliate commission. Learn more

In most cases, the term “root” on Linux refers to the system administrator account. “root” is the username for this account (like “administrator” on Windows). The root user has access to everything on the system (files, services, commands, etc.).

Typically, when you install Linux on a computer or Raspberry Pi, the root user is created by default, but not always enabled. You’ll usually create and use another user account (for yourself) that has more limited privileges on the system.

become root on a raspberry pi

Security risks

Root has superuser privileges, which means it has the highest level of access to the system.

This is convenient for system administrators, but can also be harmful, as the slightest wrong command or parameter can break everything. Using the root session directly is also risky in terms of malicious software, as installing it can break the entire system in a flash.

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

For this reason, it’s not recommended to use the root user account directly. Instead, stay with your user account for day-to-day tasks, and only temporarily switch to the root session when necessary.

When connecting to a Linux server or Raspberry Pi via SSH, the root account is often forbidden and it’s not recommended to enable it (always connect as a normal user first).

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

Read more about security here: 17 Security Tips From A Pro To Protect Your Linux Server.

Sudo command

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

In most cases, you don’t even have to use the root session, as all the main distributions are now using “sudo” instead.

Sudo is a command that is prefixed to another command and allows you to temporarily gain root privileges just to run that specific command. This is a safe way to perform tasks that require more privileges than your current user account has.

Lost in the terminal? Grab My Pi Cheat-Sheet!
Download the free PDF, keep it open, and stop wasting time on Google.
Download now

You can easily configure which users can or can’t use sudo, whether a password is required or not, etc. See the linked articles below for more details.

Root directory

Just a quick word about another use of the term “root” that you may find in some tutorials.

The term “root” also refers to the top-level directory of the Linux file system (“/”).


🛠 This tutorial doesn't work anymore? Report the issue here, so that I can update it!

If this project doesn’t work as expected on your setup, don’t worry. You can get help directly from me and other Pi users inside the RaspberryTips Community. Try it for $1 and fix it together.

Related articles

Whenever you're ready, here are other ways I can help you:

Master Linux Commands: Overwhelmed with Linux commands? This book is your essential guide to mastering the terminal. It includes practical tips, real-world examples, and a bonus cheat sheet to keep by your side.

The RaspberryTips Community: Need help with Linux or want to chat with people who actually get it? Join the RaspberryTips Community and get access to private forums, exclusive lessons, and direct support (try it for just $1).

You can also find all my recommendations for tools and hardware on this page.