Please Note: This article is written for users of the following Microsoft Excel versions: 97, 2000, 2002, and 2003. If you are using a later version (Excel 2007 or later), this tip may not work for you. For a version of this tip written specifically for later versions of Excel, click here: Hiding and Protecting Columns.

Hiding and Protecting Columns

by Allen Wyatt
(last updated December 17, 2020)

7

Roger has a worksheet that he needs to distribute to different people so they can add and change some information. He wants to hide some of the columns in the worksheet, however, so that they cannot be viewed by users. He knows how to protect the worksheet and how to hide data in cells, but noticed that info is still visible in the formula bar.

Since you already know how to protect a worksheet, you are already on your way to accomplishing your task. These are the steps you should follow:

  1. Select the column you want to protect.
  2. Choose Cells from the Format menu. Excel displays the Format Cells dialog box.
  3. Make sure the Protection tab is displayed. (See Figure 1.)
  4. Figure 1. The Protection tab of the Format Cells dialog box.

  5. Make sure both the Locked and Hidden check boxes are selected. (It is the Hidden check box that controls whether the cell contents are visible in the formula bar or not.)
  6. Click OK to dismiss the dialog box.
  7. With the column still selected, choose Format | Column | Hide. Excel hides the column.
  8. Choose Tools | Protection | Protect Sheet. Excel displays the Protect Sheet dialog box. (See Figure 2.)
  9. Figure 2. The Protect Sheet dialog box.

  10. Enter a password to be used in protecting the worksheet.
  11. Using the check boxes, select what type of protection you want applied to the worksheet. At a minimum you should choose Select Locked Cells and Select Unlocked Cells. (These two options are selected by default in a worksheet.)
  12. Click OK to dismiss the dialog box. You are prompted to reenter your password (the one from step 8), which you should do.

At this point someone cannot view what is in the hidden column, even if they use F5 to jump to one of the cells in the column; it still won't appear in the formula bar. There is one caveat to all this. If you have some cells in the worksheet (or workbook) that are unlocked, so that the contents of the cell can be changed, it is still possible to see what is in individual cells of the column. How? Two methods, really:

  • In the unlocked cell, enter a formula that references a locked and hidden cell. For instance, if column E is locked and hidden, entering the formula =E3 will display, in the unlocked cell, the value in cell E3.
  • Copy the contents of the locked and hidden cell and paste it in the unlocked cell. Use F5 to jump to the locked and hidden cell, then press Ctrl+C, move to the unlocked cell, and press Ctrl+V. The contents of the locked and hidden cell are pasted in the unlocked cell.

The bottom line is that it is virtually impossible to 100% protect the contents of the column so that they cannot be viewed. Using the protection features of Excel makes it more difficult, but a determined user may be able to still view the contents in the described manner.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (2781) applies to Microsoft Excel 97, 2000, 2002, and 2003. You can find a version of this tip for the ribbon interface of Excel (Excel 2007 and later) here: Hiding and Protecting Columns.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Chopped Off Page Borders

Tired of your page borders not printing out as you expect? The problem could be due to any number of settings or ...

Discover More

Keeping an Image Centered in a Table Cell

Tables are often used in Word documents to help with page layout. This may lead you to inserting images within the cells ...

Discover More

Removing the Last Digit in a Number

If you have a long numeric value in a cell, you may have a need to remove the last digit of that value. You can do so ...

Discover More

Program Successfully in Excel! John Walkenbach's name is synonymous with excellence in deciphering complex technical topics. With this comprehensive guide, "Mr. Spreadsheet" shows how to maximize your Excel experience using professional spreadsheet application development tips from his own personal bookshelf. Check out Excel 2013 Power Programming with VBA today!

More ExcelTips (menu)

Controlling Entry Order on Unprotected Cells

When you protect a worksheet, one of the benefits is that you can limit which cells can be used for data entry. How a ...

Discover More

Using a Protected Worksheet

If you have a worksheet protected, it may not be immediately evident that it really is protected. This tip explains some ...

Discover More

Functioning Check Boxes in a Protected Worksheet

Want to protect a worksheet but maintain the ability to make changes to the check boxes you add to the worksheet? Here is ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is three more than 1?

2021-02-18 06:51:25

Anda Lutza

Dear sir, thank you for the tip. We need a way to hide a colum so nobody can see it . We managed to do that and send the document to other users in order to let them complete the other cells. The document returned to us with the protected by password colum unhide and exposeed. The person who did that only selected the entire sheet and make a copy in another sheet. In this way our hide and protected by password column became available and anyone can see the content of it.Can you help us to hide a column and protect it by password so nobody can see it in any way and in the same time the other columns to remain available to others to make changes on them.
Thanks


2018-02-24 14:19:45

Daniel

Thanks for the tip but it does not help hide the column with pw.
What I need is how to hide some specific columns with pw but the rest of the work sheet and the workbook is free to any users. Only the hidden columns require pw.
Please show me how.
Thanks


2016-12-29 22:10:15

Kim

Awesome reference - Thank you so much!


2016-12-13 16:19:52

Stacy Markham

this is exactly my scenario. but when i do these steps, the other user hovers his mouse over the hidden column and double clicks to open it.

is it possble to get past that?
i should also note, i'm sharing through dropbox. i wonder if it interferes.
thanks


2016-02-26 10:46:10

keith roethlisberger

Question: I am trying to protect a worksheet, I select my options to allow users to edit cells. Then protect the sheet, but since I am running macros using an active x combo box it wont let me run the macro (i.e. locked out). Any suggestions?


2015-04-13 10:28:16

Pankaj

dear sir
i want only lock my selected col & row, nothing entire sheet..
and its (selected Col & row) only show... other col & row i want editable... nothing lock..

request sir

thanks & wait ur reply
Pankaj (+918872729007)


2014-03-19 16:46:05

Tom Dixon

Okay I forgot my password right after entering it twice. How do I locate my password?


This Site

Got a version of Excel that uses the menu interface (Excel 97, Excel 2000, Excel 2002, or Excel 2003)? This site is for you! If you use a later version of Excel, visit our ExcelTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.