How to find the latest (or earliest) date in a range
✓ Verified in LibreOffice 25.8.7.3 ✓ Verified in Google Sheets (2026-08-30)Most recent activity, newest entry, next deadline — dates are numbers, so MAX and MIN do it.
The formula
| App | Formula | Notes |
|---|---|---|
| Excel (desktop) | =MAX(A2:A100) | Format the result cell as a date. MIN gives the earliest; MAXIFS adds conditions. |
| Google Sheets | =MAX(A2:A100) | Identical. |
| LibreOffice Calc | =MAX(A2:A100) | Identical. |
How it works
Dates are day-count serials underneath, so the biggest number is the latest date — the verification's serials decode to July 1, June 15, and August 6, 2026, and MAX correctly picks August 6. The per-entity version is MAXIFS: =MAXIFS(A:A,B:B,"cust-42") finds a customer's most recent order. If MAX returns 0 or a 1899 date, the column is text-dates — convert them first (see the convert-text-to-date recipe).
Verified, not just documented
We ran =TEXT(MAX(A2:A4),"YYYY-MM-DD") in LibreOffice 25.8.7.3 (headless, with forced recalculation) and it returned 2026-08-06 — exactly the expected result. We then ran the same formulas in Google Sheets, executed 2026-08-30: a formula-only workbook goes into Google Drive, which converts it to a Sheet and recalculates every formula with Google’s own engine, and comes back out as .xlsx carrying the values Google computed. It returned 2026-08-06 for the worked example, the same value LibreOffice produced. Both engines’ numbers on this page are executed results. The Excel formula follows Microsoft’s official documented syntax — we do not run desktop Excel.
Functions used
MAX — see full Excel, Google Sheets & LibreOffice compatibility for each.
Related recipes
- How to calculate overtime pay
- How to calculate the range (max minus min)
- How to clamp (limit) a value between a minimum and maximum
- How to find the most common text value (mode for text)
- How to find the label that goes with the highest value