2026-05-11T02:00:08+00:00
yyyy-MM-ddTHH:mm:ssZ — RFC 3339 compliant
Convert between ISO 8601 variants and Unix timestamps. Extended, basic, week date, and ordinal — all with timezone support.
2026-05-11T02:00:08+00:00
yyyy-MM-ddTHH:mm:ssZ — RFC 3339 compliant
20260511T020008+0000
yyyyMMddTHHmmssZ — compact, no separators
2026-W20-1
yyyy-Www-D — ISO week numbering
2026-131
yyyy-DDD — day of year (001–366)
1778464808
seconds since epoch
Press 1–5 to copy a format • N for now
| Variant | Pattern |
|---|---|
| Extended (date + time) | yyyy-MM-dd'T'HH:mm:ssZ |
| Extended (date only) | yyyy-MM-dd |
| Basic (date + time) | yyyyMMdd'T'HHmmssZ |
| Week date | yyyy-'W'ww-E |
| Ordinal date | yyyy-DDD |
| Time only | HH:mm:ss |
Use the date, time, and timezone inputs. All five ISO 8601 variants update automatically.
Extended format is the most compatible. Use basic for compact storage, week date or ordinal for specialized systems.
Click any card to copy. Paste into your API, database query, or code. The Unix seconds card is always included for cross-format conversion.
2026-05-09T18:00:00Z and 2026-05-09T18:00:00+00:00 represent the same moment but are different strings. String comparison will fail. Always parse before comparing.
In JavaScript, new Date("2026-05-09") gives midnight UTC. But new Date("2026-05-09T00:00:00") gives midnight local time. The two can differ by hours. Always include a timezone offset.
ISO 8601 allows fractional seconds (.SSS, .SSSSSS, etc.). Some APIs return milliseconds, others microseconds. If you store and retrieve from a database, ensure your parser handles varying precision, or truncate to the precision you need.
ISO week numbering means January 1 can be in week 52 or 53 of the previous year. 2026-01-01 is in week 1 of 2026, but 2025-01-01 was in week 1 of 2025 (a Wednesday). Always use the ISO week year, not the calendar year, when working with week dates.
ISO 8601 is not a single format — it is a family of representations. The one you almost
certainly want for API work is the extended datetime format with a UTC offset:
2026-05-09T18:00:00Z. This is
also the form mandated by RFC 3339, which is what JSON APIs, HTTP headers, and OpenAPI
specifications refer to when they say "ISO 8601 date."
The basic format (20260509T180000Z) omits all separators. It is rarely seen in APIs but appears in some calendar standards
(iCalendar, vCard) and some legacy EDI systems. The week date (
2026-W19-6) and ordinal date (
2026-129) are even more
niche — useful when your system's natural time unit is a calendar week or day-of-year, such
as in logistics, broadcasting, and some financial reporting contexts.
For maximum compatibility across databases (PostgreSQL, MySQL, SQLite), languages, and cloud services: store timestamps as Unix integers (seconds) in your backend, and format them as extended ISO 8601 at the API boundary. This decouples storage precision from display format and avoids the many edge cases that arise from storing human-readable strings.