Date Format Converter
Paste or type a date in almost any form. The converter says how it read it, then shows the same date in every common format, each with a copy button.
This date can be read two ways. Which did you mean?
The way your input was read appears here once the page has loaded.
ISO 8601 and internet standards
- ISO 8601 date...
- ISO 8601 date and time, local...
- ISO 8601 with UTC offset...
- ISO 8601 in UTC...
- ISO 8601 in UTC with milliseconds...
- RFC 3339...
- RFC 2822 (email)...
- HTTP date (always GMT)...
- ISO week date...
- Ordinal date (year and day of the year)...
Numeric and written dates
- US numeric (MM/DD/YYYY)...
- European numeric (DD/MM/YYYY)...
- European with dots (DD.MM.YYYY)...
- Year first (YYYY/MM/DD)...
- Compact (YYYYMMDD)...
- Long, en-US...
- Full, en-US...
- Abbreviated, en-US...
- Long, day first...
Timestamps and serial numbers
- Unix time, seconds...
- Unix time, milliseconds...
- SQL DATETIME...
- Excel serial date number...
- Julian Day Number...
- Julian date (UTC, with fraction)...
- Modified Julian Date...
Time of day and your locale
- Time, 12-hour...
- Time, 24-hour...
- UTC offset...
- Relative to now...
- Full, your locale (browser language)...
- Long, your locale (browser language)...
- Short, your locale (browser language)...
Dates follow the proleptic Gregorian calendar, years 1 to 9999. Written forms use English month and weekday names. Extra rows in your own language appear when your browser is not set to US English.
Custom format pattern
Pattern tokens
Examples are for Thursday, July 9, 2026 at 3:05:09.250 PM, UTC-04:00.
| Token | Meaning | Example |
|---|---|---|
YYYY | Year, four digits | 2026 |
YY | Year, last two digits | 26 |
MMMM | Month name | July |
MMM | Month name, three letters | Jul |
MM | Month number, two digits | 07 |
M | Month number | 7 |
DD | Day of the month, two digits | 09 |
D | Day of the month | 9 |
Do | Day of the month with its ending | 9th |
dddd | Weekday name | Thursday |
ddd | Weekday name, three letters | Thu |
[text] | Literal text, copied as it is | on 9 |
X | Unix time in seconds | 1783623909 |
| Token | Meaning | Example |
|---|---|---|
HH | Hour, 24-hour clock, two digits | 15 |
H | Hour, 24-hour clock | 15 |
hh | Hour, 12-hour clock, two digits | 03 |
h | Hour, 12-hour clock | 3 |
mm | Minutes, two digits | 05 |
m | Minutes | 5 |
ss | Seconds, two digits | 09 |
s | Seconds | 9 |
SSS | Milliseconds | 250 |
A | AM or PM | PM |
a | am or pm | pm |
Z | UTC offset with a colon | -04:00 |
ZZ | UTC offset without a colon | -0400 |
The tokens follow the style of Moment.js and Day.js. Patterns written the Java or .NET way also work for the common cases: yyyy, yy, dd, d, EEEE and EEE are read as YYYY, YY, DD, D, dddd and ddd, and text in 'single quotes' is literal. x gives Unix time in milliseconds. Any other character is copied unchanged.
Format strings in common languages
The same output needs a different pattern in almost every language. Each table gives the pattern that prints the example in its column heading. The notes under the tables list the few cases where a language cannot match it exactly.
Numeric dates
| Language | 2026-11-27 | 11/27/2026 | 27/11/2026 | 27.11.2026 |
|---|---|---|---|---|
| strftime (C, Python, Ruby) | %Y-%m-%d | %m/%d/%Y | %d/%m/%Y | %d.%m.%Y |
| Java, Kotlin (DateTimeFormatter) | yyyy-MM-dd | MM/dd/yyyy | dd/MM/yyyy | dd.MM.yyyy |
| C#, .NET | yyyy-MM-dd | MM/dd/yyyy | dd/MM/yyyy | dd.MM.yyyy |
| JavaScript (date-fns) | yyyy-MM-dd | MM/dd/yyyy | dd/MM/yyyy | dd.MM.yyyy |
| JavaScript (Day.js, Moment.js) | YYYY-MM-DD | MM/DD/YYYY | DD/MM/YYYY | DD.MM.YYYY |
| PHP date() | Y-m-d | m/d/Y | d/m/Y | d.m.Y |
| Go (time.Format) | 2006-01-02 | 01/02/2006 | 02/01/2006 | 02.01.2006 |
| MySQL DATE_FORMAT | %Y-%m-%d | %m/%d/%Y | %d/%m/%Y | %d.%m.%Y |
| PostgreSQL to_char | YYYY-MM-DD | MM/DD/YYYY | DD/MM/YYYY | DD.MM.YYYY |
| Excel, Google Sheets (TEXT, cell format) | yyyy-mm-dd | mm/dd/yyyy | dd/mm/yyyy | dd.mm.yyyy |
Written dates
| Language | November 27, 2026 | Friday, November 27, 2026 | 27 Nov 2026 |
|---|---|---|---|
| strftime (C, Python, Ruby) | %B %-d, %Y | %A, %B %-d, %Y | %d %b %Y |
| Java, Kotlin (DateTimeFormatter) | MMMM d, yyyy | EEEE, MMMM d, yyyy | dd MMM yyyy |
| C#, .NET | MMMM d, yyyy | dddd, MMMM d, yyyy | dd MMM yyyy |
| JavaScript (date-fns) | MMMM d, yyyy | EEEE, MMMM d, yyyy | dd MMM yyyy |
| JavaScript (Day.js, Moment.js) | MMMM D, YYYY | dddd, MMMM D, YYYY | DD MMM YYYY |
| PHP date() | F j, Y | l, F j, Y | d M Y |
| Go (time.Format) | January 2, 2006 | Monday, January 2, 2006 | 02 Jan 2006 |
| MySQL DATE_FORMAT | %M %e, %Y | %W, %M %e, %Y | %d %b %Y |
| PostgreSQL to_char | FMMonth FMDD, YYYY | FMDay, FMMonth FMDD, YYYY | DD Mon YYYY |
| Excel, Google Sheets (TEXT, cell format) | mmmm d, yyyy | dddd, mmmm d, yyyy | dd mmm yyyy |
Times and timestamps
| Language | 2026-11-27 14:30:05 | 02:30 PM | 2026-11-27T14:30:05-05:00 |
|---|---|---|---|
| strftime (C, Python, Ruby) | %Y-%m-%d %H:%M:%S | %I:%M %p | %Y-%m-%dT%H:%M:%S%z |
| Java, Kotlin (DateTimeFormatter) | yyyy-MM-dd HH:mm:ss | hh:mm a | yyyy-MM-dd'T'HH:mm:ssXXX |
| C#, .NET | yyyy-MM-dd HH:mm:ss | hh:mm tt | yyyy-MM-dd'T'HH:mm:sszzz |
| JavaScript (date-fns) | yyyy-MM-dd HH:mm:ss | hh:mm a | yyyy-MM-dd'T'HH:mm:ssxxx |
| JavaScript (Day.js, Moment.js) | YYYY-MM-DD HH:mm:ss | hh:mm A | YYYY-MM-DDTHH:mm:ssZ |
| PHP date() | Y-m-d H:i:s | h:i A | Y-m-d\TH:i:sP |
| Go (time.Format) | 2006-01-02 15:04:05 | 03:04 PM | 2006-01-02T15:04:05-07:00 |
| MySQL DATE_FORMAT | %Y-%m-%d %H:%i:%s | %h:%i %p | No code for an offset |
| PostgreSQL to_char | YYYY-MM-DD HH24:MI:SS | HH12:MI AM | YYYY-MM-DD"T"HH24:MI:SSTZH:TZM |
| Excel, Google Sheets (TEXT, cell format) | yyyy-mm-dd HH:mm:ss | hh:mm AM/PM | No code for an offset |
- Month and weekday names come out in the language of the formatter's locale. The examples assume English.
- strftime:
%-dis the day without a leading zero. It works on Linux and macOS. On Windows write%#d.%zprints the offset without a colon, as-0500. Ruby and Python 3.12 or later also accept%:z, which prints-05:00. - Java:
XXXprintsZfor a zero offset. Usexxxto print+00:00. - .NET treats
/and:as the culture's own separators. Format withCultureInfo.InvariantCultureto keep them as written.zzzis meant forDateTimeOffsetvalues. - Go's layout is itself a date: the reference time
Mon Jan 2 15:04:05 MST 2006. - MySQL's
DATETIMEtype stores no offset, soDATE_FORMAThas no code for one. PostgreSQL'sTZHandTZMneed version 11 or later and atimestamp with time zonevalue. - Excel and Google Sheets: put the pattern in a formula, as in
=TEXT(A1,"yyyy-mm-dd"), or use it as the cell's own format (Ctrl and 1 in Excel, then Custom).mmmeans minutes when it comes right after the hour or right before the seconds. Google Sheets readshhas a 12-hour clock, so the 24-hour pattern usesHH, which Excel reads the same way. A spreadsheet date has no time zone. Excel in another language can use its own letters: the German version writesTT.MM.JJJJ.
What you can paste in
The converter tries the strict forms first and the looser ones after that. It always says which reading it chose, so you never have to trust a silent guess.
| Kind of input | Examples |
|---|---|
| ISO 8601 and RFC 3339 | 2026-11-272026-11-27T14:30:00Z2026-11-27T14:30:00.250-05:0020261127T143000Z |
| ISO week dates and ordinal dates | 2026-W48-52026-331 |
| SQL style | 2026-11-27 14:30:00 |
| RFC 2822 and HTTP dates | Fri, 27 Nov 2026 14:30:00 -0500Fri, 27 Nov 2026 19:30:00 GMT |
| Numeric dates | 11/27/202627/11/202627.11.20262026/11/27 |
| Written dates in English | November 27, 202627 Nov 2026Friday, November 27th, 2026 at 2:30 PM |
| What JavaScript prints for a date | Fri Nov 27 2026 14:30:00 GMT-0500 (Eastern Standard Time) |
| Unix timestamps | 1795789800 (seconds)1795789800000 (milliseconds) |
| Words | now, today, tomorrow, yesterday |
A bare number with up to 11 digits is read as Unix seconds. With 12 to 14 digits it is read as milliseconds. Longer numbers are read as microseconds or nanoseconds. Eight digits that form a real date, such as 20261127, are read as a date. Put @ in front to force the timestamp reading: @20261127.
Some inputs leave things out. A date with no time is treated as a calendar date, and midnight is used where a result needs a time. A time with no UTC offset is read in the time zone you picked. A two-digit year follows the usual computing rule: 00 to 68 mean 2000 to 2068, and 69 to 99 mean 1969 to 1999.
Why date formats differ between countries
Three orders are in everyday use. Each one is normal for a large part of the world.
| Order | Example | Where people write it |
|---|---|---|
| Day, month, year | 27/11/2026 27.11.2026 | Most of Europe, Latin America, Africa, South Asia, Australia and New Zealand |
| Month, day, year | 11/27/2026 | The United States |
| Year, month, day | 2026-11-27 2026/11/27 | China, Japan, Korea, Hungary, Lithuania and Sweden. It is also the order of ISO 8601. |

