Function Problems

Find the Next Non-Blank Monthly Value in Excel

Huma Ashraf ChHuma Ashraf Ch Nov 22, 2026 868 views

Question details

Find a formula that returns the current month's value or the next available non-blank value in a calendar table.

Find the Next Non-Blank Monthly Value in Excel
Product
Microsoft Excel
Device & OS
not provided
Scenario
A row contains values under monthly headers, and the user wants to search from the current month forward.
Observed behavior
The desired result is the current month's value if present; otherwise, the next non-blank value in a later month.
Before you start

Arrange the month headers from earliest to latest and confirm that the current month is included. The example below assumes B1:M1 contains text headers such as Jan 2026 and B4:M4 contains the values to search.

Solution 1Recommended

Use INDEX and MATCH to search from the current month

Use this array formula when month headers are text in the MMM YYYY format and you need to search across multiple future months.

The formula finds the current month in the header row, then returns the first value at or after that position that is not blank. A zero counts as a value, while a cell containing a formula that returns an empty string is skipped.

1
Select a result cell

Click an empty cell outside B4:M4 where you want the result to appear.

2
Enter the formula

In the formula bar, enter =IFERROR(INDEX(B4:M4,1,MATCH(1,(B4:M4<>"")*(COLUMN(B4:M4)-COLUMN(B4)+1>=MATCH(TEXT(TODAY(),"mmm yyyy"),B$1:M$1,0)),0)),""). Adjust the header and value ranges together if your table uses different columns.

3
Confirm the formula

Press Enter in a current version of Excel. In older versions, press Ctrl+Shift+Enter to enter it as an array formula.

4
Apply it to other rows

Select the result cell and drag its fill handle down to search the corresponding value row for each record.

Use INDEX and MATCH to search from the current month
Check the headers if the result is blank: The formula returns an empty result if the current month is not found or no later value is available. The text headers must match the output of TEXT(TODAY(),"mmm yyyy"), including the language used for month abbreviations.
Work with monthly data in WPS

Find the Next Monthly Value in WPS Spreadsheet

Use INDEX and MATCH in WPS Spreadsheet to search a monthly row from the current month and return the first non-blank value.

  1. 1. Open the workbook: Open WPS Spreadsheet and select Open to load your Excel workbook.
  2. 2. Check the table: Confirm that B1:M1 contains chronological text headers such as Jan 2026 and that B4:M4 contains the values to search.
  3. 3. Enter the formula: Select an empty result cell and enter =IFERROR(INDEX(B4:M4,1,MATCH(1,(B4:M4<>"")*(COLUMN(B4:M4)-COLUMN(B4)+1>=MATCH(TEXT(TODAY(),"mmm yyyy"),B$1:M$1,0)),0)),""). Adjust the ranges to match your table.
  4. 4. Confirm and copy: Press Enter to calculate the result. If your version requires array entry, use Ctrl+Shift+Enter; then drag the fill handle down to apply the formula to other rows.
Find the next non-blank value across future months.Open and edit Microsoft Excel XLSX and XLS files.Use familiar spreadsheet formulas and a straightforward interface.Work with spreadsheets using the free version of WPS Office.
microsoft office alternative - wps office

Frequently Asked Questions

What happens if the current month's cell contains zero?

The formula treats zero as a non-blank value and returns it. It skips empty cells and formulas that return an empty string.

Why does the formula return a blank result?

Check that the current month appears in B1:M1 as matching text and that there is a non-blank value in B4:M4 at or after that month. IFERROR also returns a blank if the formula encounters an error.

Can I use the formula if my month headers are real Excel dates?

Yes, if each header is the first day of its month. Replace MATCH(TEXT(TODAY(),"mmm yyyy"),B$1:M$1,0) with MATCH(DATE(YEAR(TODAY()),MONTH(TODAY()),1),B$1:M$1,0). Formatting a date as MMM YYYY does not turn it into text.

How do I apply the formula to several rows?

Select the result cell and drag its fill handle down. The value range changes to each row, while the dollar signs keep the header range on row 1.