# Response time vs took

**URL:** <https://discuss.elastic.co/t/response-time-vs-took/336065>\
**Category:** Elasticsearch\
**Created:** [June 15, 2023, 8:55am UTC](https://discuss.elastic.co/t/response-time-vs-took/336065 "2023-06-15T08:55:39Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Faisal\_Afzal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/faisal_afzal/32/122287_2.png) [@Faisal\_Afzal](https://discuss.elastic.co/u/Faisal_Afzal)\
**Post date:** [June 15, 2023, 8:55am UTC](https://discuss.elastic.co/t/response-time-vs-took/336065/1 "2023-06-15T08:55:39Z")

</div>

Elastic search performing very slow it will almost took 3 seconds to return a response, however when i look to `took` attribute it's within 100 ms.  
Not sure why response time is higher? and what does it mean?.

---

<div class="post-metadata">

**Author:** ![dadoonet](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dadoonet/32/137187_2.png) [@dadoonet](https://discuss.elastic.co/u/dadoonet)\
**Post date:** [June 15, 2023, 9:28am UTC](https://discuss.elastic.co/t/response-time-vs-took/336065/2 "2023-06-15T09:28:59Z")

</div>

It might be the network time. What are you measuring exactly?

---

<div class="post-metadata">

**Author:** ![Faisal\_Afzal](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/faisal_afzal/32/122287_2.png) [@Faisal\_Afzal](https://discuss.elastic.co/u/Faisal_Afzal)\
**Post date:** [June 15, 2023, 10:15am UTC](https://discuss.elastic.co/t/response-time-vs-took/336065/3 "2023-06-15T10:15:58Z")

</div>

We are observing a slowness on search query, I was looking to optimize a search performance. when I closely look to a search response, I found it response time is always higher compare to `took`.

Yes you are right. It is related to network latency. I check a complete end to end request. Tcp & SSL handshaking took around 800 ms, Thanks for point it out.

---

<div class="post-metadata">

**Author:** ![stephenb](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/stephenb/32/40856_2.png) [@stephenb](https://discuss.elastic.co/u/stephenb)\
**Post date:** [June 15, 2023, 1:50pm UTC](https://discuss.elastic.co/t/response-time-vs-took/336065/4 "2023-06-15T13:50:46Z")

</div>

If you are running this from Kibana Dev Tools

Response time is the total round trip time... `took` is the time of the actual query took when executed on elasticsearch

---

<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 13, 2023, 1:51pm UTC](https://discuss.elastic.co/t/response-time-vs-took/336065/5 "2023-07-13T13:51:32Z")

</div>

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