Change timezone setting on Strapi server

System Information
  • Strapi Version: 3.4.6
  • Operating System: Microsoft windows server 2019 standard
  • Database: Mongo DB v4.4.0
  • Node Version: v14.15.1
  • NPM Version: 6.14.8
  • Yarn Version:

Hello Strapi Community,

We are using Strapi community edition with Mongo DB as the underlying DB with the respective versions as mentioned in the System information section. I have few questions regarding the time zone settings on the strapi server.

It is noticed that the date time values stored in the Mongo DB is not always reflected correctly in the Strapi UI for the respective field of a given collection.

Example : In our use-case, we insert the documents containing datetime values directly into the Mongo DB but date time value does not show up same as the one inserted when we check it from the strapi UI. As we see below there seems to be a difference in the time part of the value.

  • List item

In DB >> 2021-04-16T07:54:03.600+0000

  • List item

In strapi UI >> April 16 ,2021 13:24

I know this could be due to the time zone setting differences between the strapi server and the DB server, but i could not find a way to sync Strapi time zone setting to be same as the DB server where Mongo DB is running.

Any ideas / Suggestions on how to handle this scenario would be helpful.

Prashanth Kamath

1 Like

Did you find how to fix it? I’m having the same problem, I need the server to start in UTC time since it’s the same one I have in my database, but it always takes the system time zone and I need to be able to control that part.