ModernCalcs

Timestamp to Date Converter

Convert Unix timestamps to human-readable dates and vice versa. Supports seconds and milliseconds.

Result

ISO 8601
2026-08-20T19:49:06.478Z
UTC
Thu, 20 Aug 2026 19:49:06 GMT
Local
8/20/2026, 7:49:06 PM
Date only
2026-08-20
Day of Week
Thursday
Relative
0s ago

Unix Timestamp to Human-Readable Date Converter

Raw Unix timestamps are opaque integers — useful for machines, unreadable for humans. Paste any 10-digit (seconds) or 13-digit (milliseconds) timestamp here and instantly see it rendered as a real date and time in both UTC and your local timezone. No libraries, no uploads, no waiting.

Formula
Date = new Date(timestamp_ms) — for seconds-based: new Date(timestamp_s × 1000)

UTC display: date.toISOString(). Local time: date.toLocaleString(). Specific timezone: date.toLocaleString('en-US', { timeZone: 'Asia/Kolkata' }).

Detecting Seconds vs Milliseconds Automatically

The single most common timestamp confusion is the seconds vs milliseconds mismatch. A 10-digit timestamp measures elapsed seconds (Unix standard, used in C, Python, PHP, most REST APIs). A 13-digit timestamp measures elapsed milliseconds (JavaScript, Java, Kotlin). This tool auto-detects based on digit count and converts accordingly. If you feed a seconds timestamp to JavaScript's new Date() without multiplying by 1000, you will get a date in 1970 — a bug that is surprisingly easy to introduce and hard to spot.

UTC vs Local Time — Understanding the Difference

UTC (Coordinated Universal Time) is the reference timezone — it has no daylight saving offset and never shifts. A Unix timestamp is always relative to UTC. When you convert a timestamp to a readable date, you can display it in UTC (stable, unambiguous) or in the viewer's local time (friendly, but varies by location). For logs, API responses, and database storage, always use UTC. For user-facing displays, apply the user's local timezone offset at render time, not at storage time.

ISO 8601 — the Standard String Format for Timestamps

ISO 8601 is the international standard for date-time strings: 2024-01-15T10:30:00.000Z. The T separates date from time, milliseconds are optional, and the trailing Z denotes UTC. ISO 8601 strings are lexicographically sortable — you can sort them as plain strings and get correct chronological order. JavaScript's Date.toISOString() always produces this format. Use ISO 8601 when you need a human-readable timestamp that's also safe to sort and parse across systems.

Common Sources of Unix Timestamps in the Wild

Timestamps appear throughout modern software stacks. JWT tokens: the iat (issued at) and exp (expiry) fields are seconds-based Unix timestamps. Git commits: every commit has an author timestamp and a committer timestamp stored as Unix time. S3 and cloud storage: object LastModified is returned as an ISO 8601 string derived from an internal Unix timestamp. Database records: PostgreSQL, MySQL, and SQLite all store temporal data internally as Unix timestamps or offsets from epoch. Log files: syslog, nginx, and application logs typically use epoch seconds to avoid timezone ambiguity across distributed server fleets.

Quick Reference

  • JWT token iat/exp fields (always seconds-based Unix timestamps)
  • Git commit timestamps (author date and committer date)
  • S3 / cloud storage LastModified headers
  • Database created_at / updated_at columns
  • Nginx, Apache, and application log entries
  • Unix file system mtime, atime, ctime metadata
  • Payment gateway and webhook event timestamps

Frequently Asked Questions

What is a Unix timestamp?

A Unix timestamp is the total number of seconds elapsed since January 1, 1970 at 00:00:00 UTC (the Unix Epoch). It is timezone-independent — the same timestamp resolves to different local times depending on where you are, but always refers to the same absolute moment in time.

How do I know if my timestamp is in seconds or milliseconds?

Count the digits: a 10-digit timestamp (e.g., 1705312200) measures elapsed seconds. A 13-digit timestamp (e.g., 1705312200000) measures elapsed milliseconds. As a quick check, a valid seconds timestamp for dates after 2001 starts with 1, while a milliseconds timestamp for the same era starts with 1 followed by 12 more digits. If your timestamp has 13 digits, divide by 1000 to get seconds.

How do I convert a timestamp to a readable date in JavaScript?

Use new Date(timestamp * 1000) for a seconds-based (10-digit) timestamp, or new Date(timestamp) for a milliseconds-based (13-digit) one. Then call .toISOString() for UTC, .toLocaleString() for local time, or .toLocaleString('en-US', { timeZone: 'America/New_York' }) for a specific timezone.

What is the maximum Unix timestamp before overflow?

On systems using a signed 32-bit integer for timestamps, the maximum is 2,147,483,647 — which corresponds to January 19, 2038 at 03:14:07 UTC (the Y2K38 problem). After that, the value wraps to a negative number. Modern 64-bit systems have no practical overflow concern — a 64-bit timestamp won't overflow for approximately 292 billion years.

What does a negative Unix timestamp mean?

A negative Unix timestamp represents a date before January 1, 1970. For example, -86400 is December 31, 1969 at 00:00:00 UTC. Most programming languages handle negative timestamps correctly, but some older databases and APIs assume timestamps are non-negative, so negative values may behave unexpectedly in those contexts.

What is ISO 8601 format?

ISO 8601 is an international standard for representing dates and times as strings. The format looks like 2024-01-15T10:30:00Z where the T separates date and time, and the trailing Z indicates UTC. It is sortable as a string, unambiguous, and widely supported across programming languages. JavaScript's Date.toISOString() always outputs ISO 8601 in UTC.

How do I display a timestamp in a user's local timezone?

In JavaScript: new Date(ts * 1000).toLocaleString('en-US', { timeZone: 'Asia/Kolkata' }). In Python: datetime.fromtimestamp(ts, tz=ZoneInfo('Asia/Kolkata')). Always use IANA timezone names (e.g. 'America/New_York', 'Europe/London', 'Asia/Tokyo') rather than abbreviations like EST or IST, which are ambiguous and not handled consistently across runtimes.