1. Home
  2. Knowledge Base
  3. Customizations
  4. CSS
  5. Hide the Profile Search in the Members Directory for Logged-out Users

Hide the Profile Search in the Members Directory for Logged-out Users

Introduction

By default, BuddyBoss does not provide an option to hide the Profile Search widget in the Members Directory for logged-out users. Using a simple CSS snippet, you can prevent non-logged-in visitors from accessing the profile search, helping limit directory interactions to logged-in members only.

Custom Workaround

Follow the steps below to hide the Profile Search for logged-out users:

  1. Go to BuddyBoss > Theme Options
  2. Under Custom Codes, enable CSS
  3. Append the following:
body:not(.logged-in) aside#bp-profile-search-form-outer.bp-profile-search-widget.widget { display: none; }
  1. Save changes.

Note: Any modifications are considered as custom work already. Know more about our Support policy here: https://buddyboss.com/support-policy/

Troubleshooting and FAQs

Q: Will this remove the Members Directory entirely for logged-out users?

A: No. This only hides the Profile Search widget. The Members Directory itself will still be accessible unless restricted separately.

Q: Logged-in users can still use the Profile Search, right?

A: Yes. This CSS targets logged-out users only and does not affect logged-in members.

Q: The Profile Search is still visible after adding the CSS. What should I do?

A: Clear your site cache and browser cache. If it still appears, submit a ticket to the support team for assistance.

Q: Does this apply to mobile devices as well?

A: Yes. The snippet works across all screen sizes unless overridden by other custom CSS or theme rules.

Q: Can I hide the Profile Search only on specific pages?

A: Not with this snippet alone. Targeting specific pages would require additional selectors or custom development.

Was this article helpful?

Related Articles

Subscribe to Our Newsletter

Stay In Touch

Subscribe to our Newsletter, and we’ll send you the latest news from BuddyBoss

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

To speak to our Agency consultant, fill in the form found at our Contact Page.