The WordPress top bar (also known as the admin bar) appears at the top of the screen for all logged-in users by default. While it’s helpful for admins and editors, you may want to hide it for subscribers or non-admin users to provide a cleaner front-end experience.
Here’s how you can do it easily:
✅ Option 1: Using Code (Recommended for Developers)
You can hide the admin bar for all users except administrators by adding the following code to your theme’s functions.php file or a custom plugin:
add_filter('show_admin_bar', function() {
return current_user_can('administrator');
});🔒 This ensures:
- Admins will still see the bar
- Subscribers, authors, editors won’t
✅ Option 2: Plugin Method (No Coding)
If you’re not comfortable editing code, you can use a plugin like:
🔹 Hide Admin Bar Based on User Roles
🔹 WP Adminify
🔹 Adminimize
Just install the plugin, go to settings, and choose which user roles should not see the admin bar.
✅ Option 3: Manual (Per User)
Users can individually disable the admin bar from their profile:
- Go to Users → All Users
- Click on a user
- Uncheck “Show Toolbar when viewing site”
- Save
👉 This is manual and not ideal for large sites.
🧠 Why Hide the Admin Bar?
- Cleaner front-end for subscribers/customers
- Better UX for membership or WooCommerce sites
- Prevents unnecessary access to dashboard links
🔐 For WooCommerce or Membership Sites:
If you’re running a store or membership site, hiding the admin bar can make the user area look more professional and reduce confusion.
Thanks for this question! This answer provided by FixxWP Team.