Unix Timestamp Converter - Epoch Time to Date & Back
Date & Time
Convert Unix timestamps and dates. Auto-detect or choose seconds, milliseconds, microseconds, or nanoseconds; copy ISO, RFC, UTC, and local date formats.
Current Unix timestamp
Enable live mode to see it tick
How to use this tool
- Convert a timestamp to a date. Select the "Timestamp → Date" tab, paste a Unix timestamp, choose its unit if needed, and all supported date representations appear instantly.
- Convert a date to a timestamp. Select the "Date → Timestamp" tab, pick a date and time from the date picker, and the corresponding Unix timestamps appear.
- See the current timestamp live. Click "Use now" to fill the converter with the current instant, or click "Enable live" to watch the current Unix seconds tick up every second.
- Copy any value. Click the "Copy" button next to any result row to copy it to your clipboard.
What is a Unix timestamp?
A Unix timestamp (also called epoch time) is the number of seconds (or milliseconds in JavaScript environments) since 1 January 1970, 00:00:00 UTC. It is the most common machine-readable time format because it is timezone-independent and simple to store and compare.
Seconds vs milliseconds: how to tell the difference
A 10-digit number like 1748000000 is usually seconds. A 13-digit number like
1748000000000 is usually milliseconds. JavaScript's Date.now() returns
milliseconds, while Unix command-line tools and many REST APIs return seconds. Select a unit manually
whenever the source tells you which unit it uses.
Auto-detection uses magnitude bands: values below 100 billion are treated as seconds, values from 100 billion to below 100 trillion as milliseconds, values from 100 trillion to below 100 quadrillion as microseconds, and larger values as nanoseconds. These bands work for typical contemporary timestamps, but distant future seconds and older microsecond or nanosecond values can overlap. The Unit menu lets you override the guess instead of relying on digit count alone.
Common date formats explained
- ISO 8601:
2026-01-15T12:30:00.000Z. The international standard. The "Z" means UTC. Widely used in APIs, databases, and logs. Lexicographically sortable. - RFC 2822:
Thu, 15 Jan 2026 12:30:00 +0000. Used in email headers (SMTP, MIME) and HTTP Date headers. - UTC string: Browser-formatted UTC representation.
- Local time: The date and time adjusted to your browser's timezone.
The Year 2038 problem
On 19 January 2038 at 03:14:07 UTC, 32-bit signed Unix timestamps will
overflow, rolling over to a large negative number, representing 13 December 1901. Modern
systems use 64-bit integers, which won't overflow for billions of years. This converter uses
JavaScript's Date for calendar formatting, so its supported range is about 274,000
years on either side of 1970 even when the source integer can represent a longer span.
Developer quick reference
Date.now(): current timestamp in milliseconds (JavaScript)Math.floor(Date.now() / 1000): current timestamp in secondsnew Date(ts * 1000): convert seconds to JavaScript Datedate.toISOString(): ISO 8601 string from a Datedate.getTime(): milliseconds timestamp from a Date
Timezone pitfalls
Unix timestamps are always UTC - they represent the number of seconds since the Unix epoch in
Coordinated Universal Time, with no timezone offset embedded. A common mistake is reading
new Date(timestamp).toString() in JavaScript and assuming the result is UTC;
toString() actually returns the date in the local timezone. To get UTC, use date.toISOString() (UTC) rather than date.toLocaleString()
(local time). The difference can be hours, depending on the user’s location.
Negative timestamps
Dates before January 1, 1970 are represented as negative Unix timestamps. JavaScript handles
negative timestamps correctly via new Date(-62135596800000). However, some
platforms do not: older Excel DATE functions cannot represent pre-1900 dates at all;
MySQL’s TIMESTAMP column type only supports dates from 1970-01-01 to 2038-01-19; PostgreSQL’s
TIMESTAMP and TIMESTAMPTZ types correctly handle the full historical range.
Microsecond precision
Most timestamps are in seconds (10 digits) or milliseconds (13 digits), but some modern
systems provide microsecond precision (16 digits). Go’s time.Now().UnixMicro()
and PostgreSQL’s timestamptz both support microseconds. The Unit menu also accepts
nanoseconds, which are common in some telemetry and language runtimes. For example, a microsecond
timestamp ending in 000000 can be converted to a date without accidentally treating
it as milliseconds.
- Seconds:
1748000000 - Milliseconds:
1748000000000 - Microseconds:
1748000000000000 - Nanoseconds:
1748000000000000000
JavaScript dates have millisecond resolution. When a microsecond or nanosecond value is converted, digits below one millisecond are discarded for the displayed date and millisecond result. Keep the original integer if your workflow needs its sub-millisecond precision. The converter checks the browser’s date range and reports values it cannot format.
Frequently asked questions
What is a Unix timestamp?
A Unix timestamp (also called epoch time) is the number of seconds that have elapsed since 00:00:00 UTC on 1 January 1970. It is a standard way to represent points in time in computer systems because it is timezone-independent and easy to calculate differences between dates.
What is the difference between seconds and milliseconds timestamps?
Most Unix APIs return timestamps in seconds (e.g., 1748000000). JavaScript's Date.now() returns milliseconds (e.g., 1748000000000). Auto-detection uses magnitude bands for seconds, milliseconds, microseconds, and nanoseconds. Since very old or distant-future dates can overlap those bands, use the Unit menu to choose a known source unit.
Can I convert microsecond and nanosecond timestamps?
Yes. Choose Microseconds or Nanoseconds in the Unit menu, or let the converter estimate the unit from magnitude. JavaScript Date displays milliseconds, so digits finer than one millisecond are discarded in the date and millisecond result. Keep the original integer when sub-millisecond precision matters.
What is the maximum Unix timestamp?
The 32-bit signed maximum is 2,147,483,647 (January 19, 2038 at 03:14:07 UTC), the "Year 2038 problem". Signed 64-bit seconds span much farther, but JavaScript Date formats dates only within about 274,000 years of 1970; larger values are outside this converter’s date range.
What is ISO 8601 format?
ISO 8601 is an international standard for representing dates and times. An example is "2026-01-15T12:30:00.000Z" - the trailing "Z" means UTC. It is sortable as a string and widely used in APIs and databases.
What is RFC 2822 format?
RFC 2822 is the date format used in email headers, e.g. "Thu, 15 Jan 2026 12:30:00 +0000". Many email and web standards accept this format.
Why does local time show a different value than UTC?
UTC (Coordinated Universal Time) is the reference timezone with no offset. Local time is adjusted by your browser's timezone offset. For example, UTC 12:00 is 07:00 in EST (UTC−5).
Related tools
- Log Time AnnotatorUse Log Time Annotator to convert log timestamps to local time and add.
- Timezone ConverterUse Timezone Converter to convert any date and time between multiple time.
- Date DifferenceUse Date Difference to calculate the exact number of days, weeks, months,.
- ICS GeneratorUse ICS Generator to create and download ICS (iCalendar) files for any.