Skip to content

M/D/YYYY to SQL datetime converter

US short date (M/D/YYYY) → SQL datetime (YYYY-MM-DD HH:mm:ss)

Swap → SQL datetime to M/D/YYYY

SQL datetime · YYYY-MM-DD HH:mm:ss

2024-06-09 00:00:00

No time of day in the value: read as the start of the day (00:00), UTC.

How should 6/9/2024 be read?Time of day:
Why a time of day?

9 June 2024 names a day, not a moment: no time of day was given, so there is no single instant for it in UTC. Choose the time of day to assume, or keep the date as written.

Worked examples

InstantM/D/YYYYSQL datetime
an ordinary day6/29/20262026-06-29 00:00:00
a leap day2/29/20282028-02-29 00:00:00
the Unix epoch1/1/19701970-01-01 00:00:00

A date has no time of day. These examples, like the tool, read it as the start of the day (00:00) in UTC; the tool offers noon or keeping the date as written.

What this conversion changes

  • A date has no time of day: before writing a time or a timestamp, the tool asks which time to assume (the start of the day or noon, in UTC). Nothing is filled in silently.

M/D/YYYY — US short date (M/D/YYYY)

Pattern
M/D/YYYY
Example
6/9/2024
Seen in
Spreadsheets with US locale, Hand-typed US dates

SQL datetime — SQL datetime (YYYY-MM-DD HH:mm:ss)

Pattern
YYYY-MM-DD HH:mm:ss
Example
2022-06-29 13:45:31
Seen in
MySQL DATETIME, PostgreSQL timestamp, SQLite, CSV exports from databases

Thousands of values to convert?

CSV batch mode converts an entire column from M/D/YYYY to SQL datetime (or any of the 82 formats, with time-zone shifts), entirely in your browser, with no row limit set by us (your device's memory is the practical ceiling). $9.99/month, hides the ads, cancel anytime.