Unix timestamp converter

    Current Unix timestamp
    0
    (in milliseconds: 0)
    Advertisement

    How Unix timestamps work

    A Unix timestamp is the number of seconds (or milliseconds) that have elapsed since 1 January 1970 at 00:00:00 UTC — a fixed point in time known as the Unix epoch. It's used by virtually every programming language, database, and operating system to store dates as simple integers, which makes arithmetic easy and avoids timezone ambiguity.

    Why timestamps are always UTC underneath

    A Unix timestamp itself has no timezone — it's a single count of seconds since the epoch, the same number everywhere on Earth at any given instant. The timezone selector on this page only changes how that number is displayed as a human-readable date and time; it doesn't change the underlying timestamp. This is exactly why timestamps are so useful for storing dates in software: there's no ambiguity to resolve later.

    Seconds vs milliseconds

    Unix time is traditionally measured in whole seconds, but JavaScript's Date object and many web APIs use milliseconds instead. This tool detects which one you've entered automatically — a value of 1,000,000,000,000 (13 digits) or more is treated as milliseconds, since a seconds-based timestamp won't reach that many digits until the year 33658.

    Negative timestamps and the Y2038 problem

    A negative timestamp represents a date before 1 January 1970 — this calculator supports them, since JavaScript's Date handles them natively. Separately, systems that store a timestamp as a signed 32-bit integer will overflow on 19 January 2038 — the "Y2038 problem" — but this only affects older 32-bit software; JavaScript and virtually all modern systems use 64-bit integers or floating point and aren't affected.

    Limitations

    Local-time conversions rely on your browser's IANA timezone database, which is kept up to date automatically but can occasionally lag behind a very recent change to a country's daylight-saving rules. For anything before widespread standardised timekeeping (pre-1970 in most of the world), treat results as a literal calendar calculation rather than a record of how time was actually kept at that date.