Delete a Replica Index
You can delete a standard or virtual replica through the API or your Algolia dashboard.
Using the API
To delete a standard or virtual replica index through the API, you need to use the
setSettings method on the original index to unlink the replica, then use the
deleteIndex method on the replica index to delete it.
In the below example, we want to delete the
If the primary index has other replica indices which you don’t want to unlink, they should remain in the
1 2 3 4 5 $primary_index->setSettings([ 'replicas' =>  ]); $products_price_asc->delete();
Using the Dashboard
You can also delete replica indices in your Algolia dashboard with the following steps:
- Go to your dashboard and select your primary index from the Indices tab.
- Click on the Replicas tab.
- Click on the Unlink Replica button to remove the relevant replica.
- Don’t forget to save your changes.