ISO 8601 & UTC: Date Formats and Time Zones Explained
When a timestamp is stored as text rather than a number, the format matters — and most date bugs come from ambiguous formats and mishandled time zones. ISO 8601 and UTC are the two conventions that make text dates reliable. Here's how they work.
This is a supporting guide in The Complete Guide to Dates and Times.
Why not just 08/28/26?
Locale formats are ambiguous: 08/28/26 is August 28 in the US, but 28/08/26 elsewhere — and 08/28/26 could even read as a year-first date. Worse, they don't sort correctly as text. A machine-readable, unambiguous format solves both problems.
The ISO 8601 format
ISO 8601 writes date and time from largest unit to smallest:
2026-08-28T14:30:00Z
└─date──┘ └─time─┘└ zone
- Date —
YYYY-MM-DD, always zero-padded T— separates date and time- Time —
HH:MM:SS, 24-hour, optionally with fractional seconds - Zone —
Zfor UTC, or an offset like+05:30
Two properties make it the developer default: it's unambiguous worldwide, and because the fields go big-to-small, sorting the text sorts the dates.
UTC and the "Z"
UTC (Coordinated Universal Time) is the global reference clock. The trailing Z ("Zulu") means "this time is in UTC, offset zero." 2026-08-28T14:30:00Z is the same instant everywhere on Earth; only its wall-clock representation changes by location.
Offsets and local time
A local time is UTC plus or minus an offset: 2026-08-28T20:00:00+05:30 is the same instant as 14:30:00Z. The offset tells you how to convert, but note it describes a moment, not a permanent zone label — the same city can have different offsets across the year.
The daylight-saving trap
That last point is the big one. Many zones shift their offset twice a year for daylight saving time, so "9:00 AM local" isn't a fixed offset from UTC. If you do date math in local time, you'll be off by an hour around the transitions, and one local time can even occur twice. The safe pattern:
Store and compute in UTC (or epoch); convert to local only for display.
Related
Part of The Complete Guide to Dates and Times. See also What Is Unix Time?.
Try it
Paste a date into the Unix Timestamp Converter to see its ISO 8601 (UTC) form alongside your local time — all in your browser.