Date to Unix Timestamp

Need the Unix timestamp for a specific date and time — for a test fixture, a database query, or a scheduled job? This tool converts any date and time you pick into its corresponding Unix timestamp, shown in both seconds and milliseconds.

Enter seconds or milliseconds — the unit is detected automatically.

Your data stays in your browser — this tool runs entirely on the client side and nothing is uploaded to a server.

How to Use the Date to Unix Timestamp

  1. Choose a date and time using the picker (interpreted in your local timezone).
  2. The Unix timestamp appears instantly in both seconds and milliseconds.
  3. Copy whichever precision your system expects.

From calendar date to a single number

A Unix timestamp collapses a specific date, time, and timezone into a single number representing seconds (or milliseconds) since the Unix epoch (January 1, 1970, 00:00:00 UTC). Once converted, the timezone the date was originally entered in no longer matters — the number itself is timezone-independent.

Why this conversion is useful

This is commonly needed when writing test data with a specific "created at" time, building a database query that filters by a timestamp range, debugging a system that logs Unix time, or scheduling something to run at an exact moment.

Example

January 1, 2024, 00:00:00 UTC
2024-01-01T00:00:00Z
1704067200 (seconds) · 1704067200000 (ms)

Tips

  • Be explicit about whether you are entering local time or UTC — the resulting timestamp will differ.
  • Most JavaScript APIs expect milliseconds; most Unix/Linux tools expect seconds.

Frequently Asked Questions

Does the timezone of my browser affect the result?

Yes, if you enter a date/time without specifying UTC explicitly, it is interpreted in your local timezone before being converted to the timezone-independent Unix timestamp.