Formatting Issues

Fix Excel AutoFit Row Height Not Working with INDEX Formula Results in WPS Office

Bushra ParveenBushra Parveen Nov 13, 2026 869 views

Question details

The user needs rows to expand when a WPS or Excel formula such as INDEX or XMATCH returns wrapped, multiline text that is cut off.

Product
WPS Office Spreadsheets
Device & OS
not provided
Scenario
A spreadsheet uses INDEX or XMATCH formulas that return multiline text, and Wrap Text is enabled but row height does not expand enough.
Observed behavior
AutoFit Row Height fails to calculate the required height, leaving wrapped formula results clipped or overlapping.
Before you start

Open the worksheet and confirm that Wrap Text is enabled on the cells containing the INDEX or XMATCH results, and note whether the returned text contains manual line breaks or exceeds the current column width.

Solution 1Recommended

Manually Set Row Height After Enabling Wrap Text

Use this when AutoFit does not expand rows containing wrapped INDEX or XMATCH formula results.

WPS Spreadsheets inherits Excel's behavior: AutoFit may not reliably measure row height for formula-returned multi-line text, so a fixed manual height is the most dependable fix.

1
Select the formula result rows

Click the row numbers on the left to select all rows that contain wrapped INDEX or XMATCH results.

2
Enable Wrap Text

On the Home tab, in the Alignment group, click Wrap Text so all returned lines are allowed to wrap inside the cell.

3
Open Row Height

Go to Home > Cells > Format > Row Height.

4
Enter a sufficient height

Type a height that fits the visible lines, such as 15 points multiplied by the number of lines, then click OK.

5
Verify and adjust

If any text is still clipped, repeat the Row Height command and increase the value until every line is fully visible.

Rows stay visible: A manually set row height remains fixed and is not overwritten when AutoFit recalculates other rows.

Fix AutoFit Row Height for INDEX Formula Results in WPS Office Spreadsheets

Open the workbook in WPS Office Spreadsheets, enable Wrap Text, and set a fixed row height so INDEX or XMATCH formula results remain fully visible. WPS Office keeps Excel formulas and formatting intact while offering a free, familiar spreadsheet experience.

  1. 1. Open the workbook in WPS Spreadsheets: Launch WPS Office, click Spreadsheets, and open the .xlsx file that contains the INDEX or XMATCH results.
  2. 2. Select the clipped rows: Click the row numbers to select every row where wrapped formula text is not fully visible.
  3. 3. Enable Wrap Text: On the Home tab, in the Alignment group, click Wrap Text to keep the returned text inside the cell.
  4. 4. Set a fixed row height: Go to Home > Cells > Format > Row Height, enter a height that fits the wrapped lines, and click OK.
  5. 5. Save with Excel compatibility: Save the file as .xlsx to preserve formulas and formatting when reopening in Microsoft Excel.
Keeps wrapped INDEX or XMATCH formula results fully visible without changing the formulaOpens and saves .xlsx, .xls, and .xlsm files with full Microsoft Excel compatibilityFree, lightweight Office suite with a familiar ribbon layout for easier migrationPreserves existing cell formatting, formulas, and manual row height settings
microsoft office alternative - wps office

Frequently Asked Questions

Why doesn't AutoFit row height work when my formula returns wrapped text?

AutoFit can misread the required height for formula results that contain line breaks or long multiline text. Enable Wrap Text and then set a manual Row Height from Home > Cells > Format > Row Height.

How do I manually set row height for INDEX or XMATCH results in WPS Spreadsheets?

Select the affected rows by clicking their row numbers, go to Home > Cells > Format > Row Height, enter a height based on the number of visible lines, and click OK.

Does WPS Spreadsheets support INDEX and XMATCH formulas from Excel?

Yes, WPS Spreadsheets supports INDEX and XMATCH formulas when opening .xlsx files. If the formula returns multiline text, use Wrap Text and a manual row height to display all lines.

Can AutoFit Column Width be used as a workaround?

Yes, temporarily disable Wrap Text, select the columns, go to Home > Cells > Format > AutoFit Column Width to check the column width, then re-enable Wrap Text and set row height manually.