$(time)
- Syntax
$(time [timezone])- Arguments
- Optional
StreamElements Chatbot offers two time-related variables:
$(time): Displays the current time, optionally in a specified timezone$(time.until): Counts down to a specified time
These variables allow you to enhance your stream chat with real-time clock displays and event countdowns.
Use it
Section titled “Use it”!command add !time It's currently $(time America/New_York) for the streamer$(time)
Section titled “$(time)”$(time)$(time <timezone>)$(time.<timezone>)If no timezone is provided, the variable returns the current UTC time. The output is always in 24-hour HH:MM format, e.g. 21:34 or 09:05.
Parameters
Section titled “Parameters”<timezone>: (Optional) The desired timezone in IANA format. If omitted, UTC is used. The space form$(time America/New_York)and the dot form$(time.America/New_York)are equivalent.
A list of valid IANA timezones can be found at Nodatime Timezones.
Examples
Section titled “Examples”-
Display time in New York:
The current time in New York is $(time America/New_York) -
Display UTC time:
The current UTC time is $(time)
$(time.until)
Section titled “$(time.until)”$(time.until <when>)Parameters
Section titled “Parameters”<when>: The target time, in one of exactly two accepted formats:- A bare 24-hour time, e.g.
19:00. This is interpreted as UTC; if that time has already passed today, it rolls over to the next occurrence. - A full RFC 3339 timestamp, e.g.
2026-09-20T19:00:00-03:00.
- A bare 24-hour time, e.g.
Any other format will make the variable print a parse error in chat.
Output
Section titled “Output”The result is a human-readable duration such as 2 hours 30 mins. If the target time is in the past, ago is appended, e.g. 2 hours 30 mins ago.
Examples
Section titled “Examples”-
Countdown to a time of day (UTC):
Next stream starts in $(time.until 19:00) -
Countdown to a specific date and time:
Upcoming event in $(time.until 2026-09-20T19:00:00-03:00)
Common errors
Section titled “Common errors”-
Invalid Timezone:
- Error message:
unknown time zone lol - Solution: Double-check the timezone name against the Nodatime Timezones list. Ensure you’re using the full IANA name (e.g., “America/Los_Angeles” instead of “PST”).
- Error message:
-
Invalid Timestamp Format:
- Error message:
parsing time "19:00:00-03:00" as "2006-01-02T15:04:05Z07:00": cannot parse "19:00:00-03:00" as "2006" - Solution: Use either a bare 24-hour time (
19:00) or a complete RFC 3339 timestamp (2026-09-20T19:00:00-03:00) — nothing in between.
- Error message:
Q: Can I use abbreviations like EST or GMT with $(time)?
A: No, always use full IANA timezone names like “America/New_York” or “Europe/London” to avoid ambiguity and ensure correct time display.
Q: What timezone does $(time.until 19:00) use?
A: Bare times are always interpreted as UTC. To count down to a time in your local timezone, use a full RFC 3339 timestamp with a UTC offset, e.g. 2026-09-20T19:00:00-03:00.