Read this blog on Woocommerce search and filter not working for more information.
If Product Filters do not show filters or not show results for attributes/categories/tags if you’re using WooCommerce between 2.6.x and 3.0 and WordPress less then 4.7, please, follow these simple steps:
1. Update your plugins
If you have an active cache plugin, please, do also the following:
2. Go to WooCommerce > System Status > Tools and click on recount terms
3. Empty the cache (if any)
If still the filters do not show up:
4. copy and paste the following code into the functions.php file of your current theme:
add_filter ('yith_wcan_use_wp_the_query_object', '__return_true');
and go through steps 2 and 3 once again.
The ability to filter products in stores today is a necessity to make the search for goods more efficient. Users are accustomed to using this tool, and not offering it can hurt your store. If the above methods do not work, then move on to using a custom search plugin that will give you smart filters as well.
How to fix the Woocommerce Search and Filter not Working issue using ExpertRec
- Go to https://cse.expertrec.com/newuser?platform=wordpress
- Enter your website URL and initiate a crawl.
- Wait till all site pages of your website have been crawled.
- Download and install the WP fastest site search widget from here.
- Go to https://cse.expertrec.com/csedashboard/home/Status and copy your site ID.
- Click on the site search icon in your WordPress admin panel. Copy-paste your API key from inside your WordPress admin panel
- This widget adds a better performing search form to your website.
- Subscribe to a paid plan (9 USD per month).
- That’s it, you have added a search form to your Woocommerce site.
The main purpose of the smart plugin is to improve the user search experience for any WordPress based website. You can manage a lot of settings provided by the plugin to customize its appearance by selecting what fields to display and changing styling options. It’s pretty easy to select the required fields to be used for the search in the plugin settings.
How to Troubleshoot Woocommerce Product Filter?
The ability to filter products in stores nowadays is essential for streamlining the process of looking for things. Because users are used to using this tool, not providing it may affect your business. If none of the approaches are successful, try employing a custom search plugin that will provide you with clever filters.
If you are using WooCommerce between versions 2.6.x and 3.0 and WordPress less than version 4.7 and Product Filters do not display filters or do not display results for attributes, categories, or tags, please do the following easy steps:
- Update the plugins you use(Please take additional action if you have a cache plugin that is currently running)
- Click Recount Terms under WooCommerce > System Status > Tools.
- Wipe out the cache (if any)
- If the filters are still hidden, repeat steps 2 and 3 after pasting the relevant code into your existing theme’s functions.php file.
How to Set Up a WooCommerce Price Filter on Your Shop Pages?
WooCommerce’s built-in product filter widget is the best way to set a price filter for products. Every WooCommerce installation includes this widget, which you may use in any sidebar area on your website.
These steps need to be followed to use the WooCommerce default product filter widget:
- Go to your WordPress dashboard.
- Go to Appearance > Widgets.
- Locate the Product Filters widget and place it where you want it to appear in the sidebar.
- From the drop-down selection for the Filter type, choose “Price” in the widget settings.
- Press Save.
Why WooCommerce Widget Not Appearing in Sidebar or Off-Canvas Filter?
A component of the navigation plan is the Off-Canvas sidebar. The sidebar is shifted initially off the screen and hidden. You must enable the filter option from the Toolbar option for the sidebar to show. Off-Canvas Sidebar displays when you click the trigger. Responsive gadgets respond to this choice as well. If the Off-Canvas filter or sidebars on your WooCommerce website do not reveal your widgets, then:
- Access the dashboard, Status > Tools > WooCommerce
- Select Update Database from the menu
How to Use the Filter Products by Price Woocommerce Block?
The Product Filter – Price block in the WooCommerce Product Search provides a live price filter for your shop. It searches for relevant products and displays them on the shop page as your clients enter the lowest and maximum prices in its fields.
- Launch the Block Editor and start with the ‘All Products’ block
- Locate the block labelled “Filter Products by Price”
- After you insert this element, the Block Editor will show a price slider with a starting value of $0 and a cap of the costliest item in your store
- The slider won’t work on your editing screen, as you’ll see. You must view the page in preview mode to see the block in action (or you need to publish or access it from the front end)