Number of Days / UNIX Time calculator

  • Calculates the number of days, weeks, hours, minutes, seconds, and UNIX hours between dates.
  • The number of days is counted as "1 day if you cross the date" (not "after 24 hours").
日本語 / English

Begin / End

DateTimeUNIX time
Error: Maybe there are invalid characters or the date limit (275760-09-13T00:00:00Z) has been exceeded.

Days / Elapsed time


UNIX time setting

Time zone (Time difference from UTC)
Set the end date for the Year 2038 problem

UNIX time (POSIX time)

UNIX time is a time representation used internally by the computer. Although it is expressed in seconds, it may be handled in milliseconds.

  • Use the number of seconds that have elapsed since the Unix epoch to represent the date and time.
  • Unix Epoch is 00:00:00 UTC on 1 January 1970.
  • Since it represents the date and time, the leap second is adjusted. Therefore, it does not represent the true number of seconds elapsed like GPS time.

Year 2038 problem

A problem that could cause some computers to malfunction after 03:14:07 UTC on 19 January 2038.

This date is 2147483647 seconds after the UNIX epoch, which is the maximum value for a 32-bit signed integer. Therefore, if UNIX time is handled as an int type, it may overflow in 2038 and malfunction.

Measure 1: Use a 64-bit signed integer (long). In this case, it will be usable until about 300 billion AD. By that time, the earth should be gone, so the way we measure time has changed, and it’s probably not a problem.

Measure 2: If for some reason you cannot use a 64-bit signed integer, you can use a 32-bit unsigned integer. In this case, it will be usable until 6:28:15 on February 7, 2106. Human beings may be extinct, but the earth is still there, so I would like to make it a 64-bit if possible.