Contextual merchandising requires you to use [Recommendations v2 APIs](🔗)
We recommend that you review the following guides before proceeding:
[Widget Configurator](🔗): This guide walks you through the process of configuring your widgets.
[Pathways and Recommendations Merchandising](🔗): This guide walks you through the process of merchandising your widgets.
## **What is Contextual Merchandising**
Contextual Merchandising feature generates dynamic product recommendations based on the attributes of the products your users are currently viewing.
## **How does Contextual Merchandising work**
Contextual Merchandising identifies the attribute values of the product being viewed and displays **dynamic recommendations** with similar attribute values. These context-based recommendations adjust dynamically to the product description attributes on the product description page.
For instance, if your user is viewing the product page of Nike Air Max, you want to populate the Similar Products Recommendations widget with products of the same attributes. You can apply a Contextual Merchandising rule that takes reference from the attributes of the Nike Air Max product and displays recommendations with similar attributes.
**Merchandising operations**: You can apply the boost/bury/include only/exclude merchandising operations to your contextual attribute rules.
## **Supported Widgets and Algorithms**
Contextual merchandising is available as an attribute filter for Product description attributes. This feature is currently supported for Item-based widgets and works on the following algorithm types:
Frequently Viewed together
Frequently Bought together
## **Why is Contextual Merchandising valuable for your business**
**Relevant search experience**: Contextual merchandising enables you to display the best set of relevant product recommendations. This creates a relevant search experience for your users.
**Quicker conversions, more revenue:** As dynamic recommendations adjust to the context, users can easily find related products on your site. This improved findability leads to quicker conversions and more revenue for your business.
## **How to create a Contextual Merchandising rule**
**Note**: Here, we are creating a Contextual Merchandising rule using an already existing widget. Use [this](🔗) guide to create a new widget and then proceed from Step 3.
#### **Step 1**
Go to **`
Pathways & Recommendations`** to view the Widget Configurator.
#### **Step 2**
Find the already created widget. Click the **`
Manage`** \> **`
Widget Global Settings`**. Then, on the Widget Global Rules page, click **`
Manage`** \> **`
#### **Step 3**
In the Product Grid, select the **`
Attribute`** tab to create a new attribute rule.
#### **Step 4**
Go to **`
Create New Attribute Rule `** > **`
Product Description Attributes`**. Choose the desired merchandising operation and the attribute for the rule.
#### **Step 5**
Now, you need to choose a value for the attribute. For contextual recommendations, the attribute **key-value pair** looks like this:
_attribute: Value of the viewed product (\_This makes the attribute value dynamic_)\_
You can select the _Value of the viewed product_ under **`
Dynamic Merchandising`**. Click Done.
The Contextual Merchandising rule appears with a **Context-Based** tag
If you don’t see the option for “_Value of the viewed product_”, check with [Bloomreach Support](🔗) to ensure that you have [Recommendations v2 APIs](🔗) enabled.
## **Preview Recommendations for your Contextual Merchandising rule**
In the Product Grid, click `
Preview` to test your Contextual Merchandising rule. Enter a product ID to preview what products will be recommended contextually for that product.
Let's say you have a contextual rule that boosts products based on the "`
color_groups`" attribute. This rule is set for the Frequently Viewed together widget. Suppose your user is viewing this Red Lounge Cushion shown below. You can preview the Recommendations that your users see when they view this Red Lounge Cushion.
With the contextual rule, red cushions are ranked higher since they are part of the same color group as the product being viewed. Without the contextual rule, the other red cushions are not ranked highly in the Recommendations.
## **Points to Remember**
Numeric Attributes are not supported for Contextual Merchandising.
Attribute rules cannot use "_Value of the viewed product_" at the same time as other attribute values.
## **Conflict Resolution**
In case of conflicts, the same [conflict resolution rules for Search & Merchandising](🔗) rules also apply for Contextual Merchandising. If there are multiple products (that is, multiple product IDs) on the page such that multiple attribute values are passed, then the Contextual Merchandising rule will apply to all values.
Contextual merchandising requires you to use [Recommendations v2 APIs](🔗). Please refer to [this](🔗) guide for understanding the API parameters needed for Contextual Merchandising