Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
shanfaulks
Frequent Visitor

Date fields not reflecting true local time

I have 2 date fields in a report that work perfectly in desktop version, but incorrectly in Service version. 

One date calulation field represents the date "yesterday", and the other shows the date the data was last refreshed. 

 

I have 2 date fields:

1) DAX formula: 
= DATEADD(LASTDATE('Calendar'[Date]),-1,DAY)
2) built into power query

= DateTime.FixedLocalNow()

 

Both fields work to an extent, but in the pubished version of the report, the times/dates don't reflect NZT (which is my time zone). It defaults to UTC which is not correct.

 

My browser and all other time functions on my laptop all work correctly. 

My PC is set to my timezone, my MS office and profile are all set to NZ timezone and lanuage. At a loss to find out why this isn't working properly! 

 

Help would be appreciated. 

 

1 ACCEPTED SOLUTION
collinq
Super User
Super User

Hey @shanfaulks ,

 

A couple of reasons for this can be the date/time of the data itself (ie. you are in NZ, but the data is in the US, so it looks "off") or, your tenant could be set to UTC time and not your time in the service.  And, therefore, "Now()" can be interpreted as UTC time and/or as the time of your tenant, and not where you are.....

 

And, displaying the time SHOULD be in your own time based on your computer but I know that doesn't always work, particularly within the visuals themselves.  I have three links that might be of assistance:.

1. THis is the M code page for the DateTimeZone functions: DateTimeZone functions - PowerQuery M | Microsoft Learn

2. This is another community request over the same idea: Solved: Convert UTC to client time zones? - Microsoft Power BI Community

3. This is a blog about the topic: Dynamic time zone conversion using Power BI – The White Pages (tygraph.com)

 




Did I answer your question? Mark my post as a solution!

Proud to be a Datanaut!
Private message me for consulting or training needs.




View solution in original post

2 REPLIES 2
shanfaulks
Frequent Visitor

Thank you, the links you provided weren't useful for this issue as I had already tried all the functions mentioned. But thanks anyway. 

collinq
Super User
Super User

Hey @shanfaulks ,

 

A couple of reasons for this can be the date/time of the data itself (ie. you are in NZ, but the data is in the US, so it looks "off") or, your tenant could be set to UTC time and not your time in the service.  And, therefore, "Now()" can be interpreted as UTC time and/or as the time of your tenant, and not where you are.....

 

And, displaying the time SHOULD be in your own time based on your computer but I know that doesn't always work, particularly within the visuals themselves.  I have three links that might be of assistance:.

1. THis is the M code page for the DateTimeZone functions: DateTimeZone functions - PowerQuery M | Microsoft Learn

2. This is another community request over the same idea: Solved: Convert UTC to client time zones? - Microsoft Power BI Community

3. This is a blog about the topic: Dynamic time zone conversion using Power BI – The White Pages (tygraph.com)

 




Did I answer your question? Mark my post as a solution!

Proud to be a Datanaut!
Private message me for consulting or training needs.




Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.