Formula Errors

How to Fix Excel Conditional Formatting Highlighting the Wrong Row

Camila MilosovichCamila Milosovich Nov 2, 2026 872 views

Question details

The user is attempting to highlight entire rows using an Excel conditional formatting formula, but the formatting is being applied to incorrect or offset rows instead of the expected target.

How to Fix Excel Conditional Formatting Highlighting the Wrong Row
Product
Excel
Device & OS
not provided
Scenario
Applying a conditional formatting rule with a custom formula (e.g., =$H10="Completed") to highlight an entire row based on the text value of a specific cell within that row.
Observed behavior
The conditional formatting highlights a row different from the one containing the matching text value, or the rule completely fails to trigger due to syntax or range selection issues.
Before you start

Before troubleshooting, review the exact range of cells you have selected for your formatting rule, as a mismatch between the selected range and the formula is the most common cause of offset highlighting.

Solution 1Recommended

Align the Selected Range with the Formula's Row Number

Fix offset row highlighting by ensuring the row number in your conditional formatting formula exactly matches the first row of your selected data range.

When applying a conditional formatting formula to an entire block of data, Excel evaluates the formula based on the active cell (usually the top-left cell of your selection). If your data range starts at row 2, but your formula is written as =$H10="Completed", Excel will apply an 8-row offset. This causes it to highlight a completely different row from the one containing your target word.

1
Select your entire data range

Highlight the exact block of cells you want the formatting to apply to, starting from the top data row (for example, A2:J100). Note the row number where your selection begins.

2
Open the Conditional Formatting Rules Manager

Navigate to the Home tab on the Excel ribbon, click on Conditional Formatting, and select Manage Rules from the dropdown menu.

3
Edit your existing rule

Select the rule that is highlighting the wrong row and click Edit Rule.

4
Adjust the row number in the formula

Modify your formula so the row number matches the first row of your selection. If your selection started at row 2, change the formula to =$H2="Completed" and click OK.

Align the Selected Range with the Formula's Row Number
Check the Applies To Range: Always verify that the 'Applies to' field in the Rules Manager perfectly covers your intended data without skipping the first few rows.
Efficient Data Formatting

Highlight Rows Flawlessly with WPS Spreadsheet

Avoid frustrating formula offsets and formatting errors with WPS Spreadsheet. It features an intuitive Conditional Formatting manager, making it simple to highlight rows based on text criteria with full support for standard Excel formulas.

  1. 1. Open your workbook: Launch WPS Spreadsheet and open your existing spreadsheet document. Select the exact data range you wish to format.
  2. 2. Access Conditional Formatting: Navigate to the Home tab on the top ribbon, click on Conditional Formatting, and choose New Rule.
  3. 3. Enter your highlighting formula: Select 'Use a formula to determine which cells to format'. Enter your formula using the proper locked column reference (e.g., =$H2="Completed").
  4. 4. Apply styling and save: Click the Format button to choose your desired row highlight color, click OK to confirm, and instantly see the correct rows highlighted.
Intuitive conditional formatting rule manager that prevents common offset errors100% compatible with Microsoft Excel (.xlsx) formats and formula syntaxLightweight desktop application with blazing fast data processingFree and easy-to-use alternative to Microsoft Office
QA img-9

Frequently Asked Questions

Why does conditional formatting highlight the row below the matching value?

This happens when your selected range starts at one row (e.g., row 2), but your conditional formatting formula refers to the row above it (e.g., =$A1="Text"). Excel applies this one-row offset to the entire selection, resulting in the row below the match being highlighted.

Can I highlight a row based on multiple text conditions?

Yes. You can use the OR function or AND function within your conditional formatting formula. For example, the formula =OR($H2="Completed",$H2="In Progress") will highlight the entire row if either status condition is met.

Why is my conditional formatting rule completely ignored even when the formula is correct?

Your rule might be overridden by another formatting rule with a higher priority in the Rules Manager. Additionally, check the actual text inside your cells; if there are hidden leading or trailing spaces (e.g., "Completed " instead of "Completed"), the formula will not recognize it as a match.