# Kibana removing fields from index pattern

**URL:** <https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330>\
**Category:** Kibana\
**Created:** [November 3, 2021, 1:24pm UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330 "2021-11-03T13:24:00Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![hellotty](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/hellotty/32/93445_2.png) [@hellotty](https://discuss.elastic.co/u/hellotty)\
**Post date:** [November 3, 2021, 1:24pm UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/1 "2021-11-03T13:24:00Z")

</div>

Hello.

During the test, I created a lot of fields that are now irrelevant and interfere with the search.  
Can I delete fields that I don't need?

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/6/5/658d0424a33dddb20fbc5c3b06bc9fb735d6f33d.png)

---

<div class="post-metadata">

**Author:** ![majagrubic](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/majagrubic/32/74459_2.png) [@majagrubic](https://discuss.elastic.co/u/majagrubic)\
**Post date:** [November 3, 2021, 2:58pm UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/2 "2021-11-03T14:58:10Z")

</div>

Kibana index pattern fetches fields from the mapping of your indices. The only exceptions are [runtime fields](https://www.elastic.co/guide/en/kibana/current/managing-index-patterns.html#runtime-fields) and [scripted fields](https://www.elastic.co/guide/en/kibana/current/managing-index-patterns.html#scripted-fields), which you can delete from the index management console directly. For every other field created from an Elasticsearch index, you will need to update your mapping and re-index the data. Then you can refresh the index pattern from the management console. This should then remove the fields from the index pattern as well.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [November 4, 2021, 12:27am UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/3 "2021-11-04T00:27:47Z")

</div>

Newer versions of Kibana will auto-refresh fields as well, so there's no refresh button 🙂

---

<div class="post-metadata">

**Author:** ![hellotty](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/hellotty/32/93445_2.png) [@hellotty](https://discuss.elastic.co/u/hellotty)\
**Post date:** [November 11, 2021, 8:46am UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/4 "2021-11-11T08:46:51Z")

</div>

Thanks for the answer.  
I am trying to remove a field using a command in kibana dev tools, but it doesn't work. Tell me, what am I doing wrong?

> POST mdaemon\_smtp\_combine-out-2021.11.10/\_update\_by\_query  
> {  
> "script": "ctx.\_source.remove('mail\_from1')",  
> "query": {  
> "bool": {  
> "must": [  
> {  
> "exists": {  
> "field": "mail\_from1"  
> }  
> }  
> ]  
> }  
> }  
> }

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/c/d/cdbe1dae08191a291c7bbd64c6aa889e9565dceb.png)

---

<div class="post-metadata">

**Author:** ![majagrubic](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/majagrubic/32/74459_2.png) [@majagrubic](https://discuss.elastic.co/u/majagrubic)\
**Post date:** [November 18, 2021, 1:57pm UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/5 "2021-11-18T13:57:27Z")

</div>

The request succeeded, so nothing's wrong. The warning above is unrelated, it's due to your cluster not having authentication enabled.

---

<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 16, 2021, 1:58pm UTC](https://discuss.elastic.co/t/kibana-removing-fields-from-index-pattern/288330/6 "2021-12-16T13:58:00Z")

</div>

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