Making WordPress' Admin Tool Bar Less Ugly

by | Aug 2, 2017

blickpixel / Pixabay

If you have ever used WordPress with an account, you’ll have seen the admin bar, and since you are reading this, I’ll assume you don’t like it. So what can we do about it? A good start would be to get rid of it all together, but that removes a lot of functionality. I’ll still cover how to do it because it’s a good option for certain user groups, but it’s not the perfect solution for me. I could hide the navbar by having it collapse. This is what I have currently and I will cover how to do it, but it’s still not perfect. So what’s left? The last option we have is to modify the admin tool bar. We can do this by editing the CSS attributes styling the toolbar, and also editing the functions which add components to the toolbar.

Option 1: Remove the toolbar completely

You can remove the toolbar from your instance of wordpress only by going to your Admin panel > Users > Your Profile and uncheck the box that says Show Toolbar when viewing site.  But this functionality will not carry over to other users. In order to do this, we’ll have to dig into the code. It’s nothing crazy though, just go to your functions.php file and add add_filter('show_admin_bar', '__return_false');. With this technique, it is easy to wrap the filter in conditional login. You can simple add and if statement or two to only allow the toolbar on certain accounts or deny it on others.

Option 2: Hide the toolbar

This requires different tactics to the previous option; a plugin. Its fairly straight forward and quite flexible. To get started, go to the Settings > Auto Hide Admin Bar Options and select the options that best fit your needs.

Option 3: Modifying the toolbar

To start off basic, we can revisit our settings page under Admin panel > Users > Your Profile or Admin panel > Profile. At the top we have options for changing the theme of your admin features. However, this may lead to modification of things you don’t want changed, or you may not see a theme that you like. Unfortunately the next step is a lot more complicated than the first. Modifying the toolbar code is quite an undertaking. Whether it’s Styles or Scripts, you should be careful with what you change as it may negatively affect other components of your themes or plugins. I’d advise you only start fiddling with the admin bar if you have a solid knowledge of php and WordPress development, or if you’re okay with the possibility of something going horribly wrong and potentially destroying your website. If you are ready to start modifying the admin toolbar here are a few resources to point you in the right direction.

Customizing (or Removing) the WordPress Admin Toolbar

Adding Scripts and Styles to WordPress the Right Way With Enqueueing


So there we have it! A couple different ways to make the toolbar your own. If you are an absolute beginner, I would suggest trying to accomplish your goals from the user settings page and/or using the auto hide plugin. If you’re feeling a little adventurous I would start with some CSS and conditional logic to show/hide the toolbar. For anyone feeling wild, jump right on into modifying the admin bar with enqueuing and your functions.php file. Whatever you decided, know your limits and be careful! Unless your using a disposable install, then you can experiment to you hearts content.
From hard data to fluid design – Scott
Scott blogs about how design can make data consumable and therefore valuable.
Want to read more? Try … WordPress Plugins: Shortcodes Ultimate – Maker or more from Scott
We run regular Data Requirements and Agile data warehouse training courses with an Agile business intelligence slant in both Wellington and Auckland

1 Comment
Submit a Comment

Your email address will not be published. Required fields are marked *