# I have this value in timestamp field 1635527918.1891065. How I convert it in format yyyy/mm/dd?

**URL:** <https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870>\
**Category:** Rasa Open Source\
**Created:** [October 30, 2021, 4:00am UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870 "2021-10-30T04:00:00Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jleon](https://avatars.discourse-cdn.com/v4/letter/j/b77776/32.png) [@jleon](https://forum.rasa.com/u/jleon)\
**Post date:** [October 30, 2021, 4:00am UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870/1 "2021-10-30T04:00:00Z")

</div>

timestamp: 1635527918.1891065

---

<div class="post-metadata">

**Author:** ![ChrisRahme](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/chrisrahme/32/15572_2.png) [@ChrisRahme](https://forum.rasa.com/u/ChrisRahme)\
**Post date:** [October 30, 2021, 4:00pm UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870/2 "2021-10-30T16:00:02Z")

</div>

Welcome to the community 🙂

This is a forum for chatbot-building with [Rasa](https://rasa.com/). General programming questions like yours are better asked on [StackOverflow](https://stackoverflow.com/).

Your question does not have enough info for us to be able to help anyway.

- Which programming language are you using?
- How are you getting that timestamp?
- What have you tried?

Please read “[How to ask a great question](http://forum.rasa.com/t/how-to-ask-a-great-question/15009/2)”, this applies for all coding forums.

---

<div class="post-metadata">

**Author:** ![jleon](https://avatars.discourse-cdn.com/v4/letter/j/b77776/32.png) [@jleon](https://forum.rasa.com/u/jleon)\
**Post date:** [October 30, 2021, 10:52pm UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870/3 "2021-10-30T22:52:27Z")

</div>

Thanks for the info. Just to complete the question, I am trying to query a postpress database for the dates on which the conversations took place. The values ​​are of dates, they are integers and they are in the format in which I asked the question.

---

<div class="post-metadata">

**Author:** ![RodrigoLima](https://avatars.discourse-cdn.com/v4/letter/r/58956e/32.png) [@RodrigoLima](https://forum.rasa.com/u/RodrigoLima)\
**Post date:** [October 31, 2021, 2:25pm UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870/4 "2021-10-31T14:25:45Z")

</div>

If you are using python:

[https://www.programiz.com/python-programming/datetime/timestamp-datetime](https://www.programiz.com/python-programming/datetime/timestamp-datetime)

---

<div class="post-metadata">

**Author:** ![kuldeep](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/kuldeep/32/16929_2.png) [@kuldeep](https://forum.rasa.com/u/kuldeep)\
**Post date:** [November 1, 2021, 6:15am UTC](https://forum.rasa.com/t/i-have-this-value-in-timestamp-field-1635527918-1891065-how-i-convert-it-in-format-yyyy-mm-dd/48870/5 "2021-11-01T06:15:07Z")

</div>

> [@jleon](#):
>
> 1635527918.1891065

hope this will help you. import datetime

# getting local time

local\_time = datetime.datetime.fromtimestamp(1635527918.1891065).strftime(‘%Y-%m-%d %H:%M:%S’) print(local\_time)

# get utc time

utc\_time = datetime.datetime.utcfromtimestamp(1635527918.1891065).strftime(‘%Y-%m-%d %H:%M:%S’) print(utc\_time)
