Hiding Gridlines in Excel

Hiding gridlines in Excel is a common task and most of the Excel users should know about it. It makes your spreadsheet clean and presentable. Although grid lines in excel have their own benefits but in some cases it is better to hide them.

What are Gridlines?

A spreadsheet contains cells and gridlines or gridbars represent the borders of these cells. Grid lines are the faint lines on your spreadsheet that help you to distinguish the cell boundaries.

What are gridlines ?
Uses of Gridlines:

1. They make it easier for you to align text or objects by giving you a visual cue.

2. They help you to distinguish between cell boundaries.

3. They make your data-tables more readable especially when they are without a border.

Grid lines are hidden during printing but if you want you can show them explicitly.

Method 1: Hide Excel Gridlines using the option in ribbon:

Excel has a default option to hide these mesh lines.

For Excel 2007, 2010, 2013:

  • Navigate to the “View” tab on the Excel ribbon.


  • Uncheck the “Gridlines” checkbox and the gridbars will be hidden.
  • Or you can also hide the grid lines from “Page layout” and uncheck the Gridlines “View” option.


For Excel 2003 and Earlier:

  • Navigate to “Tools” > “Options”.


  • Now, a dialog box will open. Navigate to the “View” tab and then uncheck the “Gridlines” option and click ‘OK’. This will hide these annoying lines.

Method 2: Make Gridbars invisible by changing background colour:

Another obvious way to hide the grid lines in excel is by changing their background colour so that it matches the worksheet background. This can be done by using following steps:

  • First of all select all the rows and columns of the spreadsheet by pressing “Ctrl + A”. Alternatively you can also click the little triangle icon under the “Name box”.
  • With all the cells selected, click the “Fill Color” option and select the white colour.


  • Now, all the gridlines will be hidden.

Method 3: Hiding gridlines by using the shortcut key:

If you are someone who love to see keyboard as compared to mouse then here is the shortcut key for you. You can use the “Alt + WVG” key combination to hide the excel gridbars.

Method 4: Hide spreadsheet gridlines using a Marco:

If you want to hide the grid lines by using a macro then you can use the below code. This code hides the gridbars if they are visible but if the grid lines are already hidden then it displays a message saying “Grid lines are already hidden!”

Sub Hide_Mesh()
If ActiveWindow.DisplayGridlines Then
ActiveWindow.DisplayGridlines = False
MsgBox "Grid lines are already hidden!"
End If
End Sub

Hide Grid lines when you are printing the sheet:

To hide the grid lines while printing the sheet follow below steps:

  • Navigate to “Page Layout” Tab and uncheck the “Print” option under Grid lines area. Or you can also use the “ALT + PPG” key combination to do this.
  • After this print the spreadsheet and the grid lines won’t be visible.

How to bring the grid lines back if they are already hidden:

If your grid lines are invisible by default and you want to show them up, then just check back the gridlines option that we have unchecked in the Method 1. Alternatively you can also press the keys “Alt + WVG” to make the gridbars visible again.

So, this was all how to hide gridlines in excel. Do share your thoughts and ideas related to the topic.

About Ankit Kaul

Ankit is the founder of Excel Trick. He is tech Geek who loves to sit in front of his square headed girlfriend (his PC) all day long. :D. Ankit has a strong passion for learning Microsoft Excel. His only aim is to turn you guys into 'Excel Geeks'.

Privacy Policy | Disclaimer | About