# Displaying current times in 2 Time Zones

**URL:** <https://forum.inductiveautomation.com/t/displaying-current-times-in-2-time-zones/88069>\
**Category:** Ignition\
**Tags:** vision\
**Created:** [March 29, 2024, 11:42am UTC](https://forum.inductiveautomation.com/t/displaying-current-times-in-2-time-zones/88069 "2024-03-29T11:42:47Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [March 29, 2024, 1:23pm UTC](https://forum.inductiveautomation.com/t/displaying-current-times-in-2-time-zones/88069/3 "2024-03-29T13:23:22Z")

</div>

Don't do arithmetic on the date object. Use manual formatting for a desired time zone, as described here:

> [@Ignition Perspective Page to show the client System date and time](https://forum.inductiveautomation.com/t/ignition-perspective-page-to-show-the-client-system-date-and-time/73265/8):
>
> Sure. I recommend [DateTimeFormatter.ofPattern()](https://docs.oracle.com/en/java/javase/11/docs/api/java.base/java/time/format/DateTimeFormatter.html#ofPattern(java.lang.String)). But I would move the complexity to a project script module with a DateTimeFormatter instance with your preferred pattern saved as a top level variable. Like so, perhaps: from java.time import ZoneId from java.time.format import DateTimeFormatter defaultFormatter = DateTimeFormatter.ofPattern("YYYY-MM-dd HH:mm") def zonedFormat(ts, zoneid, format=None): formatter = defaultFormatter if format is None else DateTimeFormatter.ofPattern(format) r…

Ignition datetime objects are instances of `java.util.Date`, and are fundamentally UTC. That is, they have no timezone of their own, but display in whatever time zone the JVM is using. That means they can be sent across a network and remain true to the instant in global time with which they were created, regardless of time zone.

The implication is that you should always think about these objects as UTC. Another, more elaborate discussion:

> [@Ignition Timezone of the server](https://forum.inductiveautomation.com/t/ignition-timezone-of-the-server/80848):
>
> Hi guys! My main server at the Michigan, an it's time zone is Chicago. However, my plants are ate the different time zones. I'm already have a lots of widgets that uses function now() for Tag History requests. In expression now() always return server time zone time. I tried to change Project-\>Project Properties-\>Designer-\>Timezone Behavior as well as Project-\>Project Properties-\>General-\> Project Timezone. But this has zero influence on function now(). Does anyone has similar problem?

---

_[View the full topic](https://forum.inductiveautomation.com/t/displaying-current-times-in-2-time-zones/88069)._
