# Searching based on custom header field in APM index

**URL:** https://discuss.elastic.co/t/searching-based-on-custom-header-field-in-apm-index/209855
**Category:** Elasticsearch
**Created:** [November 28, 2019, 12:38pm UTC](https://discuss.elastic.co/t/searching-based-on-custom-header-field-in-apm-index/209855 "2019-11-28T12:38:25Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![anand\_gt](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/anand_gt/32/47894_2.png) [@anand\_gt](https://discuss.elastic.co/u/anand_gt)
#### Post date: [November 28, 2019, 12:38pm UTC](https://discuss.elastic.co/t/searching-based-on-custom-header-field-in-apm-index/209855/1 "2019-11-28T12:38:25Z")

</div>

Hi Team,

I need to search based on a custom header field, say "context.request.headers.ua-device", I followed below procedure to make that field searchable by changing the index template.

> [@Searching for a custom made header](https://discuss.elastic.co/t/searching-for-a-custom-made-header/200403):
>
> Hi, My development team has created a custom header that is sent along with their requests. Is it possible to do a search for the custom header name or it's value from the search field. I'm trying things listed under context.response.headers but am not having any luck. Thanks.

But even after indexing the field (Exclamation mark corresponding to the field, under Discover, has disappeared), If I perform filtering based on this field it is not working.

I even tried changing index setting of the current APM index, settings.index.query.default\_field, but not helping.

Kindly help me with this.

---

<div class="post-metadata">

### Author: ![anand\_gt](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/anand_gt/32/47894_2.png) [@anand\_gt](https://discuss.elastic.co/u/anand_gt)
#### Post date: [December 5, 2019, 9:25am UTC](https://discuss.elastic.co/t/searching-based-on-custom-header-field-in-apm-index/209855/2 "2019-12-05T09:25:41Z")

</div>

FYI, I'm using Elasticsearch-6.7.1, running on ubuntu -18.04 Bionic OS. Kindly look into this issue

---

<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: [January 2, 2020, 9:25am UTC](https://discuss.elastic.co/t/searching-based-on-custom-header-field-in-apm-index/209855/3 "2020-01-02T09:25:49Z")

</div>

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