Copying or moving an is resource-intensive and rate-limited.
Move or rename indices
You can move or rename an index within the same Algolia in the Algolia dashboard or with an API client.Moving or renaming an index leaves its existing analytics associated with the original index name.
Algolia starts a new set of analytics under the new name.
For more information,
see Indices and analytics.
Rename indices in the Algolia dashboard
In the Algolia dashboard, you can’t rename replica indices. You also can’t rename primary indices that have replicas.- Go to the Algolia dashboard and select your Algolia application.
- On the left sidebar, select Search.
- Select your Algolia index.
- Select Manage index > Rename.
- Enter the current and new index names and click Rename.
Rename indices with an API client
To run the code examples on this page, install the latest API client. To rename or move an index with the API, you can use:- API clients:
operationIndex - Algolia CLI:
algolia indices move
Rename indices with replicas
Renaming replica indices requires several steps. You can’t move a source index with replicas. You can move an index to a destination index with replicas. Algolia replaces the destination index’s data with the source index’s data, then copies it to the destination’s replicas.Indices used as a Recommend data source
Don’t rename an index used as a data source for Recommend models. Renaming it breaks the relationship between recommended records and their source. Instead:- Copy the index.
- To keep the events you already collected, train a new model on the copied index using the original index as an additional events source.
- After training, switch your apps and services to use the new index.
- Delete the old index and the old model (from the Algolia dashboard).
Copy indices
You can copy an index in the Algolia dashboard or with an API client. Copying an index works as follows:- Copying an index duplicates the records and configuration, including synonyms and rules of an existing index.
- Copying an index doesn’t create a replica. The new index is an independent copy.
- To copy an index between two Algolia applications, use the Algolia CLI.
Copying an index doesn’t copy its analytics data.
Copy indices in the Algolia dashboard
- Go to the Algolia dashboard and select your Algolia application.
- On the left sidebar, select Search.
- Select the Algolia index that you want to copy.
- Select Manage index > Duplicate.
- Select Create a new index or Overwrite an existing index and enter the destination index name.
- If you’re overwriting an existing index, enter
DUPLICATEto confirm. - Click Duplicate.
Copy indices with an API client
To copy indices, you can use:- API clients:
operationIndex - Algolia CLI:
algolia indices copy
scope parameter.
Omit scope to copy the entire index.
When copying an index with the API,
Algolia doesn’t copy the enableReRanking, mode, or replicas settings.
Copy entire indices
To copy an index including records, settings, synonyms, and rules:Copy index settings, synonyms, or rules
To copy parts of an index, use thescope parameter of the operationIndex method.
For example, to copy only the synonyms and settings between indices, but not records or rules:
scope, Algolia replaces the selected settings, synonyms, or rules in the destination index.
Records, settings, synonyms, and rules outside the selected scopes remain unchanged.
For example, if you use the settings scope,
Algolia copies only the settings to the destination index and leaves that index’s records, synonyms, and rules unchanged.