# Convert a UNIXTIMESTAMP into a human readable Date + Time

**URL:** <https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247>\
**Category:** CMS Development\
**Tags:** javascript\
**Created:** [February 15, 2023, 10:16am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247 "2023-02-15T10:16:12Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![JBurghard](https://avatars.discourse-cdn.com/v4/letter/j/b3f665/32.png) [@JBurghard](https://community.hubspot.com/u/JBurghard)\
**Post date:** [February 15, 2023, 10:16am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/1 "2023-02-15T10:16:12Z")

</div>

We would like to push a meeting time to HubSpot via the Demodesk integration. Unfortunately, we can only get it as a UNIXTIMESTAMP in a single-line text. We want to convert this into a human readable property using custom code. According to the test run, it should work. However, when we send a contact through the workflow, the UNIXTIMESTAMP still remains. Can anyone help us here? Thanks in advance.

 ![JBurghard_0-1676455816172.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/f/4/f44ed6d170d08eb44c77c9c12b0b8caecfb0cc01.png)

 ![JBurghard_1-1676456128568.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/c/6/c63b3edb597e1c71df49cb7e9c3d865be6b24325.png)

 ![JBurghard_2-1676456140045.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/a/4/a4da492d3a5437181fdcd19a8091dbc1ec816662.png)

---

<div class="post-metadata">

**Author:** ![Cereno-Deng](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/cereno-deng/32/25189_2.png) [@Cereno-Deng](https://community.hubspot.com/u/Cereno-Deng)\
**Post date:** [February 16, 2023, 3:30am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/2 "2023-02-16T03:30:16Z")

</div>

Hi Jonas,

Have you checked your workflow action logs for this custom code? You mean the output cx\_\_\_demodesk\_\_meetinglink is still the timestamp not local time string?  
Cereno

---

<div class="post-metadata">

**Author:** ![JBurghard](https://avatars.discourse-cdn.com/v4/letter/j/b3f665/32.png) [@JBurghard](https://community.hubspot.com/u/JBurghard)\
**Post date:** [February 16, 2023, 12:14pm UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/3 "2023-02-16T12:14:18Z")

</div>

Hey Cereno,  
thanks a lot for your help. In the message before, there was a mistake in the property. It should be “cx\_\_\_demodesk\_\_meetinglink”. Either way, it still doesn’t work. The workflow claims that it works, but nothing is visible in the contact.  
Jonas

 ![JBurghard_0-1676549625514.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/2/4/24b8145107686382ed4f87fbdfcdf292e8c501c9.png)

 ![JBurghard_1-1676549650640.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/2/1/213e6890544f192a4bba750391f487e8a460068a.png)

---

<div class="post-metadata">

**Author:** ![Cereno-Deng](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/cereno-deng/32/25189_2.png) [@Cereno-Deng](https://community.hubspot.com/u/Cereno-Deng)\
**Post date:** [February 17, 2023, 2:32am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/4 "2023-02-17T02:32:32Z")

</div>

Hi Jonas,

Your custom code, and the input/output for it are correct. The issue should be from the workflow. The workflow is something like below?

1. Entrollment trigger while meeting time is known
2. That custom code
3. The “cx\_\_\_demodesk\_\_meetinglink” value is inserted into the contact’s property

It’s possible you share the scrrenshot for the workflow?

Cereno

---

<div class="post-metadata">

**Author:** ![JBurghard](https://avatars.discourse-cdn.com/v4/letter/j/b3f665/32.png) [@JBurghard](https://community.hubspot.com/u/JBurghard)\
**Post date:** [February 17, 2023, 8:44am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/5 "2023-02-17T08:44:00Z")

</div>

Hey Cereno,  
sure, here’s a screenshot of the workflow.

 ![JBurghard_0-1676623422542.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/e/0/e0902cde9d7c37251a5f84f72da6391c5cb5eb06.png)

Jonas

---

<div class="post-metadata">

**Author:** ![Cereno-Deng](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/cereno-deng/32/25189_2.png) [@Cereno-Deng](https://community.hubspot.com/u/Cereno-Deng)\
**Post date:** [February 18, 2023, 8:16am UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/6 "2023-02-18T08:16:22Z")

</div>

Hi Jonas,

I created a test environment. The contact has “Meeing Time” and “Meeting Time DE” properties. I change the “Create record” action to “Copy property value” to copy the “cx\_\_\_demodesk\_\_meetinglink” to “Meeting Time DE”, and the result is correct.

 ![CerenoDeng_0-1676708053999.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/6/f/6f97b6f27e67c33a496f50af07333a19d30093d7.png)

 ![CerenoDeng_1-1676708113465.png](https://d2qpr2jzcazej7.cloudfront.net/original/2X/2/291e900d60b5cbff19fe1bcd059570a327d458ec.png)

 ![CerenoDeng_2-1676708173486.png](https://d2qpr2jzcazej7.cloudfront.net/original/3X/2/c/2ca2bacb4792aa72f83518b00d30511d8dbb5514.png)

Cereno

---

<div class="post-metadata">

**Author:** ![kaanaro](https://d10pqhm3lwygmk.cloudfront.net/user_avatar/community.hubspot.com/kaanaro/32/63028_2.png) [@kaanaro](https://community.hubspot.com/u/kaanaro)\
**Post date:** [January 13, 2025, 3:09pm UTC](https://community.hubspot.com/t/convert-a-unixtimestamp-into-a-human-readable-date-time/75247/7 "2025-01-13T15:09:22Z")

</div>

Hello @Cereno-Deng

Thanks for this. I have a similar issue. I am wondering how can we convert the UNIX timestamp above to a Date & Time Picker property on Hubspot?
