# Add Static Value in Kibana

**URL:** <https://discuss.elastic.co/t/add-static-value-in-kibana/51629>\
**Category:** Kibana\
**Created:** [June 1, 2016, 11:24pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629 "2016-06-01T23:24:33Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![seth.yes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/seth.yes/32/11788_2.png) [@seth.yes](https://discuss.elastic.co/u/seth.yes)\
**Post date:** [June 1, 2016, 11:24pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/1 "2016-06-01T23:24:33Z")

</div>

I'm simply trying to add the value 100 to be used as a threshold in graphs. Can someone please explain the process here? It seems extremely difficult to do this one simple task..

---

<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:** [June 1, 2016, 11:50pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/2 "2016-06-01T23:50:24Z")

</div>

You cannot do this in KB at the moment, it has no concept of a threshold.

---

<div class="post-metadata">

**Author:** ![seth.yes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/seth.yes/32/11788_2.png) [@seth.yes](https://discuss.elastic.co/u/seth.yes)\
**Post date:** [June 1, 2016, 11:56pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/4 "2016-06-01T23:56:53Z")

</div>

Wow, with Kibana so limited that I can't even add a static value without having to do work in both Logstash and ES, I may just find another solution. That is absolutely ridiculous you can't simply add a static value.

---

<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:** [June 2, 2016, 12:35am UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/5 "2016-06-02T00:35:35Z")

</div>

What is the use case here?

---

<div class="post-metadata">

**Author:** ![seth.yes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/seth.yes/32/11788_2.png) [@seth.yes](https://discuss.elastic.co/u/seth.yes)\
**Post date:** [June 2, 2016, 2:49pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/6 "2016-06-02T14:49:18Z")

</div>

I'm monitoring metrics that are being passed into my ELK stack. I simply need to show a threshold on the graphs that metrics should not reach.

---

<div class="post-metadata">

**Author:** ![LeeDr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leedr/32/9289_2.png) [@LeeDr](https://discuss.elastic.co/u/LeeDr)\
**Post date:** [June 2, 2016, 3:07pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/7 "2016-06-02T15:07:46Z")

</div>

I haven't tried this but I'm thinking you could add a scripted field to your index with a hard-coded value.

---

<div class="post-metadata">

**Author:** ![LeeDr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leedr/32/9289_2.png) [@LeeDr](https://discuss.elastic.co/u/LeeDr)\
**Post date:** [June 2, 2016, 3:20pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/8 "2016-06-02T15:20:50Z")

</div>

Although I could add a scripted field with value of 100, I haven't figured out how to chart it along with some other fields value yet.

---

<div class="post-metadata">

**Author:** ![LeeDr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/leedr/32/9289_2.png) [@LeeDr](https://discuss.elastic.co/u/LeeDr)\
**Post date:** [June 2, 2016, 3:31pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/9 "2016-06-02T15:31:58Z")

</div>

Check it out. I created several scripted fields at different values so I could use one in the appropriate scale for the value I was charting it against. I turned off the 'circles' checkbox in the options so my threshold line was smooth.

edited to show an 'upper' and 'lower' threshold

 ![](https://us1.discourse-cdn.com/elastic/original/2X/d/d7cd3da2e794181ce7b8bb040ead84445ff613d3.png)

---

<div class="post-metadata">

**Author:** ![tbragin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/tbragin/32/45166_2.png) [@tbragin](https://discuss.elastic.co/u/tbragin)\
**Post date:** [June 2, 2016, 5:30pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/10 "2016-06-02T17:30:06Z")

</div>

@LeeDr nice trick! works great with line charts. For those of you trying this with Area charts, may not work as well, so we're still tracking an issue for it: [https://github.com/elastic/kibana/issues/5037](https://github.com/elastic/kibana/issues/5037) Feel free to +1

---

<div class="post-metadata">

**Author:** ![seth.yes](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/seth.yes/32/11788_2.png) [@seth.yes](https://discuss.elastic.co/u/seth.yes)\
**Post date:** [June 2, 2016, 7:19pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/11 "2016-06-02T19:19:21Z")

</div>

Thanks everyone. While scripted fields do the job somewhat, they don't appear to be the ideal solution.

Reason being that I am gathering data for more than one host, and when I create a scripted field (e.g. oneMillion in the example from @LeeDr), that same scripted field gets replicated for each host. Thus if I'm monitoring 100 nodes, that scripted field shows 100 times.

Any ideas that would stop this from replicating so often?

 ![](https://us1.discourse-cdn.com/elastic/original/2X/9/9a7f2fc92faf3731a3cbfbaf10df09e6c506ed93.png)

---

<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:** [July 6, 2017, 1:51pm UTC](https://discuss.elastic.co/t/add-static-value-in-kibana/51629/12 "2017-07-06T13:51:42Z")

</div>


