Epoch
epoch
A fixed reference point in time from which a system measures elapsed time, most commonly January 1, 1970 for Unix systems.
unix-timestamp
A Unix timestamp (also called POSIX time or Epoch time) represents a point in time as the number of seconds elapsed since the Unix Epoch: January 1, 1970, at 00:00:00 UTC. This simple integer representation makes it easy to store, compare, and transmit time values across different systems and programming languages.
Systems that store Unix timestamps as signed 32-bit integers will overflow on January 19, 2038, at 03:14:07 UTC. After this moment, the timestamp wraps to a large negative number, potentially causing catastrophic failures. Most modern systems have migrated to 64-bit integers, which extend the range to approximately 292 billion years in either direction.
Many web APIs return timestamps in Unix format, either as seconds or milliseconds since the epoch. JavaScript's Date.now() returns milliseconds, while Python's time.time() returns seconds as a float. When exchanging timestamps between systems, always clarify whether the value is in seconds or milliseconds to avoid off-by-a-factor-of-1000 bugs.
Was this article helpful?
epoch
A fixed reference point in time from which a system measures elapsed time, most commonly January 1, 1970 for Unix systems.
utc
The primary time standard by which the world regulates clocks and time, serving as the basis for civil timekeeping globally.
Learn what Unix timestamps are, why they count seconds from January 1, 1970, how to convert them to human-readable dates, and what the Year 2038 problem means.
MySQL timezone bugs almost always trace back to a misunderstanding of three layers: server defaults, session settings, and column types. This article explains why TIMESTAMP and DATETIME behave differently, how the time_zone variable interacts with connections, and how to configure JDBC drivers correctly.
Choosing between DATE, TIME, TIMESTAMP, and TIMESTAMPTZ shapes whether your application handles time zones correctly. This article walks through reservation systems, future event scheduling, audit trails, and migration strategy for legacy schemas that ignored time zones.