JavaScript's Date.now() returns Unix milliseconds (13 digits) - not seconds (10 digits). Many APIs (Java, Node.js, Firebase, MongoDB) also use milliseconds. Paste a millisecond timestamp and get the date back. Auto-detects ms vs seconds based on length so you can paste either format without thinking.
When to use this
Use when: debugging Node.js / Java / Spring Boot logs, parsing Firebase Firestore timestamps, decoding MongoDB ObjectId timestamps, working with JavaScript Date objects, reading event timestamps from Kafka / Pulsar streams.
Frequently Asked Questions
Why do JavaScript and Java use milliseconds while Python and Unix use seconds?
Historical choice. JS Date was designed around 1995 to match Java's millisecond precision. Python and the original Unix epoch use seconds (with a float for sub-second precision). It's a quirk you have to know - mixing the two without converting gives you dates that are off by a factor of 1000.
How do I convert milliseconds to seconds?
Divide by 1000. So 1716816000000 ms = 1716816000 s. Use Math.floor to drop the sub-second precision if you want a clean integer. The converter handles this automatically when you toggle between ms and s display.
Powered by Unix Timestamp Converter.