| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556 | [[index-prefixes]]=== `index_prefixes`The `index_prefixes` parameter enables the indexing of term prefixes to speedup prefix searches.  It accepts the following optional settings:[horizontal]`min_chars`::  The minimum prefix length to index.  Must be greater than 0, and defaults  to 2.  The value is inclusive.`max_chars`::  The maximum prefix length to index.  Must be less than 20, and defaults to 5.  The value is inclusive.This example creates a text field using the default prefix length settings:[source,console]--------------------------------PUT my-index-000001{  "mappings": {    "properties": {      "body_text": {        "type": "text",        "index_prefixes": { }    <1>      }    }  }}--------------------------------<1> An empty settings object will use the default `min_chars` and `max_chars`settingsThis example uses custom prefix length settings:[source,console]--------------------------------PUT my-index-000001{  "mappings": {    "properties": {      "full_name": {        "type": "text",        "index_prefixes": {          "min_chars" : 1,          "max_chars" : 10        }      }    }  }}--------------------------------
 |