Introduction

Are you looking for some solutions to hide the admin bar for all Users in WordPress? By default, you are able to disable the admin bar for each user. However, disabling it for all users is not an easy and simple issue. For that reason, we decide to support you do that smoothly via the blog today. Let’s take a look!

Before going to the methods, we would like to give you more explanation about the WordPress admin bar. As you know, when users log in to your WordPress site, there will be an admin bar on the top of the screen. This toolbar will appear not only in the WordPress admin area but also on all public pages of your site. You can see the following example about the admin bar.

hide admin bar for all users 1

On the admin bar, there will have some popular tools or shortcuts to different WordPress site sections. The users can use them to customize the content based on the users’ roles and permissions. However, sometimes, the users don’t like this toolbar because it distracts them or they can’t enjoy the full design of the website. Therefore, they want the admin bar to be hidden.

In the blog today, we would like to bring you 3 ways to do that:

  • Hide the admin bar for each user manually
  • Disable the WordPress admin bar for all users via a plugin
  • Deactivate the admin bar for all users (except and include Administrators) by utilizing code

Instructions to hide admin bar for all Users in WordPress

Hide the admin bar for each user manually

Since you are a website owner, WordPress allows you to change the profiles of all users as well as disable the admin bar for them. All you need to do is go to Users -> All Users. Then, choose the user you want to modify the settings and press the Edit button.

hide admin bar for all users 2

After clicking on the Edit button, the edit user section will appear for you to change the settings of the user’s profile easily. Let’s find the Toolbar part and uncheck the box ‘Show Toolbar when viewing site‘. Finally, don’t forget to scroll down and choose ‘Update User‘ to save all your changes.

hide admin bar for all users 3

This method will be quite handy and effective for websites with few users. However, for websites with a large number of users, manually editing each user like this will take a lot of time and effort. Therefore, let’s move on to the next method if your site has many users.

Disable the WordPress admin bar for all users with a plugin

By using this method, you can freely hide the admin bar for all users in a fast and simple way.

First of all, let’s install and activate the Hide Admin Bar Based on User Roles plugin by going to Plugins -> Add New -> Find the plugin on the search bar -> Click Install Now -> Click Activate.

disable admin toolbar for all users 1

After installing and activating the plugin, you need to go to Settings -> Hide Admin Bar Settings. When the section appears, you can choose the option you want.

With the first option ‘Hide Admin Bar for All Users‘, if you want to disable the toolbar for both all users and administrators, let’s click on the corresponding box on the right side.

The next option will allow you to hide the admin bar for all users with the guest roles.

The third selection will support you to disable the admin toolbar for the user’s roles you choose. If you just want to hide the toolbar for the editor, author, and subscriber, for example, this is the best selection for you to do.

The last step, of course, is clicking the ‘Save Changes‘ button to store all your new settings.

disable admin toolbar for all users 2

Deactivate the admin toolbar for all users (except and include Administrators) by utilizing code

If you desire to hide the admin toolbar for all users (except administrators) without using a plugin, you can utilize code to do this. Now, let’s access the WordPress theme’s functions.php file or a site-specific plugin. Then, you just need to add the code below:

add_action('after_setup_theme', 'remove_admin_bar');
function remove_admin_bar() {
if (!current_user_can('administrator') && !is_admin()) {
show_admin_bar(false);
}
}

In case you need to disable the WordPress admin toolbar for not only users but also administrators, just simply open the theme’s functions.php file or a site-specific plugin and add the following code:

/* Disable WordPress Admin Bar for all users */
add_filter( 'show_admin_bar', '__return_false' );

Finally, let’s save your changes.

Now, you, other administrators, as well as all users, won’t see the admin bar on any public pages of your site. All of you can see it when you access the WordPress admin dashboard.

Final thoughts

To sum up, there are many solutions to support you to disable the admin toolbar in WordPress. In this blog, we have already introduced to you the 3 most popular and effective ways. So, we hope they will be helpful for you. In case you have any query, don’t hesitate to leave your comment so that we can answer you quickly. Besides that, if you are seeking a great plugin to build professional profiles for your site’s users, why don’t you explore the WordPress User Profile Plugins here? What’s more? If you wish to renew your site appearance with an impressive theme, let’s check out Free WordPress Themes.

5/5 - (2 votes)
Latest posts by LT Digital Team (Content & Marketing) (see all)

Joomla! 4 Updates 120+ Joomla! designs are fully compatible with Joomla! 4.x, support 4.0.5 now! Check it out
Happy New Year 2022! Get 50% Off for everything, don't miss this huge sale! Coupon code: XMASNEWYEAR50 Redeem Now