Skip to content
Omnikalc

Unix timestamp converter: turn seconds since 1970 into a date

Enter a Unix timestamp and a time zone offset to get the date, the weekday, the time of day, the day of the year, the ISO week, the millisecond form and the years left before 2038.

Updated on
Your inputs

Value out of range

h

Value out of range

Results

Date

November 14, 2023

Day of the week
Tuesday
Time of day (hours and minutes)
10:13 PM
Seconds past the minute
20
Day of the year
318
ISO week number
46
Days since 1970-01-01
19,675
Timestamp in milliseconds
1,700,000,000,000
Years until the 32-bit limit (2038-01-19)
14.2

A Unix timestamp is a count of seconds since 1970, and it is not easy to read at a glance. The Unix timestamp converter takes a timestamp and a time zone offset and gives the date, the day of the week, the time of day, the day of the year, the ISO week number, the timestamp in milliseconds and the years left before the 32-bit limit in 2038.

How the calculation works

  • Local time = timestamp + time zone offset × 3,600. A Unix timestamp counts seconds since 1970-01-01 00:00:00 UTC, without leap seconds.
  • Date = the whole number of days in the local time, divided by 86,400, counted from 1970-01-01. The time of day is the remainder of that division.
  • Day of the week, day of the year and ISO week are worked out from the date in the Gregorian calendar.
  • Milliseconds = timestamp × 1,000, the form used by JavaScript. The 32-bit limit is the timestamp 2,147,483,647, reached on 2038-01-19 at 03:14:07 UTC.

Example

The timestamp 1,700,000,000 with no offset is November 14, 2023, a Tuesday, at 22:13 and 20 seconds UTC. It is the 318th day of the year, in ISO week 46, and 19,675 days after 1970-01-01. In milliseconds it is 1,700,000,000,000. A signed 32-bit counter overflows at 2,147,483,647, which is 14.2 years after this moment.

Why it matters

Developers meet timestamps in logs, databases, APIs and file metadata. A quick conversion helps to read a log line, check an expiry time in a token, compare two events or see whether a system is exposed to the 2038 limit.

Good to know

The calculator uses a fixed offset and ignores daylight saving time, leap seconds and time zone rules. It works for timestamps from 1970 to the year 9999. Negative timestamps, before 1970, are not accepted. For legal or scientific time, use a library that follows the zone database.

The day of the week calculator gives the weekday of any date and the date calculator adds or subtracts days from a date.

Frequently asked questions

What is a Unix timestamp?

It is the number of seconds since 1970-01-01 00:00:00 UTC, called the Unix epoch. It is a single number that does not depend on a time zone, so programs and databases use it to store moments in time. The same timestamp shows a different clock time in each zone.

What is the year 2038 problem?

Older systems store the timestamp in a signed 32-bit integer, whose maximum is 2,147,483,647. That value is reached on January 19, 2038 at 03:14:07 UTC, and the next second wraps to a negative number, which reads as December 1901. Modern systems use 64 bits, which lasts billions of years.

Why does the time look an hour off?

The timestamp is in UTC, and the calculator applies the fixed offset you enter. It does not know about daylight saving time, so in summer you must add the extra hour yourself. For example, Paris is +1 in winter and +2 in summer.

What is the difference between seconds and milliseconds?

Many systems, such as Unix, Python and PHP, count seconds, which gives 10 digits today. JavaScript and Java count milliseconds, which gives 13 digits. If a timestamp looks like the year 55,000, it is probably in milliseconds, and you should divide it by 1,000.

Was this calculator helpful?

Thanks for your feedback!

Results are estimates provided for information purposes. They do not replace professional advice.