ToolJutsu
All tools
Developer Tools

Date to Timestamp

Convert dates into Unix timestamps.

Interpret as

The value above is read in your computer’s time zone.

Processed on your device. We never see your files.

How to use Date to Timestamp

What this tool does

This tool does the reverse of timestamp decoding: you give it a calendar date and time, and it returns the Unix timestamp for that instant. You pick the moment with a native date-and-time picker, choose whether the value should be read in your local time zone or in UTC, and the tool shows the result three ways — the timestamp in seconds, the timestamp in milliseconds, and the ISO 8601 string. Everything is computed in your browser; the date you choose is never sent anywhere.

Why you might need it

Unix timestamps are the common currency for storing and comparing moments in code. You reach for a conversion like this when you need to seed a database row with a specific created_at, build a test fixture that expects an exact epoch value, set a token or cache expiry, or filter logs to “everything after this date”. Typing a human date into a picker and copying the integer out is far quicker — and far less error-prone — than computing epoch seconds by hand.

How to use it

  1. Click the Date and time field and choose the moment you want to convert. You can set the date, the hour, the minute and the second.
  2. Use the Interpret as toggle to say whether that value is Local time or UTC.
  3. Read the result: the timestamp in seconds, the timestamp in milliseconds, and the ISO 8601 string all update instantly.
  4. Click Now to drop in the current date and time, or Clear to start over.
  5. Use the copy button beside whichever value your target system expects.

Common pitfalls

The interpretation toggle is the part to get right. If your back end stores times in UTC but you leave the toggle on Local time, the timestamp you copy will be off by your time-zone offset — an hour, several hours, or more. Decide up front which clock the value belongs to. A second subtlety is units: a value in seconds and the same value in milliseconds differ by a factor of one thousand, so copying the wrong row lands you far in the past or the future. Finally, the ISO string is always expressed in UTC with a Z suffix; that is correct behaviour, not a bug, even when the hours do not match what you typed.

Tips and advanced use

When you are writing tests or fixtures, copy the seconds value for most back-end languages and the milliseconds value for JavaScript code that compares against Date.now(). If you are coordinating an event across regions — a release, a deadline, a maintenance window — set the picker, switch the toggle to UTC, and share the resulting timestamp; everyone’s machine will resolve it to the correct local moment. The ISO 8601 output is the safest format to paste into configuration files and APIs because nearly every date parser accepts it. And since the whole conversion runs locally, you can use it freely for internal scheduling data without anything leaving your device.

Frequently asked questions

Is my date sent anywhere?
No. The conversion happens entirely in your browser with JavaScript's built-in Date object. The date you pick is never uploaded or stored, and you can verify that in your browser's Network tab.
What is the difference between the Local time and UTC options?
The toggle decides how the wall-clock value you typed is interpreted. Local time reads it in your computer's configured time zone; UTC reads the very same digits as Coordinated Universal Time. Because a Unix timestamp marks one absolute instant, the two interpretations produce different timestamps unless your offset happens to be zero.
Why are there both seconds and milliseconds?
Different systems expect different units. Most back-end languages and databases use seconds, while JavaScript's Date.now() and many front-end APIs use milliseconds. The tool shows both so you can copy whichever your target expects.
Can I convert a date before 1970?
Yes. Unix time counts from the epoch at midnight UTC on 1 January 1970, so earlier dates simply produce a negative timestamp. The date picker and the conversion both handle them.
Why does the ISO string look different from what I entered?
The ISO 8601 output is always shown in UTC, marked with a trailing Z. If you entered a local time, the ISO string reflects the same instant expressed at the zero meridian, which is why the hours can differ from what you typed.

Related tools