Day first is the most common order in the world. Month first follows the way Americans say a date aloud: "November 27, 2026".
The separators vary too. Germany and much of central Europe write dots (27.11.2026). Britain and France write slashes (27/11/2026). The Netherlands writes hyphens (27-11-2026). None of these habits is wrong. The trouble starts when a date written one way is read the other way.
The MM/DD and DD/MM trap
03/04/2026 is March 4 to an American reader and April 3 to almost everyone else. Nothing in the text says which one was meant. For the first twelve days of every month both readings are real dates, so software cannot catch the mistake either.
That makes 132 date strings a year that can be swapped without any error. They are the pairs of day and month from 1 to 12, leaving out the twelve where both numbers are the same.
From the 13th onward the problem shows itself, because 27/11 can only be day first. This is why a mix-up like this passes a quick test and then turns up in the first days of a month.
There are two safe ways out. In text meant for people, write the month as a word: 4 March 2026 or March 4, 2026 cannot be misread. In data, file names and anything a program will read, use ISO 8601: 2026-03-04.
When this converter meets a date that could be either, it shows a warning and lets you choose. It starts from the order your browser's language normally uses. Dates written with dots start as day first, because that is how dotted dates are written almost everywhere.
ISO 8601 explained
ISO 8601 is the international standard for writing dates and times. It was first published in 1988, and the current edition is from 2019. The rules are short. The largest unit comes first, every field has a fixed width, and only numbers are used.
| Part | Example | What it means |
|---|---|---|
| Calendar date | 2026-11-27 | A four-digit year, a two-digit month and a two-digit day |
| Time | 14:30:00 | Hours, minutes and seconds on the 24-hour clock |
| Date and time | 2026-11-27T14:30:00 | The letter T joins the date and the time |
| UTC | 2026-11-27T14:30:00Z | The letter Z at the end means the time is in UTC |
| Offset | 2026-11-27T14:30:00-05:00 | This time is five hours behind UTC |
| Week date | 2026-W48-5 | Day 5 (Friday) of week 48. Weeks start on Monday, and week 1 is the week with the first Thursday of the year. |
| Ordinal date | 2026-331 | The 331st day of 2026 |
| Basic format | 20261127T143000Z | The same fields with no separators |
The fields run from largest to smallest and never change width. So ISO 8601 dates sort correctly as plain text, and no reader will swap the day and the month. That is why databases, APIs, log files and file names use it.
One detail matters more than the rest. A date and time without a Z or an offset is a local time. It does not name one exact moment until you know the zone it was written in. This page always states the zone it used.
RFC 3339 and RFC 2822
RFC 3339 was published in 2002. It is the internet's profile of ISO 8601. It keeps a small part of the standard, so every timestamp has the same shape: a full date, a time and an offset, as in 2026-11-27T14:30:00-05:00. It also allows a space in place of the T. When a JSON API says it uses ISO 8601, it nearly always means RFC 3339.
RFC 2822 was published in 2001. It defines the date line of an email header: Fri, 27 Nov 2026 14:30:00 -0500. The weekday is optional. The month is a three-letter English short form, and the offset has no colon. It replaced RFC 822 from 1982. Its own successor, RFC 5322, kept the format.
HTTP headers use a stricter relative that is always in GMT: Fri, 27 Nov 2026 19:30:00 GMT.
12-hour and 24-hour time

