# Sharing index templates

**URL:** <https://discuss.elastic.co/t/sharing-index-templates/285023>\
**Category:** Elasticsearch\
**Created:** [September 23, 2021, 6:27pm UTC](https://discuss.elastic.co/t/sharing-index-templates/285023 "2021-09-23T18:27:25Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Elitlogik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elitlogik/32/78920_2.png) [@Elitlogik](https://discuss.elastic.co/u/Elitlogik)\
**Post date:** [September 23, 2021, 6:27pm UTC](https://discuss.elastic.co/t/sharing-index-templates/285023/1 "2021-09-23T18:27:25Z")

</div>

I have set up Index Templates and Kibana objects that I think many people out there would like to copy.

Sharing Saved Objects as exported ndjson files is easy.

How can I share Index Templates configuration for other to easily import?

Index templates are containing name, index pattern, mappings, runtime fields and dynamic mapping.

Thank you very much for your support!

---

<div class="post-metadata">

**Author:** ![aaron-nimocks](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aaron-nimocks/32/73965_2.png) [@aaron-nimocks](https://discuss.elastic.co/u/aaron-nimocks)\
**Post date:** [September 23, 2021, 7:13pm UTC](https://discuss.elastic.co/t/sharing-index-templates/285023/2 "2021-09-23T19:13:32Z")

</div>

In Dev Tools `GET _index_template/NAME` and then copy the returned JSON to share.

```auto
{
  "index_templates" : [
    {
      "name" : "fidelis",
      "index_template" : {
        "index_patterns" : [
          "fidelis*"
        ],
        "template" : {
          "settings" : {
            "index" : {
              "number_of_shards" : "1",
              "mapping" : {
                "total_fields" : {
                  "limit" : "10000"
                }
              }
            }
          }
        },
        "composed_of" : [
          "fidelis",
          "meta",
          "ecs"
        ],
        "version" : 1
      }
    }
  ]
}

```

Then they would do a `PUT _index_template/NAME` with a body of the `index_template` that was returned in the `GET`.

```auto
PUT _index_template/fidelis
{
  "index_patterns": [
    "fidelis*"
  ],
  "template": {
    "settings": {
      "index": {
        "number_of_shards": "1",
        "mapping": {
          "total_fields": {
            "limit": "10000"
          }
        }
      }
    }
  },
  "composed_of": [
    "fidelis",
    "meta",
    "ecs"
  ],
  "version": 1
}

```

---

<div class="post-metadata">

**Author:** ![Elitlogik](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/elitlogik/32/78920_2.png) [@Elitlogik](https://discuss.elastic.co/u/Elitlogik)\
**Post date:** [September 23, 2021, 8:49pm UTC](https://discuss.elastic.co/t/sharing-index-templates/285023/3 "2021-09-23T20:49:59Z")

</div>

Thank you very much sir! Will definitely try.

---

<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:** [October 21, 2021, 8:50pm UTC](https://discuss.elastic.co/t/sharing-index-templates/285023/4 "2021-10-21T20:50:36Z")

</div>

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