5 Keyboard Shortcuts for Rows and Columns in Excel

Bottom line: Learn some of my favorite keyboard shortcuts when working with rows and columns in Excel.

Skill level: Easy

Keyboard Shortcuts for Rows and Columns in Excel

Whether you are creating a simple list of names or building a complex financial model, you probably make a lot of changes to the rows and columns in the spreadsheet.  Tasks like adding/deleting rows, adjusting column widths, and creating outline groups are very common when working with the grid.

This post contains some of my favorite shortcuts that will save you time every day.

I've also listed the equivalent shortcuts for the Mac version of Excel where available.

#1 –  Select Entire Row or Column

Shift+Space is the keyboard shortcut to select an entire row.

Ctrl+Space is the keyboard shortcut to select an entire column.

Mac Shortcuts: Same as above

Select Entire Row or Column in Excel Keyboard Shortcuts

The keyboard shortcuts by themselves don't do much.  However, they are the starting point for performing a lot of other actions where you first need to select the entire row or column.  This includes tasks like deleting rows, grouping columns, etc.

These shortcuts also work for selecting the entire row or column inside an Excel Table.

Keyboard Shortcut to Select Rows or Columns in Excel Table

When you press the Shift+Space shortcut the first time it will select the entire row within the Table.  Press Shift+Space a second time and it will select the entire row in the worksheet.

The same works for columns.  Ctrl+Space will select the column of data in the Table.  Pressing the keyboard shortcut a second time will include the column header of the Table in the selection.  Pressing Ctrl+Space a third time will select the entire column in the worksheet.

You can select multiple rows or columns by holding Shift and pressing the Arrow Keys multiple times.

Select Multiple Columns with Shift Plus Arrow Keys

#2 – Insert or Delete Rows or Columns

There are a few ways to quickly delete rows and columns in Excel.

If you have the rows or columns selected, then the following keyboard shortcuts will quickly add or delete all selected rows or columns.

Ctrl++ (plus character) is the keyboard shortcut to insert rows or columns.  If you are using a laptop keyboard you can press Ctrl+Shift+= (equal sign).

Mac Shortcut: Cmd++ or Cmd+Shift+

Insert Entire Row in Excel

Ctrl+- (minus character) is the keyboard shortcut to delete rows or columns.

Mac Shortcut: Cmd+-

Delete Selected Column in Excel

So for the above shortcuts to work you will first need to select the entire row or column, which can be done with the Shift+Space or Ctrl+Space shortcuts explained in #1.

If you do not have the entire row or column selected then you will be presented with the Insert or Delete Menus after pressing Ctrl++ or Ctrl+-.

Insert or Delete Menu Appears When Entire Row or Column is Not Selected

You can then press the up or down arrow keys to make your selection from the menu and hit Enter.  For me it is easier to first select the entire row or column, then press Ctrl++ or Ctrl+-.

So, the entire keyboard shortcut to delete a column would be Ctrl+Space, Ctrl+-.  You could also use the keyboard shortcut Alt+H+D+C to delete columns and Alt+H+D+R to delete rows.  There are lots of ways to do a simple task… 🙂

#3 – AutoFit Column Width

There are also a lot of different ways to AutoFit column widths.  AutoFit means that the width of the column will be adjusted to fit the contents of the cell.

You can use the mouse and double-click when you hover the cursor between columns when you see the resize column cursor.

Double-Click Resize Column Cursor to Autofit Column

The problem with this is that you might just want to resize the column for the date in cell A4, instead of the big long title in cell A1.  To accomplish this you can use the AutoFit Column Width button.  It is located on the Home tab of the Ribbon in the Format menu.

AutoFit Column Width Button in Excel

The AutoFit Column Width button bases the width of the column on the cells you have selected.  In the image above I have cell A4 selected.  So the column width will be adjusted to fit the contents of A4, as shown in the results below.

AutoFit Column Width Button Resizes Column Based on Selected Cell Contents

Alt,H,O,I is the keyboard shortcut for the AutoFit Column Width button.  This is one I use a lot to get my reports looking shiny. 🙂

Alt,H,O,A is the keyboard shortcut to AutoFit Row Height.  It doesn't work exactly the same as column width, and will only adjust the row height to the tallest cell in the entire row.

