# Logstash date filter timezone not working

**URL:** <https://discuss.elastic.co/t/logstash-date-filter-timezone-not-working/227451>\
**Category:** Logstash\
**Created:** [April 10, 2020, 7:49am UTC](https://discuss.elastic.co/t/logstash-date-filter-timezone-not-working/227451 "2020-04-10T07:49:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![srinika](https://avatars.discourse-cdn.com/v4/letter/s/9fc348/32.png) [@srinika](https://discuss.elastic.co/u/srinika)\
**Post date:** [April 10, 2020, 7:49am UTC](https://discuss.elastic.co/t/logstash-date-filter-timezone-not-working/227451/1 "2020-04-10T07:49:53Z")

</div>

Hi I'm working on date filter and have used timezone. I get the output but the timezone is not working. Can someone please help me?  
Here's the config file

```auto
input { stdin { } }

filter
{

mutate
{
   strip => "message"
}
date {

timezone => "Asia/Kolkata"
locale => "en"
match => ["message", "yyyy-MM-dd-HH:mm:ss.SSSS"]
target => "@timestamp"

}
}
output { stdout { codec => rubydebug } }

```

here's the output

 ![Screenshot (201)](https://us1.discourse-cdn.com/elastic/original/3X/0/4/041e54a0de010364d749fd86fcb4791cec61e804.png)

In the output the timezone is not same as the date i gave in the input

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [April 10, 2020, 1:48pm UTC](https://discuss.elastic.co/t/logstash-date-filter-timezone-not-working/227451/2 "2020-04-10T13:48:14Z")

</div>

@timestamp is always UTC. You have told the date filter that your message is in the Asia/Kolkota timezone, so it moves that back by 5:30 to get to UTC. That all looks perfectly normal to me.

---

<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:** [May 8, 2020, 1:48pm UTC](https://discuss.elastic.co/t/logstash-date-filter-timezone-not-working/227451/3 "2020-05-08T13:48:19Z")

</div>

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