# Auto-scaling the number of replicas

**URL:** <https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318>\
**Category:** Elasticsearch\
**Created:** [August 25, 2025, 5:26pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318 "2025-08-25T17:26:29Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Travis\_Andelin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/travis_andelin/32/70186_2.png) [@Travis\_Andelin](https://discuss.elastic.co/u/Travis_Andelin)\
**Post date:** [August 25, 2025, 5:26pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318/1 "2025-08-25T17:26:29Z")

</div>

We typically provision our elasticsearch clusters with a lot of indices, and one replica. The search traffic can vary based on the index.

Sometimes we get a burst of search traffic on one index (usually a node gets CPU bound and the search queue is backed up) and so we resolve it by scaling up the number of replicas.

Does elasticsearch have scaling signals for this type of scenario that could enable us to increase the number of replicas automatically?

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [August 25, 2025, 6:00pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318/2 "2025-08-25T18:00:24Z")

</div>

Do you add more nodes or just increase the number of replicas?

---

<div class="post-metadata">

**Author:** ![Travis\_Andelin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/travis_andelin/32/70186_2.png) [@Travis\_Andelin](https://discuss.elastic.co/u/Travis_Andelin)\
**Post date:** [August 25, 2025, 6:24pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318/3 "2025-08-25T18:24:11Z")

</div>

Typically there are enough nodes in the cluster already, so we just increase the number of replicas as a mechanism to add hardware to the search traffic (e.g., with 1 primary, 1 replica, existing shards for the index under load are only on 2 nodes)

---

<div class="post-metadata">

**Author:** ![leandrojmp](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leandrojmp/32/107231_2.png) [@leandrojmp](https://discuss.elastic.co/u/leandrojmp)\
**Post date:** [August 25, 2025, 6:34pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318/4 "2025-08-25T18:34:20Z")

</div>

Yeah, if it was by adding new nodes, you could use the `auto_expand_replicas` settings, but to just upgrade the number of replicas there is nothing to automate it.

---

<div class="post-metadata">

**Author:** ![Travis\_Andelin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/travis_andelin/32/70186_2.png) [@Travis\_Andelin](https://discuss.elastic.co/u/Travis_Andelin)\
**Post date:** [August 25, 2025, 8:02pm UTC](https://discuss.elastic.co/t/auto-scaling-the-number-of-replicas/381318/5 "2025-08-25T20:02:45Z")

</div>

Would you be aware of any cluster-side signals that would indicate that there are not enough resources on an index to keep up with search traffic?
