Unixタイムスタンプ変換器

現在のUnixタイムスタンプ

0

最終更新:

ツールについて

Unix タイムスタンプ変換ツールは 1970-01-01 UTC からの秒数(Unix エポック)と読みやすい日時表記を相互変換します。JWT の iat/exp、DB の created_at、ログ、ファイル mtime など至る所に登場するため、毎回暗算する手間を省きます。

使い方

  1. Read the live "now" timestamp at the top of the page.
  2. Type a Unix timestamp into the input — the human date below updates instantly.
  3. Or pick a date with the picker — the Unix value updates instantly.
  4. Click Now to grab the current timestamp.
  5. Copy whichever representation you need into your code, log query, or test fixture.

主な使用例

  • Converting a Stripe charge’s created field into a human date.
  • Decoding the iat / exp claim of a JWT to debug expiration issues.
  • Translating a log file timestamp into your local time zone.
  • Producing a Unix timestamp for an "expires in N seconds" cache entry.
  • Filling out a database test fixture with a known date.
  • Sanity-checking that a server clock matches the expected epoch.

よくある質問

Q. Are timestamps in seconds or milliseconds?

A. Both are common. Unix tools and most databases use seconds; JavaScript Date.now() returns milliseconds. A 13-digit number is almost always milliseconds; 10 digits is seconds.

Q. What about time zones?

A. Unix timestamps are always UTC by definition. Display formatting is what introduces local time — store UTC, show local.

Q. Will Unix timestamps overflow in 2038?

A. Signed 32-bit timestamps overflow on 2038-01-19. Modern systems use 64-bit timestamps and are safe for billions of years.

Q. Why do JWT exp values look strange?

A. They are seconds since the epoch. iat is when the token was issued; exp is when it expires. Both are in UTC.