How to Show Hidden Files in OS X

By default, Mac OS X hides many important system files and folders from the user’s view, either in the Finder or in the ‘Open’, ‘Save’ and ‘Save As’ Dialog Boxes of software applications. The operating system does this to prevent the accidental alteration or deletion of certain files that your Mac requires to run smoothly. Mac OS X marks these files as “hidden” by placing a single period at the start of each unseen files or folder’s name.

There are times, though, where experienced users may need to access these hidden files, perhaps to alter a configuration file or locate an apparently missing folder. There are two methods of making such files visible to the user.

The first involves using a command in the Terminal application to render all hidden files visible in the Finder and accessible from the Mac OS X Desktop. The second method is a simple key combination that will reveal hidden files and folders in Dialog Boxes.

How to View Hidden Files and Folders in the OS X Finder

To reveal files and folders marked with a period, you need to open a Terminal window (shortcut: CmdSpacebar to open Spotlight, then type ‘Terminal’ and press Return). The Terminal window will look similar to this:

Terminal Window in Mac OS X.png

To make hidden files visible in the Finder, input the following command at the Terminal prompt (or Copy and Paste from here), then press Return:

defaults write AppleShowAllFiles TRUE

The Terminal Window should appear like this:

Show Hidden Files Command entered in Terminal Window.png

To activate this command, you need to restart the Finder. You can do this by either holding the Option key down and clicking on the Finder icon in the Dock, then selecting Relaunch from the pop-up menu:

Pop Up Menu to Restart Finder in OS X.png

You can also accomplish this by typing or pasting the following command and pressing Return in the Terminal window:

killall Finder

The Terminal window should now appear like this:

the killall Finder Command entered in the Terminal Window.png

All hidden files and folders in the Mac OS X operating system will now be visible and accessible to you directly from the Finder. Here is what the result will look like:

OS X Finder Window with Hidden Files Visible.png

Previously hidden files and folders will appear paler in color than files that are always visible.

If you want to reverse this command and hide these files again, simply type or Paste the following command into a Terminal window and press Return:

defaults write AppleShowAllFiles FALSE

Again, restart the Finder using the methods outlined above for this change to take effect.

How to View Hidden Files and Folders in Dialog Boxes

In Mac OS X 10.6 Snow Leopard, there is a far simpler method for revealing hidden files when using the ‘Open’, ‘Save’ and ‘Save As’ Dialog Boxes. Ensure the Dialog Box is the foremost window by clicking anywhere on it, then press the following key combination (all keys held simultaneously):

⌘⇧. (CmdShiftPeriod)

All hidden files and folders on your system will now be visible in the Dialog Box:

Hidden Files Visible in TextEdit Save Dialog Box.png

Returning the files to their hidden state is simply a matter of pressing the same key combination again.

With these two OS X tricks under your belt, no file or folder on your Mac will be hidden from you again.

Comments [2]

  1. What? You mean the latest and greatest Mac OS requires users to use a Command Line Interface to do something as simple as hide or show a file or folder? Something that can be done in Windows with just a couple of mouse clicks. Hmmm, so much for the easier, more intuitive, more user friendly operating system.

    1. Keep in mind, when they say user friendly, they mean USER friendly, not Programmer friendly. In Windows, if an average user opens the Control Panel and sees that option, they’ll be curious and wanna make sure they see everything. Someone who doesn’t realize the importance of hidden files will see all these new files and be like “I don’t want this cluttering my system!” and throw everything in the recycle bin. Then their computer will crash. On a Mac, you have to actually KNOW what you’re doing to access anything more than what a home computer is used for. But chances are, if you didn’t know how to show hidden files and folders on either platform, you’d google it anyway, so since people would get a chance to see the warnings about deleting hidden files and folders anyway, why not make it a Terminal command?

      It makes a lot more sense to me, and I run Windows 7.

Leave a Reply

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