Power Automate Date Formatting:
How to Use formatDateTime (With Examples)
Ever had Power Automate write a date like 2025-11-20T05:11:55.8785748Z into your Excel sheet?
In this guide, you'll learn how to use the formatDateTime function to turn that robotic string into something clean, readable, and professional.
The Problem: Unreadable Timestamps
When Power Automate captures a timestamp, it uses the ISO 8601 format by default — a standard that's great for computers, but completely unreadable for humans.
The fix is the formatDateTime function in Power Automate. It takes any date/time value and reformats it to look exactly the way you want.
Understanding the formatDateTime Function
The syntax is straightforward:
Three ingredients:
- value — the date/time you want to format (usually a dynamic content field like Timestamp)
- format — the pattern that controls how the date appears, e.g.
'dd/MM/yyyy' - locale — the language/region for the output, e.g.
'en-US'(optional)
Practical Examples
Example 1 — Simple date (day/month/year)
// Output: 10/12/2025
Example 2 — Full date with month name and locale
// Output: 10.December 2025
Example 3 — Date with time
// Output: 10/12/2025 09:30
Format Code Reference Table
Mix and match these codes in the format string to get exactly the output you need:
| Code | What it represents | Example output |
|---|---|---|
| ⏱ Time Formats | ||
| h | Hour (12-hour, no leading zero) | 3 |
| hh | Hour (12-hour, with leading zero) | 03 |
| HH | Hour (24-hour, with leading zero) | 15 |
| mm | Minutes (with leading zero) | 30 |
| ss | Seconds (with leading zero) | 40 |
| tt | AM / PM indicator | PM |
| 📅 Date Formats | ||
| d | Day of month (no leading zero) | 2 |
| dd | Day of month (with leading zero) | 02 |
| ddd | Abbreviated day name | Thu |
| dddd | Full day name | Thursday |
| M | Month number (no leading zero) | 1 |
| MM | Month number (with leading zero) | 01 |
| MMM | Abbreviated month name | Jan |
| MMMM | Full month name | January |
| yy | Two-digit year | 25 |
| yyyy | Four-digit year | 2025 |
Series Navigation
Need Help with Power Automate?
Our certified Microsoft 365 specialists configure Power Automate flows for your business — in plain English, with no jargon.
Get a Free Consultation