The 24-hour clock numbers the hours from 00 to 23 and needs no AM or PM. 14:30 is half past two in the afternoon. It is the usual written form in most of the world and the only one ISO 8601 allows. The 12-hour clock with AM and PM is the everyday form in the United States.
To convert, add 12 to the PM hours other than 12, and turn 12 AM into 00. So 2:30 PM is 14:30, 12:15 AM is 00:15, and 12:15 PM stays 12:15.
Midnight and noon are where the mistakes happen. 12:00 AM is midnight at the start of the day, and 12:00 PM is noon. Many people are unsure about that. A deadline is safer written as 11:59 PM, as "noon" or "midnight", or in 24-hour time.
Date formats in JavaScript
JavaScript reads and writes ISO 8601 without any library. A few details catch people out.
new Date("2026-11-27")is read as midnight UTC, butnew Date("2026-11-27T00:00")is read as midnight local time. West of UTC the date-only form can show up as the day before.toISOString()always gives UTC with milliseconds:2026-11-27T14:30:00.000Z.getMonth()counts from 0, so January is 0 and November is 10.toLocaleDateString("en-US")gives11/27/2026. With"en-GB"you get27/11/2026, and with"de-DE"you get27.11.2026.- Strings in other forms, such as
11/27/2026, are not parsed the same way in every browser. Pass ISO 8601 to be safe.
Unix time, Excel serials and Julian days
Unix time is the number of seconds since January 1, 1970, 00:00:00 UTC, not counting leap seconds. One number names the same moment in every time zone. The Unix timestamp converter works with it in both directions. On this page it is accepted as input and shown as one of the results.

