# Increase document limit/sample size in Discover?

**URL:** https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268
**Category:** Kibana
**Tags:** discover
**Created:** [September 28, 2024, 12:49am UTC](https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268 "2024-09-28T00:49:06Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![juarrow](https://avatars.discourse-cdn.com/v4/letter/j/0ea827/32.png) [@juarrow](https://discuss.elastic.co/u/juarrow)
#### Post date: [September 28, 2024, 12:49am UTC](https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268/1 "2024-09-28T00:49:06Z")

</div>

How do I overcome the "Document count is based on smaller..."-limitation in Kibana's Discover (without Dashboard)?

It seems to have a hard limit on 5000 documents taken into account.

(My date range is set to max; there are \> 400.000 documents in the index; `discover:sampleSize` does seem to only affect the number of entries visible in the table)

![image](https://us1.discourse-cdn.com/elastic/original/3X/2/b/2ba0403786db2c48ff3a1c060333aef0ec2d1b19.png)

---

<div class="post-metadata">

### Author: ![juarrow](https://avatars.discourse-cdn.com/v4/letter/j/0ea827/32.png) [@juarrow](https://discuss.elastic.co/u/juarrow)
#### Post date: [October 11, 2024, 1:56pm UTC](https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268/2 "2024-10-11T13:56:05Z")

</div>

nothing?

---

<div class="post-metadata">

### Author: ![jughosta](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/jughosta/32/107160_2.png) [@jughosta](https://discuss.elastic.co/u/jughosta)
#### Post date: [October 11, 2024, 2:51pm UTC](https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268/3 "2024-10-11T14:51:53Z")

</div>

Hi @juarrow,

Welcome to the community!

This view does not support changing the sample size used for the field statistics aggregation.

What you can try instead, is navigate to Lens:

 ![Screenshot 2024-10-11 at 16.48.11](https://us1.discourse-cdn.com/elastic/original/3X/c/b/cb94138f49d5c1dcef626a7c0b2399766dec05c3.png)

and then switch on "Enable accuracy mode" toggle under Horizontal Axis settings:

 ![Screenshot 2024-10-11 at 16.47.14](https://us1.discourse-cdn.com/elastic/original/3X/2/c/2c4837deb8b929f931d235905f082a01941f2422.jpeg)

---

<div class="post-metadata">

### Author: ![juarrow](https://avatars.discourse-cdn.com/v4/letter/j/0ea827/32.png) [@juarrow](https://discuss.elastic.co/u/juarrow)
#### Post date: [October 14, 2024, 5:52am UTC](https://discuss.elastic.co/t/increase-document-limit-sample-size-in-discover/367268/4 "2024-10-14T05:52:32Z")

</div>

thanks!
