# What should be the value of max\_gram and min\_gram in Elastic search

**URL:** <https://discuss.elastic.co/t/what-should-be-the-value-of-max-gram-and-min-gram-in-elastic-search/108717>\
**Category:** Elasticsearch\
**Created:** [November 22, 2017, 1:18pm UTC](https://discuss.elastic.co/t/what-should-be-the-value-of-max-gram-and-min-gram-in-elastic-search/108717 "2017-11-22T13:18:22Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![aniketkk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aniketkk/32/96814_2.png) [@aniketkk](https://discuss.elastic.co/u/aniketkk)\
**Post date:** [November 22, 2017, 1:18pm UTC](https://discuss.elastic.co/t/what-should-be-the-value-of-max-gram-and-min-gram-in-elastic-search/108717/1 "2017-11-22T13:18:22Z")

</div>

Hello, I have a question regarding ngram configurations. Elastic search documentation says

> It usually makes sense to set min\_gram and max\_gram to the same value.

Perhaps, too much of difference between min and max grams will increase the index storage.

But there are many blogs which are using max\_gram as 8 or 20 to get higher accurate results.

I am confused between the two. Which should be the one to use?  
What are pros and cons of both?

Note: My use case deals with indexing of article. Article content is usually of size 150KB.

Thanks

---

<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:** [December 20, 2017, 1:18pm UTC](https://discuss.elastic.co/t/what-should-be-the-value-of-max-gram-and-min-gram-in-elastic-search/108717/2 "2017-12-20T13:18:32Z")

</div>

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