An Excel serial date number counts days from the start of 1900. January 1, 1900 is 1, each day adds one, and the time of day is a fraction, so .5 is noon. Excel's count includes a February 29, 1900 that never existed. The quirk was kept so that old Lotus 1-2-3 files still worked. Because of it, every serial from March 1, 1900 onward is one higher than a true day count. A serial has no time zone. The number shown here uses the date and time in the zone you selected.
The Julian Day Number is the day count astronomers use. It starts at noon UTC on January 1, 4713 BC in the Julian calendar, and January 1, 2000 is day 2,451,545. The Julian date adds the time of day as a fraction. Its days start at noon, so midnight UTC ends in .5. The Modified Julian Date subtracts 2,400,000.5 so that its days start at midnight.
Frequently asked questions
What date format does the United States use?
Month, day, year. In numbers that is MM/DD/YYYY, so November 27, 2026 is written 11/27/2026. Most other countries put the day first and write the same date as 27/11/2026.
What is the ISO 8601 date format?
It is YYYY-MM-DD: a four-digit year, a two-digit month and a two-digit day, joined by hyphens, as in 2026-11-27. With a time it becomes 2026-11-27T14:30:00. A Z for UTC or an offset such as -05:00 can follow.
How do I convert MM/DD/YYYY to DD/MM/YYYY?
Swap the first two numbers: 11/27/2026 becomes 27/11/2026. Or paste the date into the box at the top. The "European numeric" row gives the result, next to every other format.
Is 03/04/2026 March 4 or April 3?
It depends on who wrote it. In the United States it is March 4. In most other countries it is April 3. The text itself cannot tell you, so the converter flags it and asks. To avoid the question, write 2026-03-04 or spell out the month.
What do the T and the Z mean in 2026-11-27T14:30:00Z?
The T separates the date from the time. The Z means the time is in UTC, which has a zero offset. People read it aloud as "Zulu". A timestamp that ends in -05:00 is five hours behind UTC.
How do I convert a Unix timestamp to a date?
Paste the number. Up to 11 digits are read as seconds since January 1, 1970 UTC, and 12 to 14 digits are read as milliseconds. The results show the date in your time zone and in UTC.
What is the Excel serial number for a date?
It is the number of days since the start of 1900, with January 1, 1900 as day 1. January 1, 2000 is 36526. Enter any date and the "Excel serial date number" row shows its serial. When you give a time, the time of day is added as a decimal fraction.
Which date format should I use in a file name or a database?
Use ISO 8601 with the year first: 2026-11-27, or 20261127 where hyphens are not wanted. It sorts in date order as plain text. It also cannot be misread as a different day and month.