Docs

Facets

Overview

Faceting provides your visitors an interface to select desired field values (or product attributes or search listing page) in order to filter their search results.

Every time a user clicks a facet value, the set of results is reduced to only the items that have that value. Additional clicks continue to narrow down the search—the previous facet values are remembered and applied again. For example, the user might click "Cookbooks," and see a list of all 10 cookbook titles next to an updated navigation list like this:

If price is more important to the user than the reviews of fellow shoppers, the next click would be on a price range, say "$10-19.99." Now the list might look like this:

At this point, it is very easy for the user to choose the right cookbook.

Hence, faceted search results provide an easy-to-scan, browsable display that helps users to quickly narrow down each search.

Advantages of using Faceted Search

Increases product discoverability – Imagine scrolling through hundreds of products and hitting page after page only to feel exhausted and frustrated. This is what happens with users when they don’t find the products they are looking for. Faceted navigation solves this problem in multiple ways.

Least number of clicks to the desired products page – Faceted search helps your site users to skip the tiresome task of scrolling through a huge list of products and mindless browsing through tons of pages. With very few clicks, faceted navigation takes the user to the desired product. A user can quickly find a product and also go back and forth through different products with utmost ease and less amount of pain.

Higher Conversion Rate – Helping users reach their products of interest soon helps them reach a buying decision and purchases.

Facets Features

1. Multiselect Facet

This feature provides your visitors an option to select multiple values within a facet field or across facets fields. For example, for a query, “shoes”, you show facets on brand and size fields. If a visitor selects Nike in the brand facet field, other values in the brand facet field and field values of the size facet field will also be visible to the visitor. The search results will be refined according to the selection. Multi-select faceting is based on filter operations, that is, AND and OR.

AND

This operation will filter products that satisfies all the specified filter conditions. In other words, the results will be inclusive of those products that have all the filter fields.

OR

This operation will filter products that satisfies at least one of the specified filter conditions. In other words, the results will be inclusive of all the products that haves at least one the filter fields.

2. Multilevel Facet

You can build a hierarchy in your facet values to enable multi-level navigation and filtering. This pattern is great for long lists of values and to improve discoverability: your users will be able to browse up and down in the levels to refine their search results.

For example
Query = Mobile
Categories are
Mobile & Tablets
Smartphone
Electronics
Using multilevel faceting, you can view number of products present in each category and apply these filter directly to narrow down your search.

The face.multilevel parameter is used to enable multi-level facets in the API response. It takes a fixed value “categoryPath” if you want multi-level facets in the response. If not passed, the multi-level facets will not appear in the response.

3. Displaying Exact Value Count of Facets

The facet algorithm of Unbxd provides you with exact count of values for each facet present on your website. This helps your customer to know exactly how many number of products are present in each facet.

4. Modify default limit

This feature enables you to specify the maximum number of constraint counts (essentially, the number of facets for a field that are returned) that should be returned for the facet fields.

5. Sorting Facet

Configuration can be set by Customer on console for sorting facet values by:

  • Product Count
  • Alphabetical order.

For more information, see here

6. Flexibility to Modify Facet Position

Unbxd provides a simple drag- and-drop option on console to modify the position of facets on your website, according to your business needs.

For example, if you have configured the facets “Brand” and “Color”, you can modify the relative position of these facets on your website using the drag-and-drop operation in our console. Learn More.

7. Different Facets for Different Category Pages

Unbxd lets you customize facets according to your requirements.
You can configure different facets for different category pages. For example, a category page “shirts”, the facets could be gender, brand, color, size, and Price, but for a category page “smartphone”, facets could be brand, color, RAM, OS etc. You can set the order for these facets in terms of position with respect to each other.You can also rank the facets values according to product count/alphabetical order depending on the use case.
Unbxd provides an easy way in console to do so. Learn More.

8. Flexibility to Modify the Gap between Range Facets

Range Facets are configured on numeric fields in the catalog (essentially fields whose values are of numeric datatype). For example, Price, Discount, Offer etc.

