Excel Autofit Row Height Adding Extra Line? Fix

Errors & fixes · Updated November 22, 2026

Yes, Excel’s autofit row height can add an extra line of space, and the most common cause is that the row contains wrapped text, merged cells, or a font that Excel measures differently than what is displayed. To fix it, select the row(s), go to Home > Format > AutoFit Row Height, and if that still adds space, manually set the row height or check for merged cells and font inconsistencies.

Why Autofit Row Height Adds Extra Space

Excel calculates row height based on the font size and the number of lines of text, but it doesn’t always match the on-screen rendering. The extra line typically appears when:

  • The cell has Wrap Text enabled, and the text is close to the boundary between two lines – Excel rounds up to the next full line height.
  • The row contains merged cells. Autofit often ignores merged cells, so the row height may be based on the tallest unmerged cell, or it may add extra space to accommodate the merged content.
  • The cell uses a different font than the default (e.g., a font with larger line spacing). Excel’s height calculation uses the font’s internal metrics, which can be larger than the visible glyphs.
  • The row has conditional formatting that changes font size or style, which can affect the height calculation.

How Autofit Actually Works

When you double-click the boundary below a row header, or use Home > Format > AutoFit Row Height, Excel calculates the required height based on the maximum number of text lines in any cell in that row, considering the column width and the font. It then multiplies the number of lines by the line height (which is roughly 1.5 times the font size for Calibri 11, the default). The result is rounded to the nearest pixel. If the text is exactly at the threshold, the rounding can add an extra line of space.

For example, with Calibri 11, a single line of text has a height of about 15 points. If your text wraps to exactly two lines, the height is 30 points. But if the text is just slightly longer than one line, Excel may count it as two lines, giving 30 points instead of 15 – that’s the extra line you see.

How to Fix the Extra Line

Here are several methods to remove the extra space, in order of simplicity:

  1. Manual set: Select the row(s), right-click the row header, choose Row Height, and type a smaller value (e.g., 15 for single-line text). This overrides autofit.
  2. Clear wrap text: If you don’t need wrapping, select the cells, go to Home > Alignment and uncheck Wrap Text. Then autofit again.
  3. Adjust column width: Sometimes widening the column reduces the number of wrapped lines, so autofit gives a smaller height.
  4. Use a smaller font: Reducing the font size by 1 point (e.g., from 11 to 10) can make the text fit into fewer lines.
  5. Merge cells carefully: If you have merged cells, autofit may not work correctly. Consider unmerging, or set the row height manually.

Common Problems with Autofit

Beyond the extra line, users often encounter these issues:

  • Autofit does nothing – This happens when the row has a manually set height that is larger than the needed height. Excel won’t shrink it automatically; you must select the row and use AutoFit Row Height.
  • Autofit makes the row too tall – This is the extra line issue, but it can also occur if there are hidden characters (like line breaks) in the cell. Press Ctrl+1, go to Alignment, and check if Wrap Text is on. Also, look for line breaks by pressing Ctrl+J in Find & Replace.
  • Autofit works on one row but not others – This often happens when some rows have merged cells or different fonts. Check each row individually.
  • Autofit doesn’t work with merged cells – Excel’s autofit ignores merged cells. If you have a merged cell with wrapped text, the row height will not adjust to fit it. You must set the height manually.

Comparing Autofit Methods

There are three main ways to autofit row height in Excel:

  • Double-click the boundary: Place the cursor on the line between two row numbers until it becomes a double arrow, then double-click. This autofits the row to its content.
  • Ribbon command: Select the row(s), go to Home > Format > AutoFit Row Height. This does the same as double-clicking.
  • Keyboard shortcut: Select the row(s) and press Alt+H, O, A (Windows) or Option+Command+0 (Mac) – note that on Mac, it’s Control+Command+0? Actually, the exact shortcut on Mac is Command+Option+0? Let me clarify: In Excel for Mac, the shortcut is Control+Command+0? To be safe, use the ribbon on Mac. The Windows shortcut Alt+H, O, A works.

All three methods use the same calculation, so they’ll produce the same result. If one adds extra space, the others will too.

Alternatives to Autofit

If autofit keeps adding extra space, consider these alternatives:

  • Set a fixed row height: Select the rows, right-click, Row Height, and type a specific value. This gives you full control.
  • Use Shrink to Fit: Select the cells, go to Home > Alignment, and check Shrink to Fit. This reduces the font size to fit the text into the existing row height, but it only works for single-line text.
  • Use a table: Convert your data to an Excel Table (Ctrl+T). Tables have a default row height that can be adjusted, and they often handle text better.
  • Use a different layout: If you have long text, consider splitting it into multiple cells or using a text box instead of a cell.

Frequently Asked Questions

Why does my row height become huge when I autofit after wrapping text?

This happens because Excel counts the number of lines based on the column width and the text length. If the text is just a few characters longer than the width, it wraps to an extra line, and the height increases by a full line. To fix it, widen the column slightly or reduce the font size.

Can I autofit multiple rows at once?

Yes, select all the rows you want to adjust (click and drag on row numbers, or use Ctrl+Click for multiple), then double-click the boundary of any selected row, or use Home > Format > AutoFit Row Height. Excel will adjust each row individually based on its contents.

Why doesn’t autofit work on merged cells?

Excel’s autofit feature does not consider merged cells when calculating row height. If you have a merged cell with wrapped text, the row height will not adjust automatically. You need to set the row height manually, or unmerge the cells and use Center Across Selection instead (which visually merges but keeps cells separate).

How do I remove extra line breaks in a cell?

Extra line breaks (created with Alt+Enter) can cause autofit to add space. To remove them, select the cells, press Ctrl+H to open Find & Replace, click in the Find what box, press Ctrl+J (this inserts a line break character), leave Replace with empty, and click Replace All. This will remove all line breaks.

Does autofit work differently in Excel for Mac?

The core functionality is the same, but the keyboard shortcut differs. On Mac, you can use the ribbon: Home > Format > AutoFit Row Height. There is no direct keyboard shortcut for autofit on Mac, but you can double-click the row boundary just like on Windows.

Related

Try it: the Formula Explainer: paste any formula and see each function and reference in plain English.

More in Errors & fixes

Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources

Spotted an error in this guide? Let us know.