# Max number of shards per elasticsearch data node

**URL:** <https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607>\
**Category:** Elasticsearch\
**Created:** [May 4, 2017, 6:19pm UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607 "2017-05-04T18:19:47Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![mruthyu](https://avatars.discourse-cdn.com/v4/letter/m/bb73d2/32.png) [@mruthyu](https://discuss.elastic.co/u/mruthyu)\
**Post date:** [May 4, 2017, 6:19pm UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/1 "2017-05-04T18:19:47Z")

</div>

Is there any limitation on the number of shards a data node can have?

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [May 4, 2017, 6:34pm UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/2 "2017-05-04T18:34:57Z")

</div>

There is no hard limit and it does depend on how much heap you have available. I would generally recommend having hundreds of shards per node rather than thousands.

---

<div class="post-metadata">

**Author:** ![mruthyu](https://avatars.discourse-cdn.com/v4/letter/m/bb73d2/32.png) [@mruthyu](https://discuss.elastic.co/u/mruthyu)\
**Post date:** [May 5, 2017, 7:34pm UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/3 "2017-05-05T19:34:10Z")

</div>

Thanks. As the recommended heap size is 30GB, whether the maximum number of shards per node can be determined?

---

<div class="post-metadata">

**Author:** ![fortikeco](https://avatars.discourse-cdn.com/v4/letter/f/a587f6/32.png) [@fortikeco](https://discuss.elastic.co/u/fortikeco)\
**Post date:** [May 5, 2017, 9:18pm UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/4 "2017-05-05T21:18:07Z")

</div>

42, it depends

---

<div class="post-metadata">

**Author:** ![Christian\_Dahlqvist](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/christian_dahlqvist/32/4617_2.png) [@Christian\_Dahlqvist](https://discuss.elastic.co/u/Christian_Dahlqvist)\
**Post date:** [May 7, 2017, 4:54am UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/5 "2017-05-07T04:54:18Z")

</div>

With a 30 GB heap I would still recommend having hundreds of shards per node. Whether that is low or high hundreds will depend on your use case. In order to be able to hold as much data on the node as possible, make sure that your average shard size is in the range a few GB to a few tens of GB.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 4, 2017, 5:05am UTC](https://discuss.elastic.co/t/max-number-of-shards-per-elasticsearch-data-node/84607/6 "2017-06-04T05:05:14Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
