Discord Guide

Milliseconds to Date — How to Convert Epoch Milliseconds to Readable Dates

July 29, 2026 · 7 min read

Converting milliseconds to a date means changing a number count into a calendar time. This count is the time that has passed since January 1 1970 — the Unix Epoch. Use the free Unix Timestamp Converter to convert any milliseconds value to a readable date instantly — paste your number and get the result in seconds.

Milliseconds vs Seconds — The Key Difference

Before converting you need to know whether your number is in milliseconds or seconds:

10 digits = seconds — for example 1785283200

13 digits = milliseconds — for example 1785283200000

Milliseconds are 1000 times larger than seconds. To convert milliseconds to seconds divide by 1000. To convert seconds to milliseconds multiply by 1000.

This distinction matters because most Unix timestamp tools including the Unix Timestamp Converter expect seconds. If you paste a 13-digit milliseconds value into a seconds converter you will get a date thousands of years in the future.

Pro Tip:Count the digits first. 10 digits = seconds. 13 digits = milliseconds. This single check saves most conversion errors before they happen.

How to Convert Milliseconds to Date Online

The fastest way to convert milliseconds to a readable date:

  1. Go to the Unix Timestamp Converter
  2. Paste your milliseconds value
  3. If your number is 13 digits divide by 1000 first to get seconds
  4. The converter shows the readable date and time instantly

How to Convert Milliseconds to Date in Code

JavaScript

// Convert milliseconds to date
const milliseconds = 1785283200000;
const date = new Date(milliseconds);
console.log(date.toISOString()); // 2026-07-29T00:00:00.000Z
console.log(date.toLocaleDateString()); // 7/29/2026

JavaScript's new Date() constructor accepts milliseconds directly — no division needed.

Python

from datetime import datetime

milliseconds = 1785283200000

# Divide by 1000 to convert to seconds first
date = datetime.fromtimestamp(milliseconds / 1000.0)
print(date)  # 2026-07-29 00:00:00

# Or use UTC
date_utc = datetime.utcfromtimestamp(milliseconds / 1000.0)
print(date_utc)  # 2026-07-29 00:00:00

Python's datetime.fromtimestamp() expects seconds — always divide milliseconds by 1000 first.

PHP

$milliseconds = 1785283200000;

// Divide by 1000 to get seconds
$date = date('Y-m-d H:i:s', $milliseconds / 1000);
echo $date; // 2026-07-29 00:00:00

Java

long milliseconds = 1785283200000L;
Date date = new Date(milliseconds);
System.out.println(date);
// Java's Date constructor accepts milliseconds directly

JavaScript — Date to Milliseconds (Reverse)

// Convert date to milliseconds
const date = new Date('2026-07-29');
const milliseconds = date.getTime();
console.log(milliseconds); // 1785283200000

// Or use Date.now() for current time in milliseconds
const now = Date.now();
console.log(now); // current milliseconds

Python — Date to Milliseconds (Reverse)

from datetime import datetime
import time

# Convert date to milliseconds
dt = datetime(2026, 7, 29)
milliseconds = int(dt.timestamp() * 1000)
print(milliseconds)  # 1785283200000

How to Get Current Time in Milliseconds

Different programming languages return current time in milliseconds differently:

LanguageCode
JavaScriptDate.now()
Pythonround(time.time() * 1000)
JavaSystem.currentTimeMillis()
PHP(int)(microtime(true) * 1000)
C#DateTimeOffset.UtcNow.ToUnixTimeMilliseconds()
Gotime.Now().UnixMilli()
Ruby(Time.now.to_f * 1000).floor
RustSystemTime::now().duration_since(UNIX_EPOCH).unwrap().as_millis()
SQL ServerDATEDIFF_BIG(MILLISECOND,'1970-01-01', SYSUTCDATETIME())
PostgreSQLextract(epoch FROM now()) * 1000

Common Epoch Formats — Milliseconds vs Other Units

FormatDigitsExampleUnit
Unix seconds101785283200Seconds since 1970
Unix milliseconds131785283200000Milliseconds since 1970
Unix microseconds161785283200000000Microseconds since 1970
Unix nanoseconds191785283200000000000Nanoseconds since 1970

Why Discord Uses Seconds Not Milliseconds

