BUDDYBOSS WEB

Your community, courses and memberships on your own website.

BUDDYBOSS APP

Your own branded app on iOS and Android.

DONE FOR YOU

We build, launch and run it for you.

BuddyBoss website and mobile app

Web + App Done For You

$4,999 flat

Web Scale + Done For You Web

App Launch + Done For You App

PRICING

Web Pricing

Launch, Scale and Done For You Web.

From

$199

first year

App Pricing

Solo, Launch and Done For You App.

From

$499

first year

SITE + APP

Web + App Done For You

Your site and your app, built and run for you.

$4,999

flat, never rises

How to Hide the Member Directory Page

Updated

Introduction

The BuddyBoss platform does not provide a built-in option to disable or hide the Member Directory page. If you want to prevent users from accessing the members directory, you can achieve this by adding a small custom function to your active theme. This approach forces the Member Directory page to return a 404 error, effectively hiding it from public access. This guide explains how to hide the Member Directory page using a custom workaround.

Custom Workaround

Before proceeding, make sure you have a complete site backup.

  1. Go to Appearance > Theme Editor in your WordPress admin dashboard.
  2. Under Select theme to edit, choose your active theme (preferably a BuddyBoss Child Theme), then click Select.
  3. From the Theme Files list, open Theme Functions (functions.php).
  4. Add the following code just before the closing PHP tag (?>):
function bbp_hide_members_directory() {
    if ( bp_is_members_directory() ) {
        bp_do_404();
        load_template( get_404_template() );
        exit( 0 );
    }
}
add_action( 'bp_template_redirect', 'bbp_hide_members_directory' );
  1. Click Update File to save the changes.

After saving, visiting the Members Directory page will display a 404 page instead of the directory.

Screenshots

With the code:

Without the Code: 

Note: Modifications are typically considered custom work, but we are making an exception in this case. Please review the BuddyBoss Support Policy.

Troubleshooting and FAQs

Q: The Members Directory is still accessible.
A: Make sure the code is added to your child theme’s functions.php file. Clear any caching plugins and refresh the page. Also confirm that BuddyBoss Platform is active.

Q: Does this remove member profiles as well?
A: No. This only hides the main Members Directory listing. Individual member profile URLs will still be accessible unless restricted separately.

Q: Can I hide the directory only for logged-out users?
A: Yes. The function can be modified to check is_user_logged_in() if you want to restrict access conditionally.

Q: Can I undo this change later?
A: Yes. Simply remove the code from functions.php and save the file. The Members Directory will become accessible again.

Was this article helpful?

Subscribe to Our Newsletter

This field is for validation purposes and should be left unchanged.
This field is hidden when viewing the form

Can’t find the answer you’re looking for?

Our support team is here to help with anything the docs don’t cover.