Excel date to Unix timestamp

Converts an Excel date/time value to a Unix timestamp (seconds since January 1, 1970 UTC).

Parameters

Parameter Description Example
DateTime Excel date DATE(2024,1,1)

Unix Timestamp

The result is the number of seconds that have elapsed since midnight UTC on January 1, 1970.

Examples

=DateTimeToUnixTimestamp(DATE(2024,1,1))
Returns 1704067200
Current date as Unix
Date from cell

When to Use

  • Preparing data for APIs that use Unix time
  • Converting dates for database storage
  • Time calculations in seconds

When NOT to Use

Scenario Use Instead
Need Unix to date UnixTimestampToDateTime()

Common Issues & FAQ

Q: What timezone is used? A: The conversion assumes UTC. Local dates may need adjustment.

Q: Does this include time? A: Yes, if you pass a date with time, the timestamp includes hours/minutes/seconds.

Get Access to 1 Billion Usable Market data points IN YOUR EXCEL SHEETS WITH EASY TO USE EXCEL FUNCTIONS

Get started today
MarketXLS Excel Add-in Tutorial - How to Use Excel date to Unix timestamp and Other Financial Formulas
How does MarketXLS work?