Skip to content

Epoch & Unix Timestamp Converter

Convert Unix timestamps to human-readable dates and formats in UTC, ISO 8601, and your local timezone. Works with seconds, milliseconds, microseconds, and nanoseconds.

Enter a Unix timestamp (seconds or ms) or a date string like "2024-01-15 10:30:00"

UTC Date/Time
Tue, 14 Nov 2023 22:13:20 GMT
ISO 8601
2023-11-14T22:13:20.000Z
Local Date/Time
11/14/2023, 10:13:20 PM
Unix Timestamp (seconds)
1,700,000,000
Unix Timestamp (milliseconds)
1,700,000,000,000
Input Detected As
Detected as: seconds

Como funciona

Fórmula

Date = new Date(timestamp × 1000) | Epoch = Math.floor(Date.now() / 1000)

Exemplo prático

Epoch timestamp 1700000000 converts to Tuesday, November 14, 2023 10:13:20 PM UTC (or 2023-11-14T22:13:20Z).

Understanding Unix Timestamps and the Epoch

The Unix epoch is the universal reference point used across operating systems, distributed databases, cloud APIs, and programming runtimes to measure time independently of geographical time zones and daylight saving time (DST) shifts.

Seconds vs. Milliseconds vs. Microseconds

When debugging API payloads or database records, identifying the unit of measurement is the most common hurdle:

UnitNumber of DigitsExampleCommon Runtime / Use Case
Seconds10 digits1742400000Linux CLI, Unix kernel, Redis, JWT expiry
Milliseconds13 digits1742400000000JavaScript, Java, MongoDB ISODate
Microseconds16 digits1742400000000000Python datetime, Cassandra, PostgreSQL
Nanoseconds19 digits1742400000000000000Go time.Now().UnixNano(), InfluxDB

Common Conversion Snippets

  • JavaScript / Node.js:
    // Current epoch seconds
    const sec = Math.floor(Date.now() / 1000);
    // Epoch to Date
    const date = new Date(1742400000 * 1000);
  • Python 3:
    import time
    from datetime import datetime, timezone
    # Epoch to UTC string
    utc_time = datetime.fromtimestamp(1742400000, tz=timezone.utc)
  • PostgreSQL:
    SELECT TO_TIMESTAMP(1742400000);

Perguntas frequentes

What is Unix Epoch time?

Unix epoch time (or POSIX time) is the number of seconds that have elapsed since 00:00:00 UTC on Thursday, 1 January 1970, not counting leap seconds.

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

Standard 10-digit integers (e.g. 1700000000) represent seconds. Standard 13-digit integers (e.g. 1700000000000) represent milliseconds (used by JavaScript `Date.now()`). 16-digit timestamps represent microseconds, and 19-digit timestamps represent nanoseconds.

What is the Year 2038 problem (Y2038)?

On January 19, 2038 at 03:14:07 UTC, 32-bit signed integers will overflow from 2,147,483,647 to -2,147,483,648, wrapping back to the year 1901. Modern 64-bit systems are immune and safe for billions of years.

How do I get the current epoch timestamp in programming languages?

In JavaScript: `Math.floor(Date.now() / 1000)`. In Python: `import time; int(time.time())`. In PHP: `time()`. In SQL: `UNIX_TIMESTAMP()`.

Última atualização: 19 de mar. de 2026
datas e tempo

Contador De Dias Calculator

pt-BR: dias entre duas datas (incluir ultimo dia), dias ate uma data futura (contagem regressiva), somar/subtrair dias.

datas e tempo

Calculadora De Horas Trabalhadas Calculator

pt-BR: rows of entrada, saida, intervalo -> horas do dia; week/month total; hora extra above jornada (default 8h/44h); output hh:mm and decimal.

datas e tempo

Calculadora Entre Datas Calculator

pt-BR: diferenca entre duas datas in anos/meses/dias, total dias/semanas/meses; adicionar/subtrair periodo.

financas

Calculadora De Investimentos Calculator

pt-BR: aporte inicial, aporte mensal, taxa (a.a. or a.m. toggle), prazo -> montante = FV with contributions; optional IR regressivo (22.5% up to 180d, 20% 181-360d, 17.5% 361-720d, 15% >720d); CDI/Selic/poupanca reference rates come from data/rates.json and are editable, never hard-coded.

saude

Calculadora De Pace Calculator

Same logic as pace calculator, native pt-BR UI/copy: ritmo por km/milha, provas (5K,10K,21K,42K).