To check whether one Excel date is later than another, use the greater-than operator: with the first date in A2 and the date to compare it with in B2, enter =A2>B2. Excel returns TRUE if A2 is later than B2 and FALSE if it is earlier or the same date.
That simple comparison works because Excel stores valid dates as numbers. You can use it in a worksheet formula, a conditional-formatting rule, or a counting formula. The main complications are usually dates stored as text, hidden time values, blank cells, and whether you want strictly later dates or dates that are equal as well.
What Excel means by a date comparison
Excel does not generally compare dates as written words such as “January 15, 2025.” It compares their underlying serial numbers. In the standard 1900 date system, dates progress as serial values, with later dates having larger numbers. That is why the ordinary greater-than sign works: a later date has a greater serial value.
A comparison using > is strict. If the two dates are equal, the result is FALSE. Use the greater-than-or-equal-to operator, >=, when equality should count as meeting the condition. The choice matters for deadlines and reporting: a payment due on the cutoff date is not “after” the cutoff, but it may be “on or after” it.
Excel’s TRUE and FALSE results are logical values, not text. You can use them directly in other functions, or display a more descriptive result with IF. With an event date in A2 and a comparison date in B2, enter =IF(A2>B2,"After","Not after") to show After only when A2 is later. Because equal dates also return Not after, change the test to A2>=B2 if equality should count.
Compare two dates in cells
For a row-by-row check, put the comparison formula in a result column and fill it down. For example, if each row has a planned date in column A and a deadline in column B, enter the comparison in C2, then drag the fill handle down or double-click it. Excel adjusts the relative references for each row, so the next row checks A3 against B3.
To compare every row with one fixed cutoff date, store that cutoff in a cell and lock its reference with dollar signs. Suppose the event dates are in A2:A100 and the cutoff date is in B1. In C2, enter =A2>$B$1 and copy it down. The A2 reference changes by row; $B$1 stays fixed. This is useful for a list of appointments, invoice dates, or project milestones checked against one reporting date.
You can also compare a cell to a specific calendar date without typing a date string into the formula. With the date to test in A2, enter =A2>DATE(2025,1,1) to check whether it is later than January 1, 2025. DATE constructs the date from year, month, and day arguments, avoiding ambiguity between regional formats such as month/day/year and day/month/year.
Use IF to return a useful label
A bare comparison is excellent for calculations, but a label can make a report easier to scan. With a delivery date in A2 and a promised date in B2, enter =IF(A2>B2,"Late","On time"). This returns Late if the delivery date is strictly later. If delivery on the promised date should be considered late for your definition, use a greater-than-or-equal comparison; if it counts as on time, the strict test is appropriate.
For a three-way result that distinguishes earlier, equal, and later dates, use nested IF logic. With the dates in A2 and B2, enter =IF(A2>B2,"Later",IF(A2=B2,"Same date","Earlier")). The first test handles later dates, the second identifies equality, and the final result covers earlier dates. Choose labels that reflect the actual business rule rather than assuming that “late” always means strictly after.
For input lists where some rows may not have both dates yet, guard against blanks. With the two date entries in A2 and B2, enter =IF(OR(A2="",B2=""),"Missing date",IF(A2>B2,"Later","Not later")). This displays Missing date if either cell is empty, rather than treating an incomplete row as a completed comparison.
Highlight dates that are later than a cutoff
Conditional formatting can color qualifying dates without adding a helper formula column. If dates are in A2:A100 and the cutoff is in B1, select A2:A100, then choose Home > Conditional Formatting > New Rule > Use a formula to determine which cells to format. Enter =A2>$B$1, choose a format, and confirm. The formula is evaluated relative to the top-left cell of the selected range, so A2 should be the first date cell and the cutoff reference should be absolute.
This rule highlights only dates strictly later than the cutoff. To include dates on the cutoff, change the comparison to =A2>=$B$1. To highlight entire rows based on the date in column A, select the rows you want formatted and use a formula that locks the date column but leaves the row relative, such as =$A2>$B$1. The dollar sign before A keeps the test in column A as the rule applies across the row.
On Excel for Mac, the same conditional-formatting logic applies; menu labels and dialog layout can differ slightly by release. Excel for the web also supports conditional formatting, though the available controls may be arranged differently. If the rule appears not to work, confirm that the selected range starts where the formula expects and that the compared values are real dates.
Count dates greater than another date
To count how many entries fall after a cutoff, use COUNTIF. With dates in A2:A100 and the cutoff in B1, enter =COUNTIF(A2:A100,">"&B1). The criterion combines the greater-than operator with the date value in B1. If the dates are January 2, January 5, and January 10, and B1 is January 5, the result is 1 because only January 10 is strictly later.
For dates on or after the cutoff, use the criterion string ">="&B1 inside COUNTIF. A date equal to the cutoff is then included. If you need to count only entries in a particular category as well as later dates, COUNTIFS can apply multiple conditions, such as a category criterion and a date criterion. Make sure each criteria range has the same dimensions as the date range.
When building criteria with a date typed directly into a formula, avoid relying on a locale-specific text date. A cell reference to a real Excel date, or a DATE function inside the criterion, is less ambiguous. In most worksheets, a dedicated cutoff cell is also easier for another person to update and inspect.
Dates with times: an important distinction
Excel can store a time as a fractional part of a day. A cell displayed as January 5 may therefore contain January 5 at 3:00 p.m., even if the number format hides the time. When you compare that value with January 5 at midnight, the timed value is greater. This can make a date-only comparison appear surprising.
If the question is whether one full calendar day is later than another, ignoring time, compare the integer portions of the values. With date-and-time values in A2 and B2, enter =INT(A2)>INT(B2). INT removes the fractional time portion. By contrast, if you are checking whether a timestamp occurred after a precise deadline, keep the time included and compare the original values.
For example, a deadline of January 5 at 9:00 a.m. and an event at 10:00 a.m. on the same day have the same calendar date but the event is later as a timestamp. Decide whether the rule concerns a calendar day or an exact moment, and format the cells to display date and time while checking the data. Formatting changes what you see, not the stored value.
Common problems and how to fix them
- A date is stored as text. A date-looking entry pasted from a website or imported file may be text, not a numeric date. Comparisons can then give unexpected results. Select the cell and check whether Excel recognizes it as a date; changing the display format alone does not convert text into a date. For text that Excel can parse under the current regional settings, DATEVALUE can convert it. With a text date in A2,
=DATEVALUE(A2)returns its date serial if the text is recognized. Ambiguous text may parse differently across locales, so clean or convert imported data deliberately. - A blank cutoff makes dates look greater. In a numeric comparison, a blank can behave like zero. A real date compared with a blank cutoff may therefore return TRUE. If missing values are possible, test that both cells contain numbers first. With the two cells in A2 and B2, enter
=AND(ISNUMBER(A2),ISNUMBER(B2),A2>B2). This returns FALSE unless both cells contain numeric values and A2 is later. Excel dates are numbers, so ISNUMBER does not prove that a number is a meaningful date; it only rejects blanks and text. - The result is off by a day or more. Check for hidden time values and confirm that the cell’s number format is showing enough detail. Also check whether dates were imported under the wrong day/month order. A cell formatted to display as a date can still contain an incorrect numeric value.
- Dates shift when a workbook moves between systems. Excel workbooks can use the 1900 or 1904 date system. The systems assign different serial values to the same calendar date, and converting a workbook between them can shift displayed dates by 1,462 days. This is uncommon in many everyday files, but it matters when transferring older workbooks or data between platforms. Check workbook date-system settings before diagnosing a large consistent offset.
Choose the right comparison for the job
The best method depends on the output you need. Use a direct comparison when you need TRUE or FALSE for another formula. Use IF when people need a clear text label. Use conditional formatting to make exceptions visible in a list, and COUNTIF when you need a total rather than row-level results.
Before choosing, clarify three points: whether equality counts, whether times matter, and how blanks should be handled. Those decisions often explain more errors than the greater-than operator itself. For date ranges, a useful distinction is between “after this date” and “on or after this date”; they are not interchangeable. Also consider using a cell for a changing cutoff rather than embedding a fixed date in many formulas.
For Microsoft 365 on Windows, formulas and comparisons behave as described. Excel for Mac uses the same comparison operators and worksheet functions, although some ribbon locations and dialog layouts may vary. Excel for the web also supports these basic formulas. Formula argument separators can differ in some regional settings, but the examples here use commas as requested; if Excel rejects a formula, regional list-separator settings may be the reason.
Frequently Asked Questions
How do I check if a date is after today in Excel?
With the date to test in A2, use =A2>TODAY(). TODAY returns the current date without a time component and updates when the worksheet recalculates. The formula is FALSE for today because the comparison is strictly greater than; use greater-than-or-equal if today should qualify.
How do I compare a date to today but ignore the time?
If A2 may contain a time and you only care about the calendar day, compare its integer portion with TODAY. With the timestamp in A2, use =INT(A2)>TODAY(). This checks for a calendar date after today, not a later time today.
Does Excel’s greater-than operator include equal dates?
No. > means strictly greater, so equal dates return FALSE. Use >= when dates equal to the cutoff should also pass the test.
Why does a date comparison return FALSE when the date looks later?
The cell may contain text rather than a real date, may have been interpreted using a different regional date order, or may contain a hidden time that affects the comparison. Check the underlying values, test whether the cells are numeric, and show the time if timestamps are possible.
Can I compare dates in Excel conditional formatting?
Yes. Create a formula-based rule through Home > Conditional Formatting > New Rule and compare the date cell with a cutoff cell. Use a relative reference for the date in each row and an absolute reference for a shared cutoff, such as =A2>$B$1 when the selected range begins at A2.
Related
- Conditional Formatting in Microsoft Project: What Works
- Data Validation and Verification in Excel Explained
- Power Query Replace Text: Steps, Options, and Examples
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Compare Two Excel Sheets for Matching Data in ExcelTo compare two Excel sheets for matching data, use a shared ID column and check whether each ID…
- Box Plot in Excel: Compare Multiple Data SetsYes. In Microsoft Excel for Microsoft 365 on Windows, put each data set in its own column, select…
- How to Clear Browser Cache in Outlook on the Web SafelyTo clear the browser cache for Outlook on the web, open your browser’s privacy settings and delete cached…
- How to Schedule an Email in the New Outlook AppIn the new Outlook app, write your email, select the arrow beside Send, choose Schedule send, and pick…
- Clean Excel Duplicates: Find, Review, and Remove ThemTo clean duplicates in Excel for Microsoft 365 on Windows, select your data, choose Data > Remove Duplicates,…
- How to Calculate a Percentage of a Number in ExcelTo get a percentage of a number in Excel, multiply the number by the percentage: enter the number…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.