Date Format Converter: ISO, US, and European Formats
Write 02/03/2024 and you have said almost nothing. A reader in Chicago sees the second of March; a reader in Munich sees the third of February. The digits are identical, but the field order flips, and there is no way to recover the intended meaning from the string alone. This tool takes one date, lets you say which order you meant, and hands back the same day written every common way at once, so you can copy the version a form, database, or colleague actually expects.
Type the date the way you have it, pick the matching input format, and press Convert. The result panel echoes the day in ISO, US, and European notation, plus a Unix millisecond timestamp and the day-of-year number. Everything runs in your browser; nothing is uploaded.
The three formats this tool speaks
All three arrange the same fields, year, month, and day, in a different order. That is the entire disagreement.
| Format | Order | Example (4 July 2024) | Where you'll meet it |
|---|---|---|---|
| ISO 8601 | Year, Month, Day, hyphen-separated | 2024-07-04 |
Databases, APIs, filenames, config files |
| US | Month / Day / Year | 07/04/2024 |
United States forms and everyday writing |
| European | Day / Month / Year | 04/07/2024 |
Most of Europe, and much of the rest of the world |
ISO earns its place as the default for machines because its fields run from largest unit to smallest. Sort a column of ISO strings alphabetically and you also sort it chronologically, with no date parsing required. That single property is why so many systems store dates this way.
How the converter reads and rebuilds a date
Conversion is really just re-ordering. The script splits your input on its separator, a hyphen for ISO and a slash for the US and European presets, and assigns the three pieces to year, month, and day according to the format you chose. It then builds a JavaScript date with new Date(year, month - 1, day). The month - 1 matters: JavaScript numbers months from zero, so January is 0 and December is 11, a detail that quietly causes a lot of off-by-one bugs when people write their own date code.
Once that date object exists, printing the other formats is just a matter of reading back the year, month, and day, then gluing them together in a new order with the month and day padded to two digits. The converter also runs a sanity check: it rebuilds the date and confirms the year, month, and day come back unchanged. That catches impossible inputs like 2024-02-30, which JavaScript would otherwise roll silently forward to 2024-03-01. If the round trip does not match, you get a "valid date that matches the selected format" message instead of a wrong answer.
A quick end-to-end pass: you are holding 12/31/2023 and select US as the input format. The script reads month = 12, day = 31, year = 2023, builds the date, and reports back 2023-12-31 in ISO, 31/12/2023 in European order, a Unix timestamp, and day-of-year 365. The European line is the one that saves you. As a European date, 12/31/2023 is nonsense, since there is no 31st month, and seeing it rewritten as 31/12/2023 removes any doubt about which field was which.
Unix time and the day of the year
The timestamp is the count of milliseconds since midnight UTC on 1 January 1970, the reference point most software uses internally. It is handy whenever an API or log wants a plain number instead of a formatted string. Divide by 1000 for seconds, and note that one whole day is exactly 86,400,000 milliseconds, the same constant the converter uses to step between calendar days:
So converting the timestamp to seconds is a single division by 1000, and moving forward or back a day is a matter of adding or subtracting that one constant, no calendar logic required.
The day-of-year value counts how many days into the year the date falls, from 1 on January 1 up to 365 (or 366 in a leap year). The converter measures it directly, as the number of whole days from the last day of the previous year to your date:
Here t is the date's own timestamp and t0 is the timestamp of 31 December the year before. Because it works from the real calendar dates rather than a fixed lookup table, leap years take care of themselves: 29 February pushes every later day up by one, so 1 March lands on day 61 in a leap year and day 60 otherwise.
Where the converter stops
- It only reads the three presets above. Dot separators, two-digit years, spelled-out months, and other exotic orders are not parsed, so tell it the field order and use hyphens or slashes to match.
- It converts the date part only. Times, time zones, and the ISO date-time form
YYYY-MM-DDThh:mm:ssare out of scope, and the timestamp it reports is taken in your browser's local time zone. - It assumes the modern Gregorian calendar. Historical "Old Style" dates from before a country's Gregorian switch, and non-Gregorian calendars, are not adjusted.
- The input must be a real calendar day. Impossible dates are rejected rather than guessed at.
Frequently asked questions
Why are there different date formats?
They grew out of local habit long before computers existed. US ordering mirrors the way the date is spoken aloud ("July fourth"), European ordering runs day-to-year like most of the world, and ISO 8601 was designed later specifically to be unambiguous across borders and easy for software to sort.
Can I convert dates that include a time?
Not directly; this tool handles the calendar date only. Strip the time portion before pasting it in, or reach for a date-time library if you need to preserve hours, minutes, and offsets.
What happens if I enter an invalid date?
The converter rebuilds your input and checks that it survived the round trip. Something like 31/02/2024 fails that check, so instead of a misleading result you get a prompt to enter a valid date that matches the selected format.
Is ISO really the best format to use?
For anything a machine touches, like filenames, spreadsheets, databases, or timestamps in code, yes. Its sort-equals-chronology property and zero ambiguity make it the safest default. For prose aimed at people, a spelled-out month ("4 July 2024") beats every numeric format.
Does this work offline?
Yes. The conversion is plain JavaScript with no network calls, so once the page has loaded it keeps working with the connection off.
How do I pick the right input format?
Match it to how the date is currently written, not how you want it to come out. If your string reads 15/06/2024, choose European; the tool then produces the US and ISO versions for you.
Arcade Mini-Game: Date Format Converter: ISO, US, and European Formats Calibration Run
Use this quick arcade run to practice separating useful scenario inputs from common planning mistakes before you rely on the calculator output.
Start the game, then use your pointer or arrow keys to catch useful inputs and avoid bad assumptions.
