Return the Latest Value from an Excel Range
Question details
Find a formula that returns the last nonblank value in a changing range or the value associated with the most recent date.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- A worksheet receives new values over time, and a separate cell should display the latest relevant value.
- Observed behavior
- The result cell should update as the source range changes, using either row position or the most recent date to determine the result.
Identify the value range and decide whether latest means the bottommost nonblank entry or the entry with the most recent date. For a date-based lookup, make sure the dates are valid spreadsheet dates and align with the values in the same rows.
Return the Last Nonblank Value in an Excel Range
Use this formula when new entries appear toward the bottom of a column.
In Excel, click the cell where you want to display the latest value.
Type =LOOKUP(2,1/(A2:A1000<>""),A2:A1000) and press Enter. Replace both references to A2:A1000 with your value range.
Enter a value in a lower row within the selected range and check that the result cell updates.

Return the Value Associated with the Most Recent Date
Use a date-based lookup when the latest entry is determined by a date rather than its position in the range.
Find the Latest Range Value in WPS Spreadsheet
Use WPS Spreadsheet to return the bottommost nonblank value or look up the value associated with the latest date.
- 1. Open the worksheet: Open WPS Spreadsheet and select Open to load your workbook.
- 2. Select the result cell: Click an empty cell where the latest value should appear.
- 3. Enter a formula: For the last nonblank value, enter =LOOKUP(2,1/(A2:A1000<>""),A2:A1000). For a value in column A associated with the latest valid date in column B, enter =INDEX(A2:A1000,MATCH(MAX(B2:B1000),B2:B1000,0)). Press Enter.
- 4. Adjust and test: Replace the example ranges with your own, then change or add a value within the source range and check the result cell.

Frequently Asked Questions
Does the last nonblank formula find the most recently edited cell?
No. The LOOKUP formula returns the bottommost nonblank value in the specified range. It does not track when cells were edited.
What happens if multiple rows have the latest date?
The XLOOKUP and INDEX/MATCH examples return the value from the first row matching the maximum date.
Why does the last nonblank formula return #N/A?
The range may contain no nonblank values. Check A2:A1000 or your replacement range for an entry; formulas that return an empty string are treated as blank by this formula.
Will the formula include new rows beyond row 1000?
No. Edit both range references in the formula to include the additional rows, such as A2:A2000.




