Hidden files and folders on OS X are hidden because they are system files, like Linux, UNIX system files generally have a leading dot, like .htaccess, .profile and .bash. These are files which exist on the system but are not visible, because to delete or edit them can sometimes compromise the system.
Sometimes they are system files, although not especially crucial to the functioning of the machine on a UNIX level. That said, they are best not played around with by a non-expert user either way.
So why would you ever want to reveal them for editing anyway? Well, perhaps you are an expert user; in certain circumstances you might want to edit the .htaccess file, for example. And you might also need to see the hidden trash folder in a volume to see what files are lurking in there before you empty the trash or figure out why they are not deleting when you do so.
The only way to edit anything hidden or within a hidden folder or a system file is to reveal them all, edit, then hide them all again. Either way there are many reasons to expose hidden files and a few ways to turn them on and off. In this article, we will cover the simplest ways.
Warning: Revealing hidden files and editing them is not something you do for fun; it’s a serious, potentially machine-breaking business. Please, follow the instructions carefully. Or make sure you have a Time Machine backup before you do this if you are in any way lacking confidence in your ability to get yourself out of a hole if something goes wrong.
Terminal Hide and Seek
So, the first step in revealing the hidden files is to open Terminal. You access this by going to “Utilities -> Terminal”.
In Terminal, once it has started and presented you with a prompt, type the following:
and press Return. This tells the machine that all hidden files and folders should now be visible again. The system greys them out (or makes them slightly translucent) so you can tell them from normal folders at a glance.
Look around though and you’ll see nothing has happened. This is because the effect doesn’t show on screen until you relaunch the Finder, so before you can actually see the folders you revealed you need to type an additional command on a new line:
This is the command for relaunching the Finder. The Finder will dutifully relaunch itself and refresh. Be patient and don’t freak out when everything goes blank, give it a few moments. The desktop and folders which are open are now shutdown and restarted, revealing all the hidden folders.
Now You See Me
To turn off the folders again, you have to follow the same procedure but this time with a FALSE switch on the command AppleShowAllFiles. So go back to Terminal and type:
followed on another line by:
to reset the Finder. Now all the hidden folders are hidden again.
You can, if you like, put it all together in one line separated by a semicolon:
Show Hidden Folders in a Dialog
As a bonus, you can also show any hidden files and folders when you are using a Save dialog.
To toggle hidden folders in any save dialog use the keystroke “? + Shift + .” (that’s a period) to turn them on and off.
Are there any other aspect of hidden files you’d like us to cover? Or do you have your own method? Please, let us know in the comments.
Phil South has been writing about tech subjects for over 30 years. Starting out with Your Sinclair magazine in the 80s, and then MacUser and Computer Shopper. He’s designed user interfaces for groundbreaking music software, been the technical editor on film making and visual effects books for Elsevier, and helped create the MTE YouTube Channel. He lives and works in South Wales, UK.
Our latest tutorials delivered straight to your inbox