Skip to main content
To analyze how users interact with your search experience in your Magento installation, track clicks and conversions. For both the Autocomplete and InstantSearch Results page, you can see which products users click most often, and which searches have the highest conversion rate.
The InstantSearch frontend captures these events. The backend search adapter doesnโ€™t capture click and conversion events on its own. If you need backend rendering, run your store in hybrid mode with InstantSearch to keep tracking analytics.
To enable click and conversion analytics, go to Stores > Configuration > Algolia Search > Click & Conversion Analytics from the Magento Admin panel.

Enable click analytics

Set Enable Click Analytics to Yes to turn on click and conversion analytics. Enable click and conversion analytics in your Magento dashboard This adds the parameter clickAnalytics=true to every search. The default for this setting is No.

DOM selector of a result container on InstantSearch page

Enter a DOM selector for the search results container to define which elements on your page you track. The elements selected must have the data-objectid and data-position attributes. This default DOM selector is .ais-Hits-item a.result, .ais-InfiniteHits-item a.result.

Enable conversion tracking

To determine how well Algolia helps achieve your business objectives, enable conversion tracking. Previous versions of the extension required you to specify which event to track as a conversion: either Add to cart or Place order. From version 3.14 Algolia tracks both types of conversions. To do this, set Enable Click Analytics to Yes: Enable conversion tracking in your Magento dashboard After making this change, save your settings and clear your configuration cache. Hereโ€™s how conversions work:
For an action to count as a conversion, the user must have interacted with your search at least once during the session for that product.
To link searches to conversion events, the extension adds three URL parameters: queryID, objectID, and indexName. You need these for your clicks and conversions to work. For better SEO, use canonical link meta tags for your product pages. To enable canonical links, go to Stores > Configuration > Catalog > Catalog and set Use Canonical Link Meta Tag For Products to Yes. If you use another way to track the queryID, objectID, and indexName parameters for your conversion events, you can remove the URL parameters. Edit the common.js file to do this. From version 2 and later, if you enable conversion tracking, the extension adds URL parameters to the product links in your search. This ties search to a conversion event using the queryID parameter. As best SEO practice, use canonical links for your product pages. Enable this setting by going to Stores > Configuration > Catalog > Catalog > Search Engine Optimization > Use Canonical Link Meta Tag For Products in your storeโ€™s Admin

Revenue analytics

This feature isnโ€™t available on every plan. Refer to your pricing plan to see if itโ€™s included.
Versions 3.14 and later support revenue analytics for qualifying plans. When you enable conversion tracking, Magento also sends revenue data with all Add to cart and Place order conversion events. Revenue data sent to Algolia takes into account any discounts or special pricing that may apply. Discounts apply to conversion event types as follows: To calculate revenue, take the final sale price of an item, after any discounts, and multiply it by the number of items ordered. Magento shopping cart price rules only apply to the entire order. These discounts count only in the revenue data sent with the Place order event.
Version 3.14 uses version 4 of the Algolia PHP API client to support this feature. Version 4 of the client requires PHP 8. Plan the upgrade before deploying to production.

DOM selector of Add to cart buttons

Enter a selector for the Add to cart button if you set the conversion analytics mode to Add to cart. The elements this selector targets must have the data-objectid attribute, a unique product identifier. The default is .action.primary.tocart.
Last modified on September 16, 2026