Short answer
UTC is the world's reference clock with no daylight saving time, and Unix time counts seconds (or milliseconds) since 1 January 1970 00:00 UTC; post IDs on X decode to Unix milliseconds.
Key takeaways
- UTC never changes for daylight saving time, which makes it the safe reference for plans and records.
- Unix time is a single number: seconds since 1970-01-01 00:00 UTC. Many systems use milliseconds instead.
- A 10-digit Unix value is usually seconds, a 13-digit one milliseconds.
- ISO 8601 with a Z (2019-12-31T19:26:16Z) is the clearest way to write a UTC time as text.
What is UTC?
UTC (Coordinated Universal Time) is the reference clock every time zone is defined against, and it doesn't change for daylight saving time. New York is UTC−5 in winter and UTC−4 in summer; Tokyo is UTC+9 all year. When you write a time in UTC, nobody needs to know where you were or what season it was.
What is Unix time?
Unix time is the number of seconds since 00:00:00 UTC on 1 January 1970. It's a single integer, so it's easy to store, compare and subtract. Many systems, including JavaScript, count milliseconds instead.
| Form | Example | Notes |
|---|---|---|
| Unix seconds | 1577820376 | 10 digits for dates between 2001 and 2286 |
| Unix milliseconds | 1577820376771 | 13 digits for the same range |
| ISO 8601 / RFC 3339 | 2019-12-31T19:26:16.771Z | The Z means UTC |
| Human, UTC | Tue 31 Dec 2019, 19:26:16 UTC | Clear for reports |
All four rows are the same moment: the creation time of post 1212092628029698048.
How do X post IDs relate to Unix time?
A post ID shifted right by 22 bits is milliseconds since X's own epoch; add 1288834974657 and it becomes Unix milliseconds. X picked an epoch in November 2010 instead of 1970 so the timestamp field wouldn't waste bits on 40 years that had already passed. The Snowflake guide goes through the bits.
How do I avoid the common mistakes?
- Seconds vs milliseconds. Treating milliseconds as seconds gives a date tens of thousands of years in the future; the reverse lands in January 1970. Count the digits.
- Local time disguised as UTC. A spreadsheet that strips the zone from "2019-12-31 14:26 EST" leaves a time that looks like UTC but isn't.
- Big numbers. Post IDs are too large for spreadsheet number cells and JavaScript numbers. Keep them as text. Unix milliseconds are fine.
- Daylight saving ambiguity. 01:30 happens twice on the night clocks go back. In UTC it happens once.
Where do I convert?
The post time decoder turns an ID into UTC, Unix time and local time in one step. The date to post ID tool goes the other way, from a moment to an ID range. The seconds since a post counter is Unix arithmetic you can watch tick.
Questions people ask
Is UTC the same as GMT?
For everyday use, yes: they show the same time. Technically UTC is defined by atomic clocks, and the UK uses GMT only in winter; in summer, UK time is an hour ahead of UTC.
Does Unix time count leap seconds?
No. Unix time treats every day as exactly 86,400 seconds, so leap seconds are absorbed rather than counted. For social media timestamps the difference doesn't matter.
Why does X's API return created_at with .000 milliseconds?
The API reports created_at to the second. The ID itself carries milliseconds, which is why the decoder can be more precise than the API field.