Discord timestamps use 10-digit Unix seconds — not milliseconds. If you pass a 13-digit milliseconds value to a Discord timestamp code the date will appear thousands of years in the future.

Always divide your milliseconds value by 1000 before using it in a Discord timestamp code. Use the Unix Timestamp Converter to verify your value is 10 digits before pasting it into Discord.

See the complete Discord Timestamp Guide for all 7 Discord timestamp formats and how to generate them correctly.

Common Conversion Mistakes

Pasting milliseconds into a seconds converter — A 13-digit milliseconds value in a seconds converter returns a date thousands of years in the future. Always check your digit count first and divide by 1000 if needed.

Forgetting timezone — Unix timestamps are always UTC. When converting to a readable date make sure you account for your local timezone offset or you will get a time that is hours off.

Using Date.now() when you need seconds — JavaScript's Date.now() returns milliseconds. If you need seconds for a Unix timestamp divide by 1000: Math.floor(Date.now() / 1000).

Confusing milliseconds with microseconds — Some systems use microseconds (16 digits) or nanoseconds (19 digits). Divide microseconds by 1000000 and nanoseconds by 1000000000 to get seconds.

Related Guides

Also try our free tools:

Frequently Asked Questions

Divide your milliseconds value by 1000 to get seconds then paste into the [Unix Timestamp Converter](/unix-timestamp-converter) for an instant readable date. In JavaScript use new Date(milliseconds) directly. In Python use datetime.fromtimestamp(milliseconds / 1000.0).
Count the digits. A 10-digit number is Unix seconds. A 13-digit number is Unix milliseconds. Milliseconds are 1000 times larger than seconds — divide by 1000 to convert milliseconds to seconds.
Pass the milliseconds value directly to new Date() — for example new Date(1785283200000). JavaScript's Date constructor accepts milliseconds natively. Use .toISOString() for UTC output or .toLocaleDateString() for local date format.
Divide by 1000 first then use datetime.fromtimestamp(milliseconds / 1000.0). Python's datetime functions expect seconds not milliseconds. For UTC use datetime.utcfromtimestamp(milliseconds / 1000.0).
In JavaScript use new Date('2026-07-29').getTime() or Date.now() for the current time. In Python use int(datetime(2026, 7, 29).timestamp() * 1000). Both return the number of milliseconds since January 1 1970.
Your value is likely in milliseconds but you pasted it into a seconds converter. Divide by 1000 first then convert. A 13-digit milliseconds value in a seconds converter returns a date thousands of years in the future.
Unix seconds count seconds since January 1 1970 and are always 10 digits. Unix milliseconds count milliseconds since January 1 1970 and are always 13 digits. Milliseconds are 1000 times more precise than seconds — divide milliseconds by 1000 to get seconds.
Discord timestamps use seconds — 10-digit values. Always divide milliseconds by 1000 before using in a Discord timestamp code. A 13-digit milliseconds value in Discord shows a date thousands of years in the future.

Ready to generate Discord timestamps?

Open the Generator

Did You Miss These?

Discord Guide

Generate a Discord Timestamp

Free tool — all 7 formats, live Discord preview, auto timezone detection.

Open Generator →
Discord Guide10 min read

Jul 21, 2026

Timestamp Converter — Convert Any Timestamp to a Readable Date Instantly

Convert any timestamp to a readable date instantly. Complete guide with code examples in JavaScript, Python, PHP, Java, MySQL, PostgreSQL, Oracle, Excel, Bash, Ruby and Go.

Read Article →
Discord Guide6 min read

Aug 1, 2026

Discord Error 2007 — How to Fix Stream Reconnecting Error Fast

Discord error 2007 means your stream is reconnecting due to network issues or high packet loss. Fix it by checking your connection, disabling VPN, or lowering stream quality.

Read Article →
Discord Guide7 min read

Aug 1, 2026

Discord Error 3002 — How to Fix Mic Not Detected Fast

Discord error 3002 means your microphone is connected but not picking up sound. Fix it by checking OS permissions, selecting the correct input device, and adjusting audio settings.

Read Article →
Discord Guide7 min read

Aug 1, 2026

Discord Error 3004 — How to Fix Screen Share Failure Fast

Discord error 3004 means your screen share or stream failed to start due to an OS-level capture error. Fix it by disabling hardware acceleration, changing capture settings, or freeing up storage.

Read Article →