How to Integrate Algolia Recommend with Instagram Ads

Instagram ads

Instagram ads are a very common promotional tool for many industries, especially ecommerce. Promoted ads are injected between the regular feed, presenting a user with a carousel of items to click on and potentially purchase. Instagram offers advertisers an ad targeting algorithm based on internal data, such as user behaviors and shopping preferences, on Meta’s social media platform, as well as an option to include external tracking information from other sources. 

Trends models with Algolia Recommend

The effectiveness of Instagram ads can be optimized by leveraging AI tools for product recommendations. Trends is a set of new models within Algolia Recommend that enable teams to create experiences that can dynamically adapt to emerging trends, removing the need for manual editorial curation.

Recommend provides builders with two new APIs focused on trends: 

  • Trends on items: builders will be able to display the trending items over their whole catalog or simply for a given category or brand (or any facet values, really).  
  • Trends on facet values: builders will be able to display the trending facet values right now for a given category or brand (or any facet values, really). 

Those 2 models can be combined to recommend “trending items per facet name”

The benefits of the Trends model are in discovering early trends, such as product demand growing over time, as opposed to the constant high-demand products like typical best sellers. For highly competitive industries, such as retail, fashion, and beauty, detecting new trends early is a game changer, directly impacting the revenue and brand credibility.

From the customer experience perspective, the immediate benefit is the consistency seen across marketing and promotional assets, on all channels. Customers see the same products recommended to them on the website, while browsing social media, and when they receive promotional emails featuring recommended products. Consistency is key.

How to implement Algolia Recommend with Instagram ads

Instagram offers several options for ad content promotion. With the classic Instagram Ads, the content is selected manually by the advertiser and served by Instagram to the chosen target audiences. The Dynamic Ads option lets advertisers leverage external tracking data in addition to the internal Instagram user behavior data. We will start with integrating Algolia Recommend models with classic Instagram ads and then discuss the enhancement possibilities with dynamic ads.

To start integrating Algolia Recommend with Instagram ads, you will need to follow a two step process.

Step 1: Algolia set up

  1. Upload your catalog data to Algolia
  2. Implement Insights click & conversion events
  3. Implement Recommend (Docs: Trending Recommendations)
  4. Ensure having met minimum traffic volume requirements: Collect at least 10K events within the last 30 days

Step 2: Instagram set up

  1. Set up a Business Manager account – Your account must be verified in order to use the catalog APIs
  2. Upload your Catalog to Business Manager
  3. Dynamically Create a Set of Items in a Catalog by using the Algolia recommend API to fetch the trending items to be added to the set
    1. Fetch the global trending products from Algolia, using the Python client: 
    2. Using the list of trending product ids, create a new Facebook Catalog product set: 
  4. Create your ad campaign, using the product set created above as the product source, and define your target audience
  5. Review and Publish
  6. The trending products are refreshed every 24h, in order to always keep the products displayed in your ad fresh, you will need to update your product set:

Instagram ads in feed showing product recommendations - purses and bags

Instagram ads stories showing recommended products - purse, bag, and scarves


Next steps: enhance and automate the audience targeting

A common marketing tool used for targeted marketing campaigns is a customer data platform. CDPs like Segment, mParticle, and Google Tag Manager collect and unify first-party customer data from multiple sources and then leverage it for targeted and personalized marketing campaigns. When powering Instagram ads with Algolia Recommend Trending Products model, you can use your CDP to define dynamic audiences matching the facets of trending categories, automating the ad audience targeting process.


To integrate Algolia Recommend‘s Trending Products model with your Instagram ads, head to Algolia Code Exchange for implementation instructions, a code sample GitHub repository, and a demo. Or refer back to this blog post!

To implement this solution, you will need to activate Algolia Recommend and set up your Instagram product audiences. Once all of the configurations are completed, your social media ad targeting should become much more accurate and effective.

About the authorsTanya Herman

Tanya Herman

Product Manager
Clément Denoix

Clément Denoix

Software Engineer

Recommended Articles

Powered by Algolia AI Recommendations

Feature Spotlight: Trends Models in Recommend

Feature Spotlight: Trends Models in Recommend

Chuck Meyer

Chuck Meyer

Sr. Developer Relations Engineer
Introducing Algolia Recommend: The next best way for developers to increase revenue

Introducing Algolia Recommend: The next best way for developers to increase revenue

Matthieu Blandineau

Matthieu Blandineau

Sr. Product Marketing Manager
Trending products: The benefits of showing online shoppers what’s hot

Trending products: The benefits of showing online shoppers what’s hot

Catherine Dee

Catherine Dee

Search and Discovery writer