- Delete everything: removes the index, including records, rules, settings, and synonyms.
- Delete only the records: keeps rules, settings, and synonyms.
Delete indices
Deleting an index removes all records, rules, settings, and synonyms from your Algolia application. Algolia retains the associated analytics data even after index deletion.Indices with replicas
You can’t delete a replica index directly. First, unlink it from its primary index. If you delete a primary index, its replica indices become regular, independent indices.To delete replica indices directly,
use the Algolia CLI
algolia indices delete command:
it automatically un-links them.Delete indices in the Algolia dashboard
- Go to the Algolia dashboard and select your Algolia application.
- On the left sidebar, select Search.
- Select your Algolia index.
- Select Manage index > Delete.
- Type
DELETEto confirm and click Delete.
Delete indices with the API
Delete an index with either of the following:- Algolia CLI:
algolia indices delete(deletes several indices and automatically deletes their replicas) - API clients:
deleteIndex
Delete multiple indices
To delete more than one index:- Use
listIndices(API client) - Use
multipleBatchto delete several indices with a single request.
The
multipleBatch method expects a list of operations.
Don’t wrap these operations in a requests property:
API clients do this automatically.
If you pass something like { requests: [...] }, you’ll get an error such as:
“Requests attribute must be an array.”Clear indices
Clearing an index deletes only the records. Use this option to reindex records but keep your settings, synonyms, and rules.Delete all records from an index in the Algolia dashboard
- Go to the Algolia dashboard and select your Algolia application.
- On the left sidebar, select Search.
- Select your Algolia index.
- Select Manage index > Clear.
- Type
CLEARto confirm and click Clear.
Delete all records from an index with the API
To clear an index and delete all records, use either of the following:- API clients:
clearObjects - Algolia CLI:
algolia indices clear