# How to filter json messages in logstash for a specific value to get store to different indexes

**URL:** <https://discuss.elastic.co/t/how-to-filter-json-messages-in-logstash-for-a-specific-value-to-get-store-to-different-indexes/150524>\
**Category:** Logstash\
**Created:** [October 1, 2018, 7:51am UTC](https://discuss.elastic.co/t/how-to-filter-json-messages-in-logstash-for-a-specific-value-to-get-store-to-different-indexes/150524 "2018-10-01T07:51:24Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![kprakash\_77](https://avatars.discourse-cdn.com/v4/letter/k/f9ae1b/32.png) [@kprakash\_77](https://discuss.elastic.co/u/kprakash_77)\
**Post date:** [October 1, 2018, 7:51am UTC](https://discuss.elastic.co/t/how-to-filter-json-messages-in-logstash-for-a-specific-value-to-get-store-to-different-indexes/150524/1 "2018-10-01T07:51:24Z")

</div>

I'm new to logstash filter options and I would like to try some thing like filtering json message based on specific value like key=test1 then move that complete message to test1-index similarly if key=test2 then move that message to test2-index. Please help me and thanks in advance.

---

<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:** [October 29, 2018, 7:51am UTC](https://discuss.elastic.co/t/how-to-filter-json-messages-in-logstash-for-a-specific-value-to-get-store-to-different-indexes/150524/2 "2018-10-29T07:51:35Z")

</div>

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