How the timestamp markup works
Discord renders a special markup that displays a moment in each viewer's own time zone. The syntax is a Unix timestamp in seconds wrapped in angle brackets with a t: prefix and an optional format letter — so the same message shows 3pm to someone in London and 4pm to someone in Berlin, with no ambiguity and no conversion by hand.
The timestamp must be in seconds, not milliseconds. JavaScript's Date.now() returns milliseconds, so pasting that value directly produces a date tens of thousands of years in the future — the most common mistake when generating these programmatically. Divide by 1,000 and round down.
The format letter selects the presentation: short and long forms of time, date, and combined date and time, plus a relative format that renders as "in 2 hours" or "3 days ago" and updates itself as time passes. Omitting the letter gives the default short date-time.
Choosing a format
The relative format is the most useful for anything upcoming, because it answers the question people actually have — how long until this — without requiring mental arithmetic. It is the right choice for event countdowns and deadlines.
Absolute formats suit anything that needs to be unambiguous in a log or a pinned message, where a relative time becomes meaningless once read later. The long date-time format including the day of the week is worth using for scheduled events, since the weekday is what most people actually anchor on.
Combining two is often best: an absolute time so the moment is clear, followed by a relative one in brackets so the urgency is immediate. This is what most well-run event announcements do.
Where it works and where it does not
The markup renders in messages, embeds and most places Discord displays formatted text. It does not render everywhere — channel names, channel topics and some interface elements show the raw text instead, which is a common surprise when trying to put a countdown in a channel name.
Timestamps are rendered client-side from the viewer's system clock and time zone, so a viewer whose device clock is wrong sees a wrong relative time. This is worth remembering when someone reports that a countdown is off.
Because it displays in local time automatically, it removes the need to write out multiple time zones in an announcement — which is both cleaner and less error-prone than doing the conversion yourself. If you do need to work out what a moment is elsewhere, the timezone converter handles that, and the timestamp converter converts between Unix values and readable dates.