Fine-tune Sitecore Search Facets

A facetted search can provide a good user experience. But not all facets might have the same importance and some you might even want to hide. In this blog post we will have a look at some configuration options for facets in Sitecore Search.

What we want to achieve

A facet is a concept within Sitecore Search that creates filter options dynamically from attribute values. Your visitors can use those to filter search results. Our example has a Category and a Type facet.

Goal

We want to configure the component so the Compliance category is hidden and the Events type is pushed to the front of the filters.

Setting up an attribute as a facet

Before we get into the configuration changes to achieve our goal, let's have a quick look on how the facets shown in the example were set up.

To set an attribute up to act as a facet, you can navigate to the Attributes tab in the Administration > Domain Settings section of the main navigation. Click the attribute you want to configure and switch to the Use For Feature section.

There you can select the checkbox next to the Facets feature and save the configuration.

Configure the facet feature

Once an attribute is set up as a facet, we can work on the configuration to achieve our goal. For that, we navigate to the Feature Configuration tab in the same section on edit the facets entry.

Remove a facet

To exclude a facet, we find the Page Category attribute in the list and click the edit button next to the Boost List settings on the bottom.

There we add the Compliance entry to the excluded values list by clicking the small exclude button.

Boost a facet

To push a facet to the top of the list, we navigate to the same boost list, but for the Type attribute and click the small boost button next to the entry we want to change.

Why can I not see the result immediately?

After we saved and published all the changes, you might not see the new configuration immediately on your website. Changes on the facets require you to start a recrawl on your source. After triggering this and a bit of patience, you can see the result in your component.

Summary

Sitecore Search lets you influence which facet values to show and in which order. You can achieve this by either excluding or boosting them through the boost list in the facet feature configuration.