BuddyX

10 min read · 2,039 words

BuddyPress Toolbar: Customize, Hide or Edit the Top Bar

BuddyPress Top Login Bar

To customize the BuddyPress toolbar (often called the top login bar), first work out which bar you mean. The thin bar across the top of a BuddyPress site is usually the WordPress Toolbar (also called the admin bar), which BuddyPress adds links to. Logged-out visitors see Log In and Register, and members see their account menu. You control it with a BuddyPress setting and a few lines of code. Login and register links inside your theme header are a different thing, and you change those in the Customizer.

Last updated: 6 November 2026

This guide covers both, with code you can paste into a child theme or a small site plugin. We checked each snippet against the WordPress developer reference and the BuddyPress source.

By the numbers

  • BuddyPress lists more than 90,000 active installations on WordPress.org (checked 6 November 2026); the current release is 14.5.4, last updated on 23 October 2026.

What is the BuddyPress toolbar?

WordPress shows a black Toolbar across the top of the front end to logged-in users. BuddyPress hooks into it in two ways:

  • For logged-in members, it adds an account group (internally named my-account-buddypress) under the standard My Account menu, with links to the member’s profile areas.
  • For logged-out visitors, it can show the Toolbar with a Log In link and, if registration is open, a Register link. That is the “top login bar” many people search for.

Your theme may also have its own login and register links in the header. They are separate from the Toolbar, so hiding one does not hide the other.

How do you hide the BuddyPress toolbar for members?

The WordPress developer reference says that returning false from the show_admin_bar filter is the recommended way to hide the Toolbar on the front end. This filter does not affect the dashboard, where the bar always shows.

Hide it for everyone who is not an editor or admin

This keeps the bar for people who write content and hides it from ordinary members, such as subscribers and customers:

function mysite_hide_toolbar_for_members( $show ) {
	if ( is_user_logged_in() && ! current_user_can( 'edit_posts' ) ) {
		return false;
	}
	return $show;
}
add_filter( 'show_admin_bar', 'mysite_hide_toolbar_for_members' );

The is_user_logged_in() check is deliberate. Without it, the filter would also hide the bar from logged-out visitors, which overrides the BuddyPress setting described below.

Hide it for one role only

function mysite_hide_toolbar_for_role( $show ) {
	$user = wp_get_current_user();
	if ( in_array( 'subscriber', (array) $user->roles, true ) ) {
		return false;
	}
	return $show;
}
add_filter( 'show_admin_bar', 'mysite_hide_toolbar_for_role' );

Replace subscriber with any role slug on your site, such as customer on a WooCommerce store.

Set it per user, or for every new member

Each user has a profile checkbox called Show Toolbar when viewing site. Behind it is a user setting named show_admin_bar_front, stored as the text true or false. You can set it when a member registers, so the bar is off from day one while members can still switch it on:

function mysite_toolbar_off_for_new_users( $user_id ) {
	update_user_meta( $user_id, 'show_admin_bar_front', 'false' );
}
add_action( 'user_register', 'mysite_toolbar_off_for_new_users' );

This only affects accounts created after you add it. Existing members keep their current setting.

Where do you put this code?

Put it in a child theme’s functions.php or in a small site-specific plugin. Do not edit a parent theme directly, because an update will erase your change. A code snippets plugin also works if you prefer to avoid files.

Why not just hide it with CSS?

A rule such as #wpadminbar { display: none; } hides the bar but leaves WordPress’s top spacing in place, which can leave a gap above your header. The bar is still loaded for every member too. The filter removes it properly, so use CSS only as a last resort.

How do you show or hide the toolbar for logged-out visitors?

BuddyPress has a built-in switch for this:

  1. Go to Settings, BuddyPress, Options in the WordPress dashboard.
  2. Find the Toolbar row.
  3. Tick or untick Show the Toolbar for logged out users.
  4. Save the settings.

In the BuddyPress source, that option is stored as hide-loggedout-adminbar and defaults to showing the Toolbar. When it is on, visitors see Log In, plus Register if your site allows sign-ups. If you would rather use your theme’s header buttons, untick it so visitors do not see two sets of login links.

How do you customize the BuddyPress toolbar menu?

The Toolbar is built from “nodes,” and each node has an ID. You can remove or add nodes on the admin_bar_menu hook. The WordPress reference examples run this at priority 999 so that your change happens after plugins have added their items.

function mysite_remove_buddypress_toolbar_items( $wp_admin_bar ) {
	$wp_admin_bar->remove_node( 'my-account-buddypress' );
}
add_action( 'admin_bar_menu', 'mysite_remove_buddypress_toolbar_items', 999 );

Removing a parent node also drops the items under it. WordPress ignores any node whose parent no longer exists when it builds the bar. To remove only the logged-out links instead, use the node IDs bp-login and bp-register.

How do you find a node ID?

