Free tool · exact 64-bit math · runs in your browser
Snowflake ID decoder.
Paste a Discord or X (Twitter) ID and see the exact millisecond it was created, plus the worker and sequence bits. Or go the other way: turn a date into the snowflake you need for a time-range query.
Short answer: shift the ID right by 22 bits and add the epoch. Discord: (id >> 22) + 1420070400000. X/Twitter: (id >> 22) + 1288834974657. The result is Unix milliseconds.
Snowflake IDs
One per line: a Discord user, message or server ID, an X post ID, or your own.
Date to snowflake
The smallest ID that could exist at a moment: use it for "before" / "after" filters in an API.
| ID | Created (UTC) | Unix ms |
|---|
Worked example
Discord's own documentation uses the ID 175928847299117063. Shift it right by 22 bits and you get 42,015,105,796 milliseconds. Add the Discord epoch, 1,420,070,400,000 (the first millisecond of 2015), and you get 1,462,015,105,796: 2016-04-30 11:18:25.796 UTC. The bits below the timestamp say it came from internal worker 1, process 0, and was the 7th ID that process made in that millisecond.
How it works
- Layout. A snowflake is a 64-bit integer. The top 42 bits are milliseconds since the service's epoch; the low 22 bits identify the machine and count IDs made in the same millisecond. Discord splits those 22 bits into a 5-bit worker, a 5-bit process and a 12-bit increment (Discord docs, Snowflakes). Twitter's original Snowflake used a 5-bit datacenter, a 5-bit worker and a 12-bit sequence (IdWorker.scala).
- Formula. created_ms = (id >> 22) + epoch. Discord epoch: 1420070400000 (2015-01-01). X/Twitter epoch: 1288834974657 (2010-11-04 01:42:54.657 UTC).
- Date to snowflake. (ms − epoch) << 22 gives the smallest possible ID for that millisecond. Discord's API accepts these in
before,afterandaroundfor paging messages by time. - Why JavaScript gets these wrong. IDs are bigger than 253, so a plain JavaScript number silently rounds them. This page uses BigInt, which is exact. It is also why Discord and X send IDs as strings in JSON.
Sources
- Discord developer docs: Snowflakes, read Oct 23, 2026
- twitter-archive/snowflake, IdWorker.scala (twepoch = 1288834974657), read Oct 23, 2026
Related
Who made this
Matt Busel, who runs AI agents that post on X all day and reads a lot of IDs. Everything is decoded on your device.