How to Autofit Columns and Rows in Excel

AutoFit resizes Excel columns or rows to fit their contents automatically. It is faster and more accurate than dragging borders by eye, especially across a large sheet.

Does this affect you?

Use this for Excel for Microsoft 365, Excel 2021, and Excel 2019 on Windows or Mac when text is cut off, columns are too wide, row heights look wrong, or cells show ##### because the column is too narrow.

Autofit by double-clicking a border

This is fastest for one or two columns or rows.

  1. Move the pointer to the line between two column letters, such as the border between B and C.
  2. Wait for the double-headed arrow cursor.
  3. Double-click.
  4. Excel resizes the column on the left side of that border to fit its widest content.
  5. For rows, double-click the line between row numbers.

Autofit several columns or rows from the ribbon

Use this for a whole range or sheet.

  1. Select the columns by dragging across their header letters, or press Ctrl+A to select the sheet.
  2. Open the Home tab.
  3. In the Cells group, click Format.
  4. Choose AutoFit Column Width.
  5. For rows, select rows and choose AutoFit Row Height from the same menu.

More control

Fix columns that still look wrong

Wrap Text can change how Excel calculates height and width. Merged cells can block AutoFit because Excel cannot tell which column owns the content. Toggle Wrap Text or unmerge cells when AutoFit behaves oddly.

Set exact sizes instead

Right-click a column header and choose Column Width, or right-click a row header and choose Row Height. Column width is measured in default-font characters; row height is measured in points.

##### means a display width problem

For dates and numbers, hash marks usually mean the column is too narrow. AutoFit generally fixes it without changing the data.

Printed output can still scale

Page Layout > Scale to Fit can shrink or stretch the printed sheet after AutoFit. Check print scaling if paper output differs from the screen.

Long numbers may need text format

A 16-digit account number may turn into scientific notation under General or Number format. Format the cell as Text before entering it; AutoFit will not fix number-format conversion.

Sources

  • Microsoft Support – Change the column width and row height (2025)
  • Microsoft Support – Wrap text in a cell (2025)
Disclosure: This post may contain affiliate links which means I may receive a commission for purchases made through links. I will only recommend products that I have personally used! Learn more on my Private Policy page.
A thoughtful woman reads a newspaper while enjoying coffee at an indoor workspace.

DEALWEEK

SUBSCRIBE AND GET 20% OFF YOUR NEXT ORDER! OFFER ENDS SOON - DON’T MISS OUT!

We don’t spam! Read our privacy policy for more info.

Shopping Cart