Weighting results based on facets

We have a scenario where we’d like particular “types” of content (which are identified via a content type facet we have stored in Algolia) to be weighted to appear at the top of our results list - is this possible?

We’ve seen the “Query Rules” option to allow certain results to be promoted based on a given query but this weighting we’d like to apply across any given query against this particular index.

Hi Kyle,

The easiest way for you to achieve this would be an attribute at the top of the ranking formula: featured=true and desc(featured). Everything not present or false will then show at the bottom.

Hope that helps,


Thanks, that makes sense! Just to clarify, would “featured” in this case be a field within the index? Or is it a system property that can be used?

Edit - never mind, gave it a go with a new field and that works as expected. Thanks again!

1 Like