You can specify the span of the range as a value to be added to the lower bound.The span of each range is expressed as a value to be added to the lower bound. For example, for facet “price”, for query “mobile”, values are "35000.0",
4,
"37500.0", 6,
"40000.0",

Here the gap is 2500.
But if we wish to increase or decrease the gap between the price facet value, we can achieve this by using f.price.facet.range.gap parameter in request.

9. Breadcrumbs

The breadcrumb parameter gives the position within the category hierarchy where the results appear. For example, if the visitor searches for “red dress”, the breadcrumb would be:

Sample request:

{
    "breadcrumb": {
        "filterField": "Category1_fq",
        "values": [{
            "id": "FA"
        }],
        "level": 1
    }
}

10. Disabling Facet

If the client has configured facets, the defaults facets are sent in response if unbxd search api is fired.
In case, client wants to disable facet, sending facet=false (default value is true) along with request will disable facet in response.

Sample Request:

https://search.unbxd.io/<api_key>/<siteKey>/search?&q=mobile&facet=false  

Types of facets

Facets are grouped under their respective types, so that it is easy to deserialize them. Currently, we support three types of facets:

  • Text
  • Range
  • Multilevel

Text Facet

Text facets are configured on text fields in the catalog (essentially fields whose values are of text type). For example, color, brand, size etc.

For facet “brand”, for query “mobile”, values are samsung (663), HTC (513) and so on. This means for query mobile, under brand facet, we have Samsung, HTC as filters (values) and total number of products available with that value is also sent. Shopper can select any value among ( Samsung , HTC ..) and that value will be applied as filter in search query.

Range Facet

Range Facets are configured on numeric fields in the catalog (essentially fields whose values are of numeric datatype). For example Price, Discount, Offer etc.

For Range facet, we send the start of the facet range and number of product count between current value and subsequent value. For example, for facet price, for query “mobile”, values are "35000.0",
4,
"37500.0", 6,
"40000.0",

This means, four products are available between price range 35000 and 37500.
Sixare available between the price range 37500 and 40000.

Range Facets allow you to modify the way you want to display facet values by letting you do the following:

  • Modifying the gap of range facet
  • Modify the start of range facet
  • Modify the end of range facet.

Multilevel Facet

You can build a hierarchy in your facet values to enable multi-level navigation and filtering. This pattern is great for long lists of values and to improve discoverability: your users will be able to browse up and down in the levels to refine their search results.

For example
Query = Mobile
Categories are
Mobile & Tablets
Smartphone
Electronics
Using multilevel faceting, You can apply view number of products present in each category and apply these filter directly to narrow down our search.

Have a look at the following category hierarchy tree from garnethill brand:

Holiday & Gifts

Top-Rated

Women's Fashion

|--- Top-Rated Product

|--- Sweaters & Wraps

|--- New Arrivals

|--- The Organic Shop

|--- Eileen Fisher Clothing

|--- Shirts, Tops & Tees

|--- Knit Tops & Tees

|--- Tunics

|--- Shirts & Blouses

|--- Sleepwear

Bedding & Bath

Unbxd API always responds with the category values belonging to each level.

When no facets are selected(or no filters are passed): API responds to the facets belonging to the first level of the category.

When first level of facets are selected: API responds with the second level of category values.

When second level of facets are selected: API responds with the third level of category values.

And so on …

When the category from the last level is selected: API will respond back with the siblings of category values

Configuring Facets

You can use console to configure facets. Learn more about console

Facets can be easily configured from the Manage -> Configure Search -> Configure Facet section of the Console. Learn more.

Merchandize Facets on console

Merchandising section allows you to do the following:

  1. Create different facet for different category pages.
  2. Reposition a facet corresponding to a category page or a search query by simple drag and drop.
  3. Edit the facet properties like facet length, facet display name.
  4. Modify the sort order for your facet. You can sort either by product count or alphabetically.

Note: You can do all of the above for search queries as well as for category pages.

Merchandising facets for search query

Click the link below to know how to do it for search query using console.
How to Merchandise facets for search query using console.

Merchandising facets for category pages

Click the link below to know how to do it for category pages using console.
How to Merchandise facets for category pages using console.