Right-click the item in your browser and choose Inspect. The list item has an ID such as wp-admin-bar-my-account. Remove the wp-admin-bar- prefix and what remains is the node ID to pass to remove_node().

function mysite_add_toolbar_link( $wp_admin_bar ) {
	if ( ! is_user_logged_in() ) {
		return;
	}
	$wp_admin_bar->add_node(
		array(
			'id'     => 'mysite-help',
			'parent' => 'user-actions',
			'title'  => __( 'Help center', 'mysite' ),
			'href'   => home_url( '/help/' ),
		)
	);
}
add_action( 'admin_bar_menu', 'mysite_add_toolbar_link', 110 );

The user-actions group is the area under the member’s avatar that holds links like Edit Profile and Log Out. Change the text domain mysite to your own.

If your theme draws its own login links, you change them in the Customizer rather than with code. Here is how it works with BuddyX, based on the theme’s current settings:

  1. Go to Appearance, Customize, Site Header.
  2. Switch Enable Login Link and Enable Register Link on or off. Both are on by default, and they show to logged-out visitors in the header.
  3. Click Publish.

BuddyX Pro adds more on top of that, according to its documentation: a button style picker for the login and register links (text, icon, or button styles), an optional Site Top Bar for a contact line and social icons, and branding for the WordPress login page. The free BuddyX theme has the login and register switches but not those extras. BuddyX does not change the WordPress Toolbar itself, so use the code above for that.

If you run BuddyNext instead of BuddyPress, BuddyX Pro detects it and routes the login, register and lost password links to the BuddyNext sign-in pages, and feeds your user menu into the BuddyNext header dropdown. If you are still choosing a theme for your community, see our list of BuddyPress-compatible themes and the guide to free WordPress community themes.

Where do members land after they log in?

Hiding the Toolbar does not change where a login sends people. By default WordPress may send members to the dashboard, which is confusing for a subscriber. Set a redirect to the member’s profile or the activity page. Our guide on BuddyPress login redirects shows how.

How do you test the change?

  1. Logged out: open the site in a private window. Check that you see exactly one set of login and register links, either in the Toolbar or in the header.
  2. As a member: log in with a test subscriber account. The Toolbar should be gone.
  3. As an admin: confirm you still have the Toolbar so you can reach the Customizer and edit links.
  4. On a phone: check a 390px wide screen. Make sure there is no gap above the header and that the header buttons do not wrap.
  5. With caching on: if you use a page cache, clear it after the change. Test again logged out.

Why isn’t my change working?

  • The bar still shows for members. Another plugin or your theme may set show_admin_bar later. Try a higher priority, such as add_filter( 'show_admin_bar', 'mysite_hide_toolbar_for_members', 99 );.
  • The bar vanished for logged-out visitors too. Your filter is missing the is_user_logged_in() check.
  • The node is still there. Check the node ID spelling, and run the code at priority 999 on admin_bar_menu.
  • A blank gap appears at the top. You hid the bar with CSS. Use the filter instead.
  • Admins cannot see the bar on the dashboard. This should not happen, because the dashboard always shows it. Check for a plugin that hides it with CSS.

FAQs

Is the BuddyPress top login bar the same as the WordPress admin bar?

Usually, yes. BuddyPress adds its links to the WordPress Toolbar. Some themes also draw their own login links in the header, which are separate.

Can members turn the toolbar off themselves?

Yes. WordPress adds a Show Toolbar when viewing site checkbox to each user’s profile screen. If you set the default to off for new users, members can still switch it on.

Will hiding the toolbar lock members out of their profile?

No. Members still reach their profile through your site menu or theme header. Make sure your main navigation or header has a clear link to it first. Our guide to member profiles and directories shows how to make profiles easy to find.

Does this work with BuddyBoss or BuddyNext?

The show_admin_bar filter is part of WordPress, so it works on any site. The my-account-buddypress node and the BuddyPress Toolbar setting are specific to BuddyPress, so check the node IDs on other platforms using the Inspect method above.

Should I hide the toolbar for administrators too?

We would not. Admins use it to jump to the Customizer and edit screens. Keep it for them and hide it only for ordinary members.

Is BuddyPress still maintained?

Yes. WordPress.org lists BuddyPress 14.5.4 as last updated on 23 October 2026, with more than 90,000 active installations. Check the plugin page for compatibility with your WordPress version before you change production code or settings.

Sources

Reading
10 min · 2,039 words
Published
Nov 29, 2024
Shashank Dubey
BuddyX contributor

Writing about WordPress communities, BuddyPress, BuddyBoss, LMS plugins, and the business of paid communities.

Keep reading

More from the BuddyX blog

Browse all posts on community, WordPress, BuddyPress and the studio of plugins behind BuddyX.

What customers say on Trustpilot

I recently purchased the Buddyx Theme…

I recently purchased the Buddyx Theme and the support that I have been receiving from WBCom is nothing short of amazing! They truly stand behind their product in every sense!

Greg MoreheadUS