Unix time

epochUNIX epoch1 January 19701,111,111,111dateelapsed seconds from some fixed dateepoch timeJanuary 1, 1970January 1st, 1970time values
Unix time (also known as POSIX time or UNIX Epoch time ) is a system for describing a point in time.wikipedia
125 Related Articles

Year 2038 problem

19 January 203832-bit computer clocks overflow2036 Problem
This is referred to as the Year 2038 problem, where the 32-bit signed Unix time will overflow and will take the actual count to negative. At 03:14:08 UTC on Tuesday, 19 January 2038, 32-bit versions of the Unix time stamp will cease to work, as it will overflow the largest value that can be held in a signed 32-bit number ( or 2147483647). Before this moment, software using 32-bit time stamps will need to adopt a new convention for time stamps, and file formats using 32-bit time stamps will need to be changed to support larger time stamps or a different epoch. If unchanged, the next second will be incorrectly interpreted as 20:45:52 Friday 13 December 1901 UTC.
The Year 2038 problem relates to representing time in many digital systems as the number of seconds passed since 1 January 1970 and storing it as a signed 32-bit binary integer.

Leap second

leap secondsabolish the leap secondAnother second
It is the number of seconds that have elapsed since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds. When a leap second occurs, the UTC day is not exactly 86400 seconds long and the Unix time number (which always increases by exactly 86400 each day) experiences a discontinuity.
Leap seconds in Unix time are commonly implemented by repeating the last second of the day.

Tz database

IANA time zone databasetime zone databaseOlson Data
This resembles the manner in which time zone tables must be consulted to convert to and from civil time; the IANA time zone database includes leap second information, and the sample code available from the same source uses that information to convert between TAI-based time stamps and local time.
The database attempts to record historical time zones and all civil changes since 1970, the Unix time epoch.

Epoch (reference date)

epochepochsepoch event
Every day is treated as if it contains exactly 86400 seconds, so leap seconds are to be subtracted since the epoch.

Time

temporaldurationintervals
Unix time (also known as POSIX time or UNIX Epoch time ) is a system for describing a point in time.
Unix epoch

Integer (computer science)

integerintegersint
The Unix time_t data type that represents a point in time is, on many platforms, a signed integer, traditionally of 32bits (but see below), directly encoding the Unix time number as described in the preceding section.

C date and time functions

time tstrftimetime()
The Unix time_t data type that represents a point in time is, on many platforms, a signed integer, traditionally of 32bits (but see below), directly encoding the Unix time number as described in the preceding section.

System time

DATEsystem clocktime
System time
For example, Unix and POSIX-compliant systems encode system time ("Unix time") as the number of seconds elapsed since the start of the Unix epoch at 1 January 1970 00:00:00 UT, with exceptions for leap seconds.

A Deepness in the Sky

Vernor Vinge's novel A Deepness in the Sky describes a spacefaring trading civilization thousands of years in the future that still uses the Unix epoch.
The Qeng Ho's computer and timekeeping systems feature the advent of "programmer archaeologists": the Qeng Ho are packrats of computer programs and systems, retaining them over millennia, even as far back to the era of Unix programs (as implied by one passage mentioning that the fundamental time-keeping system is the Unix epoch:

Unix

Unix-likeUNIX-basedUX
At 23:31:30 UTC on Friday, 13 February 2009, the decimal representation of Unix time reached 1234567890 seconds (like the number row on a keyboard). In some parts of the world, this day fell on Friday the 13th in the Gregorian calendar, or Saturday, 14 February, for locations from France east to the International Date Line. Google celebrated this with a Google doodle. Parties and other celebrations were held around the world, among various technical subcultures, to celebrate the 1234567890th second.
Unix time

2,147,483,647

21474836472 31 − 12147483647 (number)
At 03:14:08 UTC on Tuesday, 19 January 2038, 32-bit versions of the Unix time stamp will cease to work, as it will overflow the largest value that can be held in a signed 32-bit number ( or 2147483647). Before this moment, software using 32-bit time stamps will need to adopt a new convention for time stamps, and file formats using 32-bit time stamps will need to be changed to support larger time stamps or a different epoch. If unchanged, the next second will be incorrectly interpreted as 20:45:52 Friday 13 December 1901 UTC.
The data type time_t, used on operating systems such as Unix, is a signed integer counting the number of seconds since the start of the Unix epoch (midnight UTC of 1 January 1970), and is often implemented as a 32-bit integer.

Second

ssecmegasecond
It is the number of seconds that have elapsed since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.

Coordinated Universal Time

UTCUTC-3UTC-4
It is the number of seconds that have elapsed since 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC), minus leap seconds.

Scalar (mathematics)

scalarscalarsbase field
The first layer encodes a point in time as a scalar real number which represents the number of seconds that have passed since 00:00:00UTC Thursday, 1 January 1970.

Real number

realrealsreal-valued
The first layer encodes a point in time as a scalar real number which represents the number of seconds that have passed since 00:00:00UTC Thursday, 1 January 1970.

Gregorian calendar

GregorianN.S.NS
At 23:31:30 UTC on Friday, 13 February 2009, the decimal representation of Unix time reached 1234567890 seconds (like the number row on a keyboard). In some parts of the world, this day fell on Friday the 13th in the Gregorian calendar, or Saturday, 14 February, for locations from France east to the International Date Line. Google celebrated this with a Google doodle. Parties and other celebrations were held around the world, among various technical subcultures, to celebrate the 1234567890th second. As is standard with UTC, this article labels days using the Gregorian calendar, and counts times within each day in hours, minutes, and seconds.

International Atomic Time

TAIatomic timeTemps Atomique International
Some of the examples also show International Atomic Time (TAI), another time scheme which uses the same seconds and is displayed in the same format as UTC, but in which every day is exactly 86400 seconds long, gradually losing synchronization with the Earth's rotation at a rate of roughly one second per year.

Synchronization

synchronoussynchronizedsynchronize
Some of the examples also show International Atomic Time (TAI), another time scheme which uses the same seconds and is displayed in the same format as UTC, but in which every day is exactly 86400 seconds long, gradually losing synchronization with the Earth's rotation at a rate of roughly one second per year.

ISO 8601

ISO 8601:200452 weeksa number of contexts
For brevity, the remainder of this section uses ISO 8601 date and time format, in which the Unix epoch is 1970-01-01T00:00:00Z.

Continuous function

continuouscontinuitycontinuous map
The above scheme means that on a normal UTC day, which has a duration of 86400 seconds, the Unix time number changes in a continuous manner across midnight.

Classification of discontinuities

discontinuitiesdiscontinuousdiscontinuity
When a leap second occurs, the UTC day is not exactly 86400 seconds long and the Unix time number (which always increases by exactly 86400 each day) experiences a discontinuity.

Network Time Protocol

NTPNetwork TimeNTP server
A Unix clock is often implemented with a different type of positive leap second handling associated with the Network Time Protocol (NTP).

David L. Mills

Dave MillsDavid MillsMills
Commonly a Mills-style Unix clock is implemented with leap second handling not synchronous with the change of the Unix time number.

Civil time

civil dayclock time
This resembles the manner in which time zone tables must be consulted to convert to and from civil time; the IANA time zone database includes leap second information, and the sample code available from the same source uses that information to convert between TAI-based time stamps and local time.

Bit

binary digitbitsbinary digits
The Unix time_t data type that represents a point in time is, on many platforms, a signed integer, traditionally of 32bits (but see below), directly encoding the Unix time number as described in the preceding section.