# Custom queries in kibana

**URL:** https://discuss.elastic.co/t/custom-queries-in-kibana/91313
**Category:** Kibana
**Created:** [June 29, 2017, 3:37pm UTC](https://discuss.elastic.co/t/custom-queries-in-kibana/91313 "2017-06-29T15:37:52Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![philv](https://avatars.discourse-cdn.com/v4/letter/p/ebca7d/32.png) [@philv](https://discuss.elastic.co/u/philv)
#### Post date: [June 29, 2017, 3:37pm UTC](https://discuss.elastic.co/t/custom-queries-in-kibana/91313/1 "2017-06-29T15:37:52Z")

</div>

Is there a way to run custom queries (more complex ones using Elastic Search syntax) in kibana ?  
I can see you can run such a query in the Console, but not sure how I could run this in the Discover panel.  
I'd like to be able to define the query via json, and the aggregations via the standard UI interface in Discover.  
Is this possible ?

Many thanks,  
Phil

---

<div class="post-metadata">

### Author: ![dsnider](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dsnider/32/44068_2.png) [@dsnider](https://discuss.elastic.co/u/dsnider)
#### Post date: [June 30, 2017, 5:02pm UTC](https://discuss.elastic.co/t/custom-queries-in-kibana/91313/2 "2017-06-30T17:02:47Z")

</div>

Only the query/filter part of the query DSL works in the Kibana search bar. You can see it by creating a filter, then hitting the "edit" icon for it.

 ![](https://d3vv6lp55qjaqc.cloudfront.net/items/1y1j0n1G0m032U3T3H24/Screen%20Recording%202017-06-30%20at%2001.01%20PM.gif?X-CloudApp-Visitor-Id=59773&v=72bb7120)

---

<div class="post-metadata">

### Author: ![philv](https://avatars.discourse-cdn.com/v4/letter/p/ebca7d/32.png) [@philv](https://discuss.elastic.co/u/philv)
#### Post date: [June 30, 2017, 9:42pm UTC](https://discuss.elastic.co/t/custom-queries-in-kibana/91313/3 "2017-06-30T21:42:04Z")

</div>

Perfect

Thanks,  
Phil

---

<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 28, 2017, 9:42pm UTC](https://discuss.elastic.co/t/custom-queries-in-kibana/91313/4 "2017-07-28T21:42:15Z")

</div>

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