Skip to content
100% in your browser. Nothing you paste is uploaded — all processing runs locally. Read more →

The Year 2038 problem

On this page
  1. What overflows, exactly
  2. The exact moment
  3. What’s affected
    1. Definitely safe (64-bit time_t)
    2. Potentially affected (32-bit time_t)
    3. Definitely affected (without action)
  4. Real incidents already
  5. How to check your stack
  6. Languages that handle it natively
  7. What to do today
  8. Try the tool
  9. Related reading
  10. Related across the network

TL;DR. On 2038-01-19 03:14:07 UTC, the signed 32-bit Unix timestamp overflows from 2147483647 to -2147483648, making the system think it’s 1901. Most modern Linux/Unix systems already use 64-bit time_t, but embedded systems, old databases, file formats, and protocols may still be 32-bit. Audit now.

What overflows, exactly

A signed 32-bit integer holds values from -2147483648 to +2147483647. For Unix seconds, that range covers:

-2,147,483,648 = 1901-12-13 20:45:52 UTC
 0             = 1970-01-01 00:00:00 UTC (the epoch)
 2,147,483,647 = 2038-01-19 03:14:07 UTC

At the moment of 2147483647 + 1, the value wraps to -2147483648 — the system interprets the new “now” as 1901-12-13 20:45:52 UTC.

The exact moment

Tuesday, January 19, 2038 at 03:14:07 UTC
= Monday, January 18, 2038 at 22:14:07 EST
= Tuesday, January 19, 2038 at 12:14:07 JST

You can paste 2147483647 into the converter and see the date yourself.

What’s affected

Definitely safe (64-bit time_t)

For these, Y2038 is a non-issue. The 64-bit range covers ~292 billion years — well past any practical horizon.

Potentially affected (32-bit time_t)

Definitely affected (without action)

Real incidents already

Yes — Y2038 has caused production outages already, decades early:

Expect more in the run-up to 2038, especially in audit/compliance code that intentionally sets dates 5–20 years in the future.

How to check your stack

# C / Linux
echo | gcc -E -dM -include <time.h> | grep -i time_t
# Look for sizeof(time_t)

# C check
cat <<'EOF' > t.c
#include <stdio.h>
#include <time.h>
int main(void) {
    printf("sizeof(time_t) = %zu\n", sizeof(time_t));
    return 0;
}
EOF
gcc t.c -o t && ./t
# Want: 8

# Database — Postgres
\d+ table_name
# Look for timestamp / bigint columns; INTEGER on time fields is suspect

# Application code — search for hard-coded 2147483647 or 0x7FFFFFFF
grep -r 2147483647 .
grep -r 0x7FFFFFFF .

If your timestamps are stored as 32-bit anywhere, plan a migration to 64-bit before 2038. The fix is mechanical (column type change + data copy) but disruptive in production.

Languages that handle it natively

If your application code is in any of these on a 64-bit OS, you can ignore Y2038 for application-level time. The risk lives in:

  1. Stored data (database column types)
  2. External systems (embedded devices, legacy mainframes)
  3. Wire protocols (any that hardcode a 32-bit timestamp field)

What to do today

Try the tool

Paste these into the converter to see for yourself: