Understanding replicas - Algolia

Documentation Index

Fetch the complete documentation index at: /llms.txt

Use this file to discover all available pages before exploring further.


Algolia has one ranking formula per index. Every index has a unique sorting strategy but you can’t change it at query time. This is because pre-sorting during indexing instead of at query time leads to a considerable performance boost. The key use of replica indices is they let you provide different rankings for the same data. Algolia lets you automatically replicate the content of one index (the primary) onto other indices (standard and virtual replicas) and synchronize content changes.

Standard and virtual replicas

Standard or virtual replicas are optimized for different use cases:

This feature isn’t available on every plan. Refer to your pricing plan to see if it’s included.

Similarities

Index settings

Replicas start with the same settings as their primary index, but you can change them. For example, to sort:

Algolia applies one sorting strategy to each index. You can only sort by attributes with boolean or numerical values. If you want to sort by dates, convert the dates to Unix timestamps. To keep replica settings in sync with your primary index, set the primary index’s forwardToReplicas parameter to true with the setSettings method.

Differences

Standard replicas Virtual replicas
Records Increases the number of records since it’s a copy of its primary index Doesn’t increase the number of records since it’s just a view of its primary index. It does slightly increase the primary index’s size (but by less than 10 MB per million records)
Usage Optimized for exhaustive sorting Optimized for relevant sorting
Number of replicas per index Unlimited 20
Supported index settings All A subset
Synonyms Supports all synonym types Supports most synonym types, except placeholders
API response that returns the number of hits nbHits nbSortedHits

Manage replicas

For more information about managing replica indices, see:

Supported index settings for virtual replicas

Virtual replicas support a subset of the index settings.

Supported settings

Unsupported settings

You can’t change the following parameters for virtual indices. Instead, change them on the corresponding primary index or create a standard replica.

Last modified on May 19, 2026