Mac Shortcuts: None that I know of.  The Mac version does not use the Alt key sequence which I believe is a limitation of the Mac OS.

#3.5 – Manually Adjust Row or Column Width

The column width or row height windows can be opened with keyboard shortcuts as well.

Alt,O,R,E is the keyboard shortcut to open the Row Height window.

Alt,O,C,W is the keyboard shortcut to open the Column Width window.

Excel Keyboard Shortcuts for Row Height and Column Width

The row height or column width will be applied to the rows or columns of all the cells that are currently selected.

These are old shortcuts from Excel 2003, but they still work in the modern versions of Excel.

Mac Shortcuts: None that I know of.  The Mac version does not use the Alt key sequence which I believe is a limitation of the Mac OS.

#4 – Hide or Unhide Rows or Columns

There are several dedicated keyboard shortcuts to hide and unhide rows and columns.

  • Ctrl+9 to Hide Rows
  • Ctrl+0 (zero) to Hide Columns
  • Ctrl+Shift+( to Unhide Rows
  • Ctrl+Shift+) to Unhide Columns – If this doesn't work for you try Alt,O,C,U (old Excel 2003 shortcut that still works).  You can also modify a Windows setting to prevent the conflict with this shortcut.  See the comment from Pablo Baez on Oct 5, 2015 below for further instructions.  Thanks Pablo! 🙂

Mac Shortcuts: Same as above

The buttons are also located on the Format menu on the Home tab of the Ribbon.  You can hover over any of the items in the menu and the keyboard shortcut will display in the screentip (see screenshot below).

Keyboard Shortcuts to Hide and Unhide Rows and Columns in Excel

The trick with getting these shortcuts to work is to have the proper cells selected first.

To hide rows or columns you just need to select cells in the rows or columns you want to hide, then press the Ctrl+9 or Ctrl+Shift+( shortcut.

To unhide rows or columns you first need to select the cells that surround the rows or columns you want to unhide.  In the screenshot below I want to unhide rows 3 & 4.  I first select cell B2:B5, cells that surround or cover the hidden rows, then press Ctrl+Shift+( to unhide the rows.

Select Cells That Surround Hidden Rows or Columns Before Unhiding

The same technique works to unhide columns.

#5 – Group or Ungroup Rows or Columns

Row and Column groupings are a great way to quickly hide and unhide columns and rows.

Shift+Alt+Right Arrow is the shortcut to group rows or columns.

Mac Shortcut: Cmd+Shift+K

Shift+Alt+Left Arrow is the shortcut to ungroup.

Mac Shortcut: Cmd+Shift+J

Again, the trick here is to select the entire rows or columns you want to group/ungroup first.  Otherwise you will be presented with the Group or Ungroup menu.

Keyboard Shortcut to Ungroup Rows or Columns in Excel

Alt,A,U,C is the keyboard shortcut to remove all the row and columns groups on the sheet.  This is the same as pressing the Clear Outline button on the Ungroup menu of the Data tab on the Ribbon.

*Bonus funny: At some point when using the group/ungroup shortcuts, you will accidentally press Ctrl+Alt+Right Arrow.  This is a Windows shortcut that orientates the entire screen to the right.  I call it “neck ache view”.  To get it back to normal press Ctrl+Alt+Up Arrow.

If your co-worker or boss accidentally leaves their computer unlocked and you want to play a joke on them, press Ctrl+Alt+Down Arrow.  This will turn their screen upside down.  Don't forget to record a video of their WTF reaction… 🙂

What Are Your Favorites?

There are a ton of keyboard shortcuts for working with rows and columns.  The above are some of my favorites that I use everyday.  What are some of your favorites?  Please leave a comment below.  Thanks! 🙂


Your email address will not be published. Required fields are marked *

  • Hi Jon,

    Is there an Excel shortcut for the vlookup function?

    I’ve searched online and cant find anything and then remember you’ve answered a question of mine before, in the above thread.



  • Thanks Dear for such a informative knowledge.

    I usually use short keys to insert or delete row and columns. But i found you by searching how to hide rows and columns with short keys.

    Thanks for your sharing.

  • Thanks Jon, most useful. The Ctrl+9 & 0 don’t appear to work in Excel 365, however Ctrl+O, etc works fine.

    • Nice and useful tips John, Thanks…I too love keyboard shortcuts.

      Hi Steve,

      Below are the steps for higher versions of Windows or Excel set up issues for the same with little changes mentioned already by Pablo for older versions.

      1. Click Start, and then click Control Panel.
      2. Double-click Language.
      3. Click Advanced Settings
      4. Click Change language bar hot keys under Switching input methods
      5. Click Advanced Key Settings tab, and select Between input languages.
      6. Click Change Key Sequence…
      7. For Switch Keyboard Layout, select Not Assigned.
      8.Click OK to close each dialog box.

      I hope this will solve your issue.


  • Hi Jon,
    Thanks Dear,
    I am always using shortcut key when working in the excell work book, so this shortcut key are very useful for me.

  • what is short key to auto adjust the column width as per data entry in the column. ALT+H+O+I works only to auto fit the length as per colume name size, but it doesn’t fit as per entire column width. i know there is short key to manually change the length as per desire, but i want short key to auto adjust the column width as per data entered in column.

    Thanks for you kind support

  • Hi Jon, hi all
    I tend to work more with text than numbers (I’m a translator). I often get glossaries from customers in Excel format and need to set row height to AutoFit. This is because they or I sometimes have to merge cells. This seems to torpedo the Cells->Format->AutoFit row height function. Is there a quick and dirty way to do this?

    • If you use this function frequently, you may pin it to the Quick Access Toolbar: File > Options > Quick Access Toolbar (or Alt+F+T+Q). Choose from left column and move it to the right, then arrange the order. For my convenience, I would put my most frequently used command as the second in the list, so that I can press Alt+2 at ease.

  • This was really lovely. Learnt many new things. Came here looking for a keyboard shortcut for show/un-showing the Grouped rows/column. Clicking that + / – button. Does anyone know if that is possible?

  • Alt + :
    Select Visible Cells only. Then copy / paste as needed. Or Format only visible cells.

    Very useful when working with SUBTOTALS. I often want to format/highlight/bold only the subtotals and not the details.

  • Í enjoyed very much the lesson, God bless you and continue to educate us It Will be better if you will be sending me lessons through my e-mail

  • Hi,
    I use multiple shortcuts and have no particular favorite until now.
    Now I gone use both Ctrl+Alt+Right Arrow, Ctrl+Alt+Left Arrow, Ctrl+Alt+Down Arrow. When doing my web presentation on bad graphs.
    Then I will know if they are looking on my presentation or doing something else… If they claim its upside down I will tell them its there own settings on there computer which are wrong !!!
    Ha, Ha.

    Thanks for this.

    (Ctrl+Alt+Up Arrow to reset.)

  • Hi John,
    Here are some additional keyboard shortcuts related to Rows and Columns (either in a range or in a table)

    1. Shift+Home – When selecting a cell in the middle of the row – extends selection to the beginning of the row
    2. End+Shift+Enter – Extends selection to the last non-empty cell in
    the row (Press End+Shift, release the End Key while still pressing Shift and press Enter)
    3. Ctrl+End – Moves to the last cell (bottom right)
    4. Ctrl+Shift+T – Displays/removes table’s total row (toggle)
    5. Ctrl+Shift+Arrow Key – Extends selection from the active cell
    (left, right, up, down) to the beginning or end of the row/column

    BTW, if trick no.2 does work on your computer, then I’m probably the only person in the universe who knows this trick   
    All the above mentioned shortcuts have been tested on Excel 2013 Professional Plus; however there’s no guarantee that they’ll function as described on other versions.

    I’m not a great fan of the Alt keyboard shortcuts because they work only on the English version of Excel.

  • Many thanks. I’ve been looking for these shortcuts, and now my works gona run a little more.

  • I found this very confusing as control+9 or control shift did not hide rows or columns but as the screen shot indicated control+0 did. Please adjust.

  • CTRL+SPACE doesn’t work in non-English Windows with input method enabled. Because some input method will use CTRL+SPACE for other use. Even you disable that use, the CTRL+SPACE still doesn’t work in EXCEL.

Generic filters
Exact matches only

Excel Shortcuts List

keyboard shortcuts list banner

Learn over 270 Excel keyboard & mouse shortcuts for Windows & Mac.

Excel Shortcuts List

Join Our Weekly Newsletter

The Excel Pro Tips Newsletter is packed with tips & techniques to help you master Excel.

Join Our Free Newsletter