What Is a Leap Second?
A leap second is an occasional adjustment that has added a second to UTC to keep it close to the time indicated by Earth's rotation.
Two ways of measuring time
Atomic clocks measure seconds very consistently. Earth's rotation, which underlies the changing position of the Sun in the sky, is not perfectly steady. Over time, the two measures can drift apart. UTC is based on atomic time, with adjustments historically used to keep it within an agreed range of Earth's rotational time.
When an adjustment is made by inserting a second, the minute can contain a displayed second numbered 60. This does not happen at the same time as a leap day. Leap days adjust the calendar's relationship to the seasonal year; leap seconds adjust a time scale's relationship to Earth's rotation.
Why can this affect computers?
Many software systems assume time moves forward in perfectly regular steps. A clock that repeats or inserts a second can surprise software that expects each minute to have exactly 60 ordinary seconds. Distributed services may receive clock updates at slightly different moments, which can complicate event ordering, monitoring and scheduled jobs.
Different systems have handled the adjustment in different ways. Some step the clock, while some spread the adjustment over a period, a practice often called smearing. A smeared clock does not show the same reading as an unsmeared UTC clock during that interval. Software that compares times from different providers should understand the provider's convention.
How Unix timestamps relate
Ordinary Unix timestamps generally do not assign a unique count to every leap second. Many programming interfaces intentionally model days as a regular number of seconds and do not expose a distinct second 60. As a result, a timestamp is convenient for everyday event records but is not always a complete description for scientific measurements that need precise traceability to Earth's rotation or atomic time.
For most calendars, appointments and logs, use the standard date-time tools supplied by a trusted platform. For scientific, navigation or high-precision work, use the time scale and libraries specified by that field rather than inventing a leap-second correction.
Are leap seconds permanent?
The policy for coordinating UTC with Earth's rotation has been under international review. Future systems may handle the relationship differently from historical leap-second additions. Applications should avoid hard-coding assumptions about when a leap second will happen or assuming the historical practice will continue forever.
The NIST leap-second list provides a primary data reference for the historical relationship between TAI and UTC. Check current notices from the relevant timekeeping authorities for future policy changes.
In ordinary conversation, UTC remains a useful global reference and local time zones remain the right way to format civil time. Read What Is UTC? for the broader time standard, and What Is a Leap Year? for the calendar adjustment with a similar name.
Leap second versus leap year
The names sound alike, but the corrections solve different problems. A leap year adds a calendar date to keep a calendar aligned approximately with Earth's trip around the Sun. A leap second is a time-scale adjustment historically used to keep UTC close to Earth's rotation. Leap years happen on a predictable calendar rule; leap seconds have depended on measurements and international decisions.
A leap second does not create another day. It affects how a specific second is labelled at a UTC boundary. Ordinary date applications normally need to follow their platform's time rules rather than implement a leap-second table on their own.
Why distributed software must agree
Systems that receive a time update at slightly different moments can disagree about event order. A server may repeat a timestamp, insert an unusual second, or spread an adjustment over time. Monitoring, databases and distributed logs should not assume that wall-clock readings are perfectly smooth or strictly increasing.
For ordering events inside one process, a monotonic clock is often more reliable than comparing wall-clock timestamps alone. For events shared across systems, use a well-documented synchronization method and account for clock uncertainty. The system's choice of step, smear or other handling should be consistent across components that compare timestamps.
Leap-second labels and timestamp limits
Not every programming language can parse a seconds field of 60. Many Unix-style timestamp interfaces model regular days and do not provide a unique count for the leap second itself. This is convenient for general software, but it means that a normal timestamp may not preserve every detail needed for a measurement tied to a precise time scale.
Applications used for astronomy, satellite navigation, telecommunications or laboratory measurements should use the time-scale definitions and data required by that field. Avoid treating a general-purpose timestamp as a substitute for traceable measurement.
Keep policy assumptions current
UTC coordination policy is determined internationally and can evolve. Historical behavior is not a guarantee of how future systems will represent the relationship between atomic time and Earth's rotation. Software should use current authoritative announcements and maintained libraries rather than hard-coding an assumed date for the next adjustment.
For everyday use, the important practical point is to label timestamps clearly and keep system time-zone and timekeeping data up to date. The wall-clock time guide explains why a display clock can differ from a stable elapsed-time measurement.