Guides / Managing results

Getting the best results

Relevance touches on every aspect of the Algolia search experience. It governs everything from structuring your data to how the engine queries your indices and orders the results to what your users see as they type.

The aim is to find a general configuration that gets the best results in all situations.

Configuration is about telling Algolia how to search your data. You already began this process while structuring your data, where you told Algolia which attributes to search in and which to use to customize your ranking.

Defining searchable attributes and customizing your ranking are two Must Dos before configuring anything else. These actions alone could get you production-ready.

Getting the best from Algolia

Before going live, though, it’s best to get familiar with Algolia’s key features. Some are immediately useful, like creating synonyms and adding filters and alternative sorts. Others quickly become important, like merchandising, grouping records, and geolocation. Later, as your solution evolves, you’ll take advantage of analytics, Click and Conversion Tracking, Personalization, and A/B testing. Finally, you’ll want to learn the core features of Algolia’s engine, such as Typo Tolerance, Prefix Search, Natural Language Processing (NLP), Detecting User Intent, and others. Knowing how the engine works will be invaluable as you structure your data and fine-tune your results.

The Managing Results section guides you through the entire configuration process, showing how Algolia has solved search’s most common use cases. Along the way, you’ll learn about the engine’s default settings and when you might need to override them, usually rarely. Finally, the guide helps you identify and solve situations that fall outside the norm.

Getting no or too few results

If some key search phrases aren’t returning results or returning what you’d hoped for, you may have to review your content and/or settings.

What’s meant by “relevance”?

Finding results

Finding results consists of defining attributes and text-based comparisons that affect the engine’s choice of which objects to return. These include typos, prefixes, plurals, stop words and other text-based criteria that Algolia uses to enhance relevancy. There are also some non-text-based criteria, such as filtering and geolocation.

Ranking records

Ranking is critical since users should see the results that most closely match their queries first: this is wholly dependent on the order in which records are presented. Algolia’s ranking uses a tie-breaking algorithm where specific criteria order and “bucket” results together and break ties between equal matches.

Index settings and query parameters

There are two ways and times to configure Algolia search:

  • Index settings
  • Query parameters

Index settings occur at “indexing time” - that is, when you are adding, updating, or removing data or merely changing settings directly on the index. These changes are permanent and global - they affect how the data is stored, and every search is affected.

Configuring your query is different. When you send a query to Algolia, you can add parameters that alter the index settings. These parameters are neither permanent nor global; they only affect the current search.

While you can do a lot with query parameters, some settings can only be done at indexing time, as they affect how the data is stored. This can be seen when adding new synonyms or changing typo tolerance settings. Same with query parameters - some settings make sense only at query time, like filtering, geolocation, and defining which attributes to retrieve.

The specific parameter documentation indicates whether a setting is available at indexing time, query time, or both.

Did you find this page helpful?