81

I have copied some data into Excel 2010. I have found that some of the cells need to be widened to allow the data to fit. How do I automatically adjust the height of the cells to fit the content?

0

7 Answers 7

115

I have solved it like this:

  1. Select the entire spreadsheet.

  2. Double click the line in the margin in between the two rows.

This auto sizes every row not just the one row that I clicked on.

You can see a video of it here: Adjusting the Row Height of Rows in Excel

4
  • 2
    FWIW this also works in Google spreadsheets.
    – Hein
    Jan 4, 2012 at 21:46
  • 6
    Is there a way to automate this on every file open? Jan 17, 2014 at 16:10
  • 4
    it's not a 'automatically autoresize' it's only a 'one-shot' autoresize.
    – realtebo
    Nov 11, 2014 at 10:20
  • Is there a way to undo this besides using "undo" (CTRL-Z)? Dec 5, 2014 at 17:22
27

Select the data then from menu Format->Column->AutoFit.

For Excel 2010, the menu is Home, Cells, Format, AutoFit Column Width.

For Excel 2015 (Mac) Preview it is still the same menu as Excel 2 and up to 2003 so Excel 2010 looks an odd outlier

10

Row Heights: Highlight the rows you want to re-size. click on the ribbon's "Home" tab. In the "Cells" group, click on the "Format" icon -> a drop down menu will appear select "AutoFit Row Height".

Column widths: Highlight the columns you want to re-size. click on the ribbon's "Home" tab. In the "Cells" group, click on the "Format" icon -> a drop down menu will appear select "AutoFit Cell Width".

by the way, if you have used Word for awhile, you will recognize the drop down menu.

6

In the margin, where the columns are named, double-click the border of the columns that needs to be widened, same place where you would click and drag to manually resize. This will autoresize it.

0
3

As many said:

  • Menu Home tab -> Format->Column->AutoFit Row/Column Height

But to me, the trick was to select all the rows that need to be taken into account. Note that it might be counter intuitive but the first row is not enough to let Excel figure out it must resize based on all the content in each column.

So yeah, in a nutshell, to visualize a CSV file generated automatically:

  • CTRL+A
  • Menu Home tab -> Format->Column->AutoFit Row/Column Height
3

You can use keyboard commands as such:

Ctrl+A to select all/select the entire spreadsheet

Alt+H(for hometab), Then O (for format), I(for autosize width).

When you tap Alt you get all the keyboard letter commands right on the ribbon.

keyboard commands are much faster once you get used to them.

2
  • While incomplete (it doesn't contain the ctrl-A to select all which is necessary for this to work), it IS useful as this is the keyboard shortcut in Excel 2010 for autosize width - a useful bit of knowledge that isn't currently present in any of the other answers.
    – Ben
    Jul 3, 2015 at 16:00
  • Worked for me. I'm using Excel 2016.
    – Tim
    Dec 10, 2018 at 19:49
2

As Dunc answer didn't work for me and other answers are incomplete:

  1. Select cells you want to auto resize or CTRL + a for all cells
  2. Menu Home tab -> Format->Column->AutoFit Row/Column Height

Not the answer you're looking for? Browse other questions tagged .