Achieve faster time-to-value with Algolia’s Salesforce Accelerator for B2B Commerce

B2B expectations are changing in the market, and businesses are realizing that to be successful they need to match the digital experience of consumer-focused sites. However, there are the unique characteristics and complexities of B2B business operations that make this difficult:

  • B2B operations typically rely on legacy software, making it harder to migrate to new technologies.
  • B2B businesses have more complexity in the products, from entitlements, to many variants and dynamic pricing and inventory.
  • B2B businesses often operate within highly regulated industries, introducing additional layers of complexity to technology adoption and compliance efforts.

Algolia has partnered with over 1,700 B2B companies, successfully guiding them into the modern digital era. Through the creation of consumer-like search experiences, they’ve improved customer satisfaction, driven higher conversions, and ultimately generated more revenue.

Salesforce Commerce Solution

Salesforce has multiple clouds, from its original CRM to others like case management for a support system and the commerce cloud systems. There are 2 types of commerce systems within Salesforce. The first one is Salesforce Commerce Cloud (SFCC), which is a solution that used to be called Demandware. The other commerce solution is what Salesforce calls B2B / DTC Commerce, that has a B2B component, which is the focus of this article.

B2B / DTC Commerce

The B2B2C Commerce can be separated into B2C Commerce, B2B Commerce, and D2C Commerce and is different from the SFCC solution, it’s within Salesforce’s platform itself. This means it has the use of Products, Pricing and other solutions built into Salesforce. It has more flexibility to be able to be used as more of a B2B solution.

On top of this, Salesforce has a system called Lightning Web Runtime (LWR) that offers very fast performance on the storefront by compiling assets. This works well with Algolia, which is also blazing-fast, and can help with a complex B2B solution.

The Salesforce Accelerator

Algolia has a robust offering that connects to the Salesforce Core platform. It uses Salesforce’s own platform and components to put together an integration that:

  1. Indexes both real-time and bulk indexes to Algolia.
  2. Has a settings application that is used to configure what objects and methods a customer needs to use to index their data.  It’s flexible enough to use any objects in Salesforce. This can be applied to any cloud that Salesforce has in its system.
  3. Has a UI InstantSearch component that uses the settings and displays instant search and Autocomplete. This component you can put on one or multiple pages in the Salesforce commerce storefront.

The benefit of this integration is that it’s a low-code to no-code solution you can implement to your storefront and backend. Once it’s set up in the LWR pages, things will be lightning-fast and super easy for customers to use.

Indexing Data

The Salesforce Accelerator has a backend component that can index the data that is configured via the settings app and send it in batches of 100 to Algolia. Since it uses Salesforce’s Batch and Job functionality, it can handle many thousands of records at once.

Settings Application

The Settings Application has 2 parts to it.  The first part is the object and field mapping system to select what objects you want to use, and for each object, what fields. This is used to build the index as well as set up the templates. The second part is used to configure the InstantSearch and Autocomplete UI components.

UI Components

The Salesforce Accelerator also has an LWC that takes the settings and displays items using a templating system and facet configuration to display items in a way that fits the customer’s needs.


There are several ways to extend the Salesforce Accelerator.

  1. Indexing processors – these are written in Apex and the methods are called when indexing happens, either through an event or from a full index.
  2. LWC Component extensions – these are on the UI side of things and can be extended to solve any UI issues.

Indexing Processors

The backend indexing system can be extended by implementing an Apex interface that is called during the main indexing process. This allows for vast customization in the indexing process where you can customize how the data gets into Algolia.


The connector comes in different layers, where there is the base layer that can work in any Salesforce cloud environment. For example, if you want to index and use a custom CRM page that shows opportunities with accounts, it’s super easy and requires no code to get it done. There is also another layer that sits on top of the base layer that’s commerce specific. This one adds real-time indexing and captures images that are stored in Salesforce’s commerce backend. To customize further, it’s easy to extend either the base layer or the commerce layer to add even more customizations and special cases.

UI Extensions

The InstantSearch component can also be extended at various points, and in fact, there are already extensions in the commerce layer that customize UI related functionality related to commerce, such as selecting a specific price point.

Using the Accelerator for Commerce

Integrating Algolia to Salesforce Lightning Web Components and indexing Salesforce data lets builders create no-code discovery experiences across all of their data.

Algolia consumes both event-driven or batched updates with speed at scale to support a large amount of products. Our experience and success has shown us that while technology alone will not solve this challenge, we do need the industry leading capacity and experts in partnership with your team to make this successful. Which is why Algolia’s success combines people, process, technology, and partnership.

This connector can build in-store experiences by combining commerce with the in-store availability. Apps today know to direct you to a shelf, inform your home store availability, and to tell you how close out of stock items are to you. But we know there are many technical moving parts which make an elegant solution hard. B2B and/or B2C can have very specific needs and use cases. The Salesforce Accelerator can be extended easily to be used for very specific use cases.


While it’s impossible to foresee any specific use cases for a customer’s needs, we feel that with the right tools in place, this Accelerator can be used to get to the right solution faster than if built up from scratch. From being able to manage a potential complex index to an extensible set of UI components, the solution can be used to leverage a complex B2B scenario.


About the authorsDebanshi Bheda

Debanshi Bheda

Global Alliances Director - Algolia
Peter Hale

Peter Hale

Principle Partner Engineer

Recommended Articles

Powered by Algolia AI Recommendations

Drive personalization, performance and growth at scale with AI search on Salesforce

Drive personalization, performance and growth at scale with AI search on Salesforce

Valeriia Pierzinski

Valeriia Pierzinski

Product Marketing Manager, Algolia
Announcing Algolia headless commerce integration for Salesforce Commerce Cloud

Announcing Algolia headless commerce integration for Salesforce Commerce Cloud

Matthieu Blandineau

Matthieu Blandineau

Sr. Product Marketing Manager
AI-powered recommendations in the back office

AI-powered recommendations in the back office

Peter Villani

Peter Villani

Sr. Tech & Business Writer