Convert GMT to Local Time in Power Automate
Introduction
Date and time values in Power Automate are typically stored in UTC (GMT) format. However, many business processes require displaying dates and times in a user's local timezone. Fortunately, Power Automate provides a built-in Convert Time Zone action that makes it easy to convert GMT/UTC dates into local times without complex calculations.
In this article, we'll explore different ways to convert GMT to local time in Microsoft Flow (now Power Automate).
Why Convert GMT to Local Time?
Converting UTC/GMT time helps organizations:
- Display dates in users' local timezones.
- Improve report readability.
- Send accurate email notifications.
- Avoid confusion caused by time zone differences.
- Support global users across multiple regions.
Prerequisites
Before starting, ensure you have:
- Access to Power Automate.
- A cloud flow.
- A UTC date/time value.
- Basic knowledge of flow actions.
Understanding UTC and Local Time
UTC (GMT): UTC (Coordinated Universal Time) is the standard time format used internally by Power Automate. For example: 2025-06-16T10:00:00Z
Local Time: Local time is the date and time adjusted for a specific region. For example, India Standard Time (IST) might be 16-Jun-2025 03:30 PM.
Method 1: Using the Convert Time Zone Action
This is the easiest and recommended approach.
Step 1: Add the Convert Time Zone Action
In your Power Automate flow, search for and add the Convert Time Zone action.
Step 2: Configure the Fields
- Base Time: Enter your UTC date/time value.
- Source Time Zone: Select 'UTC'.
- Destination Time Zone: Select the desired local time zone (e.g., 'India Standard Time').
- Format String: Specify the desired output format (e.g., 'dd-MM-yyyyhh:mmtt').
Example Input: 2025-06-16T10:00:00Z
Example Output (with 'India Standard Time' and 'dd-MM-yyyyhh:mmtt' format): 16-06-2025 03:30 PM
Power Automate automatically converts UTC to the specified local time.
Method 2: Using the convertTimeZone() Expression
You can also achieve this using Power Automate expressions.
To get the current UTC time converted to India Standard Time:
convertTimeZone(
utcNow(),
'UTC',
'India Standard Time'
)
Custom Date Formatting
To format the converted date, include the format string as the fourth argument:
convertTimeZone(
utcNow(),
'UTC',
'India Standard Time',
'dd-MM-yyyyhh:mmtt'
)
This expression will return the current date and time in IST, formatted as '16-06-2025 03:30 PM'.
Common Time Zones
Here are some common time zones you might use:
- India:
India Standard Time - US Eastern:
Eastern Standard Time - US Pacific:
Pacific Standard Time - United Kingdom:
GMT Standard Time - Australia Eastern:
AUSEastern Standard Time
Note: Always refer to Microsoft's official documentation for the exact supported time zone names.
Convert SharePoint Date to Local Time
Suppose a SharePoint column stores UTC date values. You can access this value using dynamic content, for example, triggerOutputs()?['body/Created']. To convert it to India Standard Time:
convertTimeZone(
triggerOutputs()?['body/Created'],
'UTC',
'India Standard Time'
)
Convert Dynamics 365 Date to Local Time
Similarly, if you have a date field from Dynamics 365, like createdon, you can convert it using the expression:
convertTimeZone(
triggerOutputs()?['body/createdon'],
'UTC',
'India Standard Time'
)
This is particularly useful when sending email notifications or generating reports that need to reflect the user's local time.
Real-Time Business Scenario
A company receives support requests globally. They need to send email notifications to their Indian support team with the request time in the local Indian time.
UTC Time Received: 2025-06-16T09:00:00Z
Expression to use:
convertTimeZone(
'2025-06-16T09:00:00Z',
'UTC',
'India Standard Time',
'dd-MM-yyyyhh:mmtt'
)
Output: 16-06-2025 02:30 PM
This ensures the email displays the correct local time for Indian users.
Common Errors and How to Avoid Them
- Invalid Time Zone Name:
- Incorrect:
IST - Correct:
India Standard Time - Invalid Date Format:
- Incorrect:
16/06/2025 - Correct:
2025-06-16T10:00:00Z(ISO 8601 format)
Always use Microsoft's supported time zone names.
Use ISO 8601 format whenever possible for input, and specify your desired format for the output.
Best Practices
- Store dates in UTC within your systems.
- Convert to local time only when displaying data or for user-facing communications.
- Use the Convert Time Zone action whenever possible, as it's more readable than complex expressions.
- Apply consistent date and time formats for both input and output.
- Test your flows with users from different regions to ensure accuracy.
- Use descriptive variable names for clarity.
Advantages of Time Zone Conversion
- Better user experience.
- Accurate notifications.
- Improved reporting.
- Global application support.
- Reduced date/time confusion.
- Easier maintenance.
Conclusion
Converting GMT (UTC) to local time is a common and essential requirement in Power Automate workflows. By leveraging the Convert Time Zone action or the convertTimeZone() expression, you can easily display date and time values in the desired regional format. Following these best practices ensures accurate reporting, reliable notifications, and a better user experience across your global applications.