Planning multi-clients widget with algolia

I’m trying to think about the right way to write an web app with algolia.com API. Lets say I have 10 clients that have products I want end-users to search for at their site through my widget. And of course, I have one algolia account which suppose to store all of their products. What is the right way to store their database?

  1. Is it to store all products (which all have the exact same fields) at one index and have some kind of way so that clients could search through only their products?
  2. Or is it to have an index for each client and every client users should search only in their own index?
1 Like

Hi @don,
Both options are technically possible that being said, it’s better to go with the second approach: one index per client. That way you will be able to have

  • different index configuration if needed (typo-tolerance, synonyms)
  • separated analytics
  • the possibility of creating a different a API key each index (see doc)

Best,

1 Like