All tools / Gateway

Snowflake ID to timestamp decoder

Decode a Discord snowflake into its creation time, worker, process, and increment, or build a snowflake for pagination.

(id >> 22) + 1420070400000

The top 42 bits of every Discord id are milliseconds since the Discord epoch (the first second of 2015). The low 22 bits are the internal worker id, process id, and a per-process increment. Snowflakes are 64-bit, so they travel as strings in JSON; decode them with BigInt, never a float.

Related: Interaction 3-second deadline checker · Discord timestamp markdown formatter