How to Hide Products in WooCommerce Catalog Visibility Options

Updated: September 22, 2021

Share:

There are several reasons why you would wish to hide products in WooCommerce catalog visibility options in your online store. This might be because some eCommerce merchants sell to both retail customers and B2B purchasers. Alternatively, membership site owners may make special items (such as merchandise) available only to members.

The good news is that you can conceal WooCommerce goods in your online store in various ways. That is why today’s tutorial will show you how to hide products in WooCommerce catalog visibility options in three different methods. So, let’s dive in!

Table of contents:

Why do we need to hide products in WooCommerce catalog visibility options?

Many online merchants build WooCommerce hidden items. These items have been uploaded (and published) to the WooCommerce store but are “hidden” from the main shop page and product archives. More precisely, we mean WooCommerce hidden items that fall into one or more of the following categories:

  • WooCommerce items are not accessible to particular (or all) users on the main store page or in the product archives.
  • Products that cannot be accessed through a direct URL
  • Products that are not indexable by search engines, i.e., they are not visible to search engines

In general, online merchants develop WooCommerce hidden goods for a variety of reasons. The fundamental aim, though, is to limit the availability of particular items to specific categories of clients.

B2B store tend to hide products in the Catalog Visibility options

Here are a few examples of typical applications:

  • Wholesale stores: WooCommerce wholesale shops and B2B stores that sell to both retail and wholesale clients may require a means to limit the availability of - specific items to wholesale customers alone. These might be product bundles or entirely distinct goods.
  • Sites that provide memberships: WooCommerce membership sites frequently sell special items in addition to regular (non-member) consumers. Tickets to events, engraved merchandise, and limited-edition products are examples of such things.
  • Stores for members only: Members-only stores are ones that exclusively sell items to logged-in members. In other words, you must be a registered member to see and purchase items.

How to Hide Products in WooCommerce Catalog Visibility Options

Of course, there are thousands of more instances where you could need to hide products in WooCommerce catalog visibility options. The three ways we’ll go through later in this post may be applied to almost any online business that wants to hide WooCommerce items.

Method 1: Using the default setting

Several built-in WooCommerce options limit WooCommerce Catalog Visibility and WooCommerce Product Visibility without using a plugin or custom code. How you disable, hide, or make a Product Page Private in WooCommerce depends on why you hide the product visibility. If you want to make the WooCommerce product page private so that only Admins can view it, add the product to cart, and test the WooCommerce shop, you’ll need to use a different method than if you only want to conceal a Product Page while you’re creating it or adding content.

Similarly, suppose you want to make the WooCommerce Product Visibility Private and only accessible to chosen members. In that case, you’ll need to use a different technique rather than web admins or WordPress users. So, be clear on why you want to conceal WooCommerce Products to ensure you choose the best option for your unique needs. Following these steps below:

  • Step 1: Log in as the admin account to your WordPress site and go to the Dashboard.
  • Step 2: Click Products from the Dashboard menu and choose the product you want to remove from the site.
  • Step 3: Go to the edit page by clicking on the Product title, as illustrated below:

Click on product title

  • Step 4: The usual “Publish” meta box may be seen on the right-hand side. It gives you the ability to configure publishing options and publish your posts, goods, or pages. There is a setting named “Catalog visibility” there. Click the Edit link to the right of it. You will be given some options for the Product’s visibility on the front end.
  • Step 5: Choose the Hidden option.
  • Step 6: When you click the Update button, the product will be removed from the front end of your WooCommerce Store.

Select the hidden option

The primary disadvantage of this technique is that anyone with a direct URL may still access the goods. Furthermore, it is not appropriate for store owners to conceal many goods because it needs you to update each product manually.

Method 2: Coding

On the other hand, coding is the simplest way to hide products from Carts, Checkout, and other WooCommerce pages. The following are the steps you must take: -** Step **1: Log in as the admin account to your WordPress site and go to the Dashboard.

  • Step 2: Click Appearance Menu > Theme Editor Menu from the Dashboard menu. When entering the Theme Editor page, look for the theme functions file and add the function to hide goods from the WooCommerce cart, checkout, order received, and emails.
  • Step 3: In the function.php file, add the following code: ```

/**

  • Hide Hidden Products from Cart, Checkout, Order - WooCommerce

*/

add_filter( ‘woocommerce_cart_item_visible’, ‘njengah_hide_hidden_product_from_cart’ , 10, 3 );

add_filter( ‘woocommerce_widget_cart_item_visible’, ‘njengah_hide_hidden_product_from_cart’, 10, 3 );

add_filter( ‘woocommerce_checkout_cart_item_visible’, ‘njengah_hide_hidden_product_from_cart’, 10, 3 );

add_filter( ‘woocommerce_order_item_visible’, ‘njengah_hide_hidden_product_from_order_woo333’, 10, 2 );

function njengah_hide_hidden_product_from_cart( $visible, $cart_item, $cart_item_key ) {

$product = apply_filters( 'woocommerce_cart_item_product', $cart_item['data'], $cart_item, $cart_item_key );

if ( $product->get_catalog_visibility() == 'hidden' ) {

    $visible = false;

}

return $visible;

}

function njengah_hide_hidden_product_from_order_woo333( $visible, $order_item ) {

$product = $order_item->get_product();

if ( $product->get_catalog_visibility() == 'hidden' ) {

    $visible = false;

}

return $visible;

}

```

  • Step 4: Save your changes.

Method 3: Using the third-party plugins

Using third-party plugins allows you to get more advanced features to manage and control your WooCommerce Catalog Visibility options. Here are some greats plugins that could enhance your managing system:

WooCommerce Members Only

The WooCommerce Members Only plugin allows you to conceal WooCommerce goods from your online shop in several ways, which we will go over in detail below. The plugin provides:

  • Individual WooCommerce items, WooCommerce product categories, or all WooCommerce products can be hidden using passwords.
  • Options for hiding WooCommerce products for particular user roles. This is ideal for membership sites and shops that cater to a variety of clients.
  • Use the User ID option to restrict access to hidden WooCommerce items to particular users.
  • The log-in status option restricts access to WooCommerce hidden items to logged-in users only. This feature may benefit WooCommerce store owners who wish to provide exclusive items to consumers who have user accounts, for example.

WooCommerce Members Only

It essentially provides you fine-grained control over WooCommerce product visibility and allows you to specify how you want to restrict access. Simply said, it lets you control who may see and buy your WooCommerce items. The WooCommerce Members Only plugin also includes user role management. It is used for creating new roles, assigning capabilities, and updating current functions.

By category

To hide a specific WooCommerce product by category, go to the Edit product screen and scroll down to the Product data area. Select the Members Only tab.

Click on the Members Only tab

From the dropdown menu, choose a Restriction method. If you select Password, for example, you will be prompted to enter a password (or create a set of passwords) to unlock the product. To hide WooCommerce items by category or all WooCommerce products in your shop, go to the WordPress admin panel and navigate WooCommerce > Settings > Members Only.

Restricted Content and Specified Categories

Select a Restriction Method and change the Restricted Content option to Specified Categories. Finally, add the restricted categories into the Restricted Categories section, create a password, and choose where the password form page is displayed. In the same way, you may conceal all WooCommerce goods from your online store. Simply change the Restricted Content setting to All WooCommerce Pages.

By user role

Assuming you already have user roles set up, you can build WooCommerce hidden products based on user roles in a matter of minutes.

By user role

Assume you want to conceal various WooCommerce items based on user role (s):

  • Step 1: Go to WooCommerce > Settings > Members Only and set the Restriction Method to User Role.
  • Step 2: Using the Restricted Content option, decide whether you want to conceal goods in a specific category or all WooCommerce products.
  • Step 3: If you choose Specified Categories, you can additionally define which WooCommerce product categories are restricted in the Restricted Categories section.
  • Step 4: Finally, insert one or more user roles under the Permitted User Roles column. These are the user roles that have access to the WooCommerce products that are concealed.
By log-in status

If you operate a membership site or want to build WooCommerce hidden items for members only, try concealing products based on the user’s log-in status. Following these steps below:

  • Step 1: Go to WooCommerce > Settings > Members Only and set the Restriction Method to Log In Status.
  • Step 2: Using the Restricted Content option, decide whether you want to conceal goods in a particular category or all WooCommerce products.
  • Step 3: Enter the Restricted Categories section to specify the WooCommerce product categories you want to hide.

By log-in status

By using passwords

You may give several passwords (or a single password) to individual WooCommerce items, WooCommerce product categories, or all WooCommerce products in your shop using the WooCommerce Members Only plugin. This is an excellent choice for business owners looking for a simple method to organize marketing campaigns or provide discounts. Following these steps below:

  • Step 1: Go to WooCommerce > Settings > Members Only and set the Restriction Method to Password.
  • Step 2: Using the Restricted Content option, decide whether you want to conceal goods in a specific category or all WooCommerce products.
  • Step 3: Enter the WooCommerce product categories you want to hide in the Restricted Categories section.
  • Step 4: In the Passwords area, enter a single password (or a set of passwords).
  • Step 5: Using the Password Form Page option, specify which page the password form should display.

By using passwords

Individual WooCommerce products may also be hidden with a single password (or several passwords) by accessing the Members Only page from the Product data settings.

By user ID

You may need to hide particular WooCommerce items by user ID at times. This is handy when you just want to make WooCommerce items available to a small number of people.

By user ID

Open the product you want to hide, scroll down to the Product info area, and select the Members Only tab. Next, change the Restriction method to By User and input the user IDs you want to give access to.

User ID

Redirect users away from the hidden products

You may wish to divert customers away from hidden items if they attempt to access them to provide a pleasant user experience. This is very handy for WooCommerce membership and members-only sites. Following these steps below:

  • Step 1: From the WordPress admin panel, navigate to WooCommerce > Settings > Members Only.
  • Step 2: Using the dropdown menu, select a Restriction Method.
  • Step 3: Select the page you want to redirect unauthorized users to in the If Restricted, Redirect To box.
  • Step 4: You can select one of the standard WooCommerce pages, such as My account. Alternatively, you may design a custom landing page to which customers will be redirected.

Redirect

This is the simplest method for redirecting customers who do not have access to the WooCommerce hidden product(s) to a different page without giving a terrible user experience. It also allows you to persuade those users to sign up for your subscription or create a user account.

Products Visibility By User Roles

You may use the Products Visibility By User Roles extension to hide products and categories for particular user roles. When a user tries to access a restricted product or type, you may limit visibility for various user roles and display a custom error message or redirect to another URL. You may also restrict guest user visibility and select whether or not to enable Google to rank the banned sites. The goods will be concealed from the store, categories, search, and other listing pages.

Products Visibility By User Roles

Global Visibility

The global visibility option allows you to hide/show products for customers who are not signed in or for all registered customers regardless of their user responsibilities. You may select to hide this option here.

  • Products
  • Categories

Global Visibility

You may also create a personalized message displayed to visitors who attempt to access the restricted page.

Catalog Visibility by user roles

The Visibility by User Roles tab allows you to show/hide goods based on the user role. Click on the role for which you want to change the visibility of your catalog. To implement the updated catalog visibility adjustments, click on “Enable for this Role.”

  • Show – The products will only be shown to the chosen user role and hidden from the rest of the users.
  • Hide – The products will be concealed for the selected user role only, and they will be visible to everyone else.

Catalog Visibility by user roles

You may show and conceal items and categories for all user roles at the same time.

General Settings

You may enable or prevent search engines from scanning, indexing, and ranking your website in general settings. If you want to hide particular goods and categories from non-logged-in consumers, Google will also keep them hidden. Select this option to allow search engines to crawl and rank certain private pages.

General Settings

Catalog Visibility for WooCommerce

Catalog Visibility for WooCommerce enables you to create unique catalogs and personalize your customers’ experiences by presenting more relevant products. The plugin provides extensive visibility controls that allow you to offer appropriate information on client data such as geolocation, price-tier in which their orders fall, and user roles. You may build unique user roles and client groups with a sophisticated user role module to optimize the browsing experience for your potential customers.

Catalog Visibility for WooCommerce

Return to your WordPress dashboard and click to WooCommerce > Settings when the plugin has been appropriately activated. There are several sections on the settings page, including General, Products, Tax, and Shipping. The Catalog Visibility tab will be visible, as seen below. Clicking on it will take you to the settings page. A menu will appear on the upper left of the settings screen. To establish catalog visibility rules, go to Visibility Settings.

User Role

When this property is enabled, similar choices show under it. Store administrators may establish custom user roles in the user role module by choosing Roles from the top menu. The roles you create there will display in the dropdown list here.

User Role

User Group

When this property is enabled, similar choices show under it. Store administrators may establish custom user groups in the user role module by choosing Groups from the top menu. The roles you create there will display in the dropdown list here.

User Group

Price Tier

When this property is enabled, similar choices show under it. Administrators can assign customers a pricing tier. This pricing tier determines whether a customer’s previous order amount falls inside this tier.

Price Tier

Geolocation

When this property is enabled, similar choices show under it. A dropdown list displays all of the world’s countries, allowing users to pick countries and set rules based on them.

Geolocation

Hide Prices for Non-Logged-in Audience

The plugin allows the administrator to hide catalog pricing from non-logged-in users. The administrator can hide prices in specific categories/products or the whole catalog.

Non-logged-in Audience

Hide Products for Non-Logged-in Users

Administrators can use the plugin to conceal catalog goods from non-logged-in users. Admin can restrict non-logged-in users from viewing specific products/categories or the whole catalog.

Non-logged-in Users

User Roles

You may build your unique roles and give them whatever name you like by selecting the Roles choices in the menu above.

User Roles

Navigate to WooCommerce => Customers and choose the customer to whom you want to assign the job. Scroll down to the Catalogue Visibility User Roles option. Select the user role from the dropdown menu by clicking on the selection field. Scroll to the bottom and click on Update Changes. Your customer has now been assigned the User Role.

User Groups

You may establish client groups and give them whatever name you like by selecting the Groups option in the menu above. On the Edit User page, you may assign these groups to customers. This will generate client groups, which can then be used to construct bespoke catalogs.

User Groups

Conclusion

We hope this tutorial demonstrates clearly how to hide products in WooCommerce Catalog Visibility options. In addition, we have highlighted some of the circumstances that may force you to remove a product from your store. However, you should be aware that simply concealing the product will not be enough, as it may be added to the basket dynamically. We also have included a PHP code that will allow you to conceal a product from the basket, checkout, order received, and emails.

Recommend for you
Image Description
SMS, Email Marketing Automation

Top rated Marketing automation for Shopify stores

Learn more
Image Description
SEO Suite

Auto-optimize website elements and structure in one-click.

Learn more
proofo
Boost Sales [Free]

Boost sales: Sales Pop, Trust badges, Countdown timer, more

Learn more
Image Description
Photo Reviews [Free]

Use photo reviews to boost sales

Learn more

Subscribe

Stay in the know

Get special offers on the latest news from AVADA.

40k subscribers has been joined!

Earn $10 in reward now!

comment
iphone
go up