![Enable Root User Mac Featured Image](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-featured-image.jpg)
On macOS, certain parts of the file system are unavailable by default, even if you are the administrator. But if you enable the root user on your Mac, you’ll gain read and write privileges to the entire file system. You can even access files of another user’s account, which is perfect if you forget your username or password or an ex-employee leaves your business without sharing the login details for their company-issued macOS device. Follow this tutorial to learn how to enable the root user on macOS.
How to Enable Root User via the Terminal
You can enable root access via your Mac’s terminal.
- To launch the Terminal, either open a new Finder window and navigate to “Applications -> Utilities -> Terminal” or search for “terminal” using Spotlight.
![Enable Root User Mac Terminal Finder](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-terminal-finder.jpg)
- In Terminal, type
dsenableroot
after the “%” symbol and press Enter.
![Enable Root User Mac Terminal User Password](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-terminal-user-password.jpg)
- Your username should come up. Enter your user password at the prompt and press Enter.
- Enter or create your root password and verify it.
- You should see a success message indicating that you have enabled the root user.
![Enable Root User Mac Terminal Enabled](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-terminal-enabled.jpg)
How to Enable Root User Using the Directory Utility
If you prefer to use a GUI-based option to enable the root user on your Mac, use the Directory Utility instead of the Terminal.
- Open your Mac’s Spotlight by clicking the menu bar icon in the upper-right corner of the screen or pressing Command + Space.
- Search for “directory utility” in the Spotlight window, then select the application when it appears.
![Enable Root User Mac Spotlight Directory Utility](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-spotlight-directory-utility.jpg)
- Click on the lock icon in the bottom-left corner of the Directory Utility window.
![Enable Root User Mac Directory Utility Lock](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-directory-utility-lock.jpg)
- Use Touch ID or type your Mac password when prompted.
- Click on “Edit” in the menu bar and select “Enable Root User” from the drop-down.
![Enable Root User Mac Spotlight Directory Utility Edit](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-spotlight-directory-utility-edit.jpg)
- A pop-up will appear requesting your root user password. Create or enter your root user password.
![Enable Root User Mac Spotlight Directory Utility Root User Password](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-spotlight-directory-utility-root-user-password.jpg)
- Click “OK” or press Enter to enable the root user.
Note: you won’t get a prompt alerting you that the root user is enabled.
How to Log In as the Root User
Once it’s enabled, you can log in to the root account from the login screen.
- Log out of your current user account.
- Select “Other” on the login screen.
![Enable Root User Mac Login Screen](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-login-screen.jpg)
- For “username,” enter your username or “root,” then enter the password you created for your root account.
- Log in to the account.
This account may look the same as a regular user account, but it’s now possible to access, edit, and even delete files that would typically be strictly off-limits, so tread carefully!
To avoid accidental damage to your Mac, you should only log in to the root account when you have a task that specifically requires root privileges.
How to Disable the Root User
To help protect your Mac from malicious activities, or even accidental damage, disable root as soon as it’s no longer required.
How to Disable the Root User Using Terminal
- Launch Terminal via Finder (“Applications -> Utilities”) or Spotlight.
- Enter the
dsenableroot -d
command and press Enter.
![Enable Root User Mac Disable Terminal](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-disable-terminal.jpg)
- Enter the password for your current account. You should see a prompt letting you know that the root user has been disabled.
How to Disable the Root User Using Directory Utility
- Launch Directory Utility.
- Click on the lock icon in the bottom-left corner of the window and enter your user password or use Touch ID for authentication.
- Click on “Edit” in the menu bar, then select “Disable Root User.”
![Enable Root User Mac Disable Directory Utility](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-disable-directory-utility.jpg)
Note: you don’t need the root account for most fixes. You can even fix a frozen Mac without root access.
How to Change the Root User Password
- Launch “System Preferences.”
- Go to “Users & Groups.”
![Enable Root User Mac Change Password System Preferences Home](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-change-password-system-preferences-home.jpg)
- Click on the lock icon, then enter the administrator name and password to gain access to the underlying settings.
- Click on “Login Options” in the sidebar.
![Enable Root User Mac Change Password System Preferences Login Options](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-change-password-system-preferences-login-options.jpg)
- Click the “Join” button next to “Network Account Server” in the pane on the right.
![Enable Root User Mac Change Password System Preferences Login Options Join](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-change-password-system-preferences-login-options-join.jpg)
- Click “Open Directory Utility” in the pop-up that appears.
![Enable Root User Mac Change Password System Preferences Login Options Join Directory Utility](https://www.maketecheasier.com/assets/uploads/2022/07/enable-root-user-mac-change-password-system-preferences-login-options-join-directory-utility.jpg)
- Click on the lock icon in the Directory Utility window, then enter your user password or authenticate with Touch ID.
- From the menu bar in Directory Utility, choose “Edit,” then select “Change Root Password.”
![Enable Root User Mac Change Password Directory Utility 1](https://www.maketecheasier.com/assets/uploads/2022/10/enable-root-user-mac-change-password-directory-utility-1.jpg)
- Enter a new root password when prompted.
Frequently Asked Questions
Can I change the username for the root user account?
No. The root account username is “root” by default on all macOS devices.
Can the password for my Mac and root user be the same?
If you want to set it that way, it’s possible. However, if you have someone else who knows your Mac’s password, they’ll also have access to your computer’s administrative privileges.
Is it safe to keep the root user enabled?
No. By enabling the root user, you’ll have full control over your Mac. While this can be handy for advanced users, it’s also far easier to damage your device or leave your Mac open to attacks. Apple is fully aware of this and has disabled root access by default. For safety, disable the root user after performing administrative tasks on your Mac.
Image credit: markusspiske via Pixabay.
Our latest tutorials delivered straight to your inbox