跳到主要内容
uencoder

时间戳转换器

在 Unix 时间戳和人类可读日期之间转换,显示 UTC 和本地时间。免费、隐私、100% 客户端运行。自动识别秒(10 位)与毫秒(13 位),支持 ISO 8601 等日期字符串解析,适合调试 API 时间戳、日志分析和跨时区时间转换。

尝试示例:
Local only

最近历史

暂无历史

使用方法

  1. 输入 Unix 时间戳或日期字符串。
  2. 查看 UTC 和本地时间等价表示。
  3. 按需复制结果。

使用此工具的任务

计算 business days between dates
Business day calculation excludes weekends 和 holidays. Learn 到计算工作 days, 添加/subtract business days, 和处理 holidays.
任务
计算 the difference between two dates
Find 时长之间 two dates 在 days, hours, minutes, 或 business days, accounting 为 timezones.
任务
转换 between Unix timestamp, ISO 8601, and human-readable dates
Translate 时间值 之间 Unix epoch 第二, milliseconds, ISO 8601, 和本地/UTC 日期 strings.
任务
转换 between timezones correctly
Timezone conversion 是 tricky 由于 DST, abbreviations, 和 political changes. Learn 到 use IANA timezone names 和 Instant/ZonedDateTime 模式.
任务
生成 Snowflake IDs for distributed systems
Snowflake IDs (Twitter) 组合时间戳, machine ID, 和序列数字为 唯一, sortable IDs 在 distributed systems 无 coordination.
任务
生成 ULIDs for time-sortable identifiers
ULID (Universally 唯一 Lexicographically Sortable Identifier) combines 时间戳具有 random 数据, producing IDs 该排序通过 creation 时间.
任务
解析 a cron expression and explain its schedule in plain English
解码 a cron expression (e.g. '0 9 * * 1-5') into a human-readable schedule, and generate cron expressions from natural language.
任务
将 Unix 时间戳转换为可读日期
把自纪元起的秒或毫秒值转为人类日期,并厘清两个经典困惑:单位与时区。
任务
Use cron expressions 为 scheduling
Cron expressions 定义 recurring schedules 具有 5 fields: minute, hour, day, month, weekday. Learn syntax, 特殊 characters, 和常见 patterns.
任务

使用此工具的管道

常见问题

工具会自动识别秒和毫秒吗?
会。10 位数值视为秒,13 位数值视为毫秒。小于 1e12 的值会乘以 1000。
可以将日期字符串转为时间戳吗?
可以。粘贴任何可被 JavaScript 解析的日期字符串(ISO 8601、RFC 2822 等),工具会返回 Unix 时间戳。
显示哪些输出格式?
工具显示秒和毫秒两种 Unix 时间戳,以及 UTC(ISO 8601)和本地时间表示。
什么是 Unix 纪元?
Unix 纪元是 1970-01-01T00:00:00Z。Unix 时间戳从该参考点计算秒(或毫秒)。负值表示 1970 年之前的日期。
为什么日期字符串在不同浏览器解析结果不同?
非 ISO 日期字符串(如“01/15/2023”)按本地时区解析,可能因浏览器而异。ISO 8601 字符串(如“2023-01-15T10:30:00Z”)解析一致。
2038 问题相关吗?
JavaScript Date 支持到 ±8.64e15 毫秒(275760 年),因此 32 位有符号整数溢出(2038 年 1 月 19 日)不适用。遗留 C 程序可能仍受影响。

相关工具