Home » Documentation » Product Search » Filtering and Exclusions » How to Filter WooCommerce Products by Category

How to Filter WooCommerce Products by Category

To control which product categories appear in search results, navigate to Elevated › Product Search › Settings › Advanced Options and expand the Search Filters section. Choose whether to include all categories, exclude specific categories, or only include specific categories. Select the categories from the dropdown, then click Save Settings. The indexer automatically applies the filter.

Table of Contents

Step 1: Open Product Search Filters

Navigate to Elevated › Product Search › Settings.

Look for the Advanced Options section on the left side of the page. Click Advanced Options to expand it.

Settings page with Advanced Options section highlighted

Scroll to the Search Filters section below Fuzzy Matching.

Search Filters section showing filter mode options

Step 2: Choose a Product Category Filter Mode

The Search Filters section provides three ways to control which categories appear in search results.

Include all products: Every product in your store appears in search. No categories are hidden.

Exclude specific products: Hide products from certain categories. Products in the selected categories will not appear in search results.

Only include specific products: Only show products from certain categories. Products outside the selected categories will not appear in search results.

Toggle the option that matches your needs.

Step 3: Select Product Categories to Include or Exclude

If you enabled Exclude specific products or Only include specific products, the Categories and Tags inputs appear below.

Categories input visible under Search Filters

Click the Categories input and type a category name. Select the categories you want to exclude or include.

To remove a selected category, click the X next to the category name.

You do not need to select tags unless you also want to filter by tag. This article focuses on category filtering only.

Step 4: Save Product Search Settings

Click Save Settings at the top of the page.

The indexer automatically rebuilds to apply the category filter rules. A success message appears indicating how many products were indexed.

Step 5: Test the Category Filter for WooCommerce Products

After you add filtering WooCommerce products by category, visit a page on your frontend where the search form is placed.

Search for a product that belongs to a category you excluded. Confirm that it does not appear in the live dropdown results.

Then search for a product that belongs to a category you included. Confirm that it appears normally.

WooCommerce Product Category Filtering

When you filter WooCommerce products by category, you restrict which products the indexer includes in the search results pool. This is different from the Categories toggle in Search Scope, which makes category names searchable. Filters control which products are eligible to appear at all based on their category assignment.

When you choose Only include specific products, the indexer creates a whitelist of categories. This is useful if you want the search form to show a subset of your catalog, such as a specific product line or seasonal collection.

When you choose Exclude specific products, the indexer creates a blacklist. This is useful for hiding internal products, discontinued items, or categories that should not be discoverable through search.

If a product belongs to multiple categories and one of those categories is excluded, the product will not appear in search results. Category filtering applies at the product level, not the category name level.

Advanced Troubleshooting

Filtered products still appear in search

Confirm you selected the correct filter mode and categories. If you chose Exclude specific products, verify the product is actually assigned to the excluded category in WooCommerce. If you recently changed the settings, click Force Index Rebuild in the Indexer section and test again.

No search results appear at all

If you enabled Only include specific products and selected categories with no assigned products, the search form will return no results. Switch to Include all products or verify your category selections.

Category filter affects products I did not expect

A product assigned to multiple categories will be excluded if any one of its categories is in the exclude list. Check the category assignments for the affected product in WooCommerce.

Filter WooCommerce Products by Category – Related Documentation

On this page
Want More?

Get Every Elevated Extension You’ll Ever Need—One Payment, Yours for Life

Build faster, smarter, and without limits. A single purchase unlocks our entire library today and every new extension we release in the future. No renewals, no upsells, just lifetime power at your fingertips
+All other extensions for unlimited sites

The All Access Pass, available for a limited time

This exclusive package won't be around forever, as we will eventually move to a subscription model. This is your chance to get in early.
  • All Current Extensions
  • All Future Extensions
  • No Renewal Fees
  • 90-Day Money-Back Guarantee