How To Show Hidden and Protected Files in OS X Finder

One of my few complaints about MacOS X is that at times I feel like it treats you with kids gloves– many options for power users either require some sort of hacking, or simply don’t exist. One such thing which is fixable is getting Finder to show hidden files. It’s a quick and easy process via the command line to fix this:

tobin:~ brandon$ defaults write com.apple.finder AppleShowAllFiles TRUE
tobin:~ brandon$ killall Finder

Now you can actually see all of the directories which start with periods, etc. Enjoy!

Tags: , , , , , , , ,

17 Responses to “How To Show Hidden and Protected Files in OS X Finder”

  1. Rob Wilkerson Says:

    This is really handy when you create it as a shell script, wrap it an Automator plugin for Finder and can then access it from the context menu.

    I found I needed it most when I was already in Finder and the effort to open a terminal window and do the typing wasn’t conducive to my desire to…not do either of those things.

    Now I can right click, access the Automator submenu and select “Show Hidden Files” (the name I gave to the plugin). To invert, I select my “Hide Hidden Files” plugin.

  2. Sam Farmer Says:

    Cool. I’ve wanted to know how to do that for a while. However, my finder icons, like a folder, now have a washed out look to them.

  3. Brandon Harper Says:

    Sam,

    Strange, that certainly didn’t happen for me. In fact I just rebooted and it still looks the same. If it bothers you more than having hidden files, you could always revert it by doing the following commands:


    tobin:~ brandon$ defaults write com.apple.finder AppleShowAllFiles FALSE
    tobin:~ brandon$ killall Finder

  4. pan69 Says:

    I’m also getting the “washed” icon look. Undoing will bring them back to their normal state.

    Its odd that this kind of functionality isn’t standard included in OSX. I’ve been working on OSX for about eight weeks now (due to work) and I definitely do not like the GUI of this OS. “I feel like it treats you with kids gloves” to me it feels more like I’m being treated like an idiot. Finder is definitely the most horrible piece of **** ever conceived. To me it seems like Apple only comes up with functionality to be “different” then the “others” instead of creating a great user experience.

    I’ve worked on Windows and Linux desktops for years and even a Linux/Gnome desktop gives me a better user experience then OSX and the reason for this is that I’m free to adjust anything I want. Even Windows gives me more freedom than OSX. With OSX I constantly have the feeling that I’m forced into some else’s personal preferences. All in all, OSX should go straight into the bin…

  5. Joseph Lamoree Says:

    You might find PathFinder useful. It’s a very good replacement for Finder. Among the slew of features it offers, the ability to toggle the visibility of various types of files is much more convenient than using the global default.

  6. Brandon Harper Says:

    @Joseph

    Yeah, I have PathFinder myself, though just a trial. I get tired of getting nickled and dimed to death for little apps to fix problems that should be part of the OS, so I’ve pretty much refused to buy it.

  7. Aaron West Says:

    Hey guys, I also wrote a little OS X code to allow you to toggle between showing hidden files and not. If you access the following blog post you’ll get instructions on downloading my script and adding it to the Scripts menu so you can toggle hidden files view any time you want. It was built pre-Automater, but works well nonetheless.

    http://www.trajiklyhip.com/blog/index.cfm/2006/3/10/AppleScript-to-View-Hidden-Files-on-Mac

  8. pan69 Says:

    Since we’re on the topic of hidden files, does anyone know how to get rid of those annoying hidden .DS_Store files?

  9. Brandon Harper Says:

    @pan69

    Just created an entry just for you:

    http://devnulled.com/content/2007/08/how-to-stop-the-creation-of-ds_store-files/

  10. Glenn Says:

    FYI. The ‘defaults write com.apple.finder AppleShowAllFiles FALSE’ tip no longer works in OS X Leopard (10.5). I have not yet found a workaround.

  11. menneke Says:

    @ Glenn

    It still works for me in 10.5.1. The invisible files and folder icons now have this washed out look, the others look normal (more or less like in Windows I believe).

  12. arif Says:

    @ Glenn
    it’s probably not working b/c the code you posted enables default behaviour ie. don’t show hidden files

    change the FALSE to TRUE in the snippet you posted and you’ll be fine

  13. Stefan Says:

    well, this enables to see *several* hidden files in Finder.

    however, I still can’t see my .bashrc file in my home and some other dot-files (like the .profile file or the .ssh folder).

    anyone any idea how I can make those visible in Finder? (I’m on 10.5.1)

    thx & greetings from Germany,
    Stefan.

  14. Tim Says:

    Another question about hidden files: Does anyone know if I can delete files in a hidden folder called “.Trash”? I have 4.5GB of files in this folder and they’re things I thought I deleted about two weeks ago.

  15. » How To Stop The Creation of .DS_Store Files : devnulled: A stream for software developers and engineers Says:

    [...] At the request of a reader, I went ahead and researched what .DS_Store Files are, and how prevent MacOS X from creating them. In a nutshell, .DS_Store files are created by Finder to store preferences: .DS_Store (Desktop Services Store) is a hidden file created by Apple Inc’s Mac OS X operating system to store custom attributes of a folder such as the position of icons or the choice of a background image. By default, Mac OS X will create a .DS_Store file in every folder that it accesses, even folders on remote systems (for example, folders shared over a SMB or AFP connection) and even if the user has only customized the appearance of the folder by moving its Finder window. This is in contrast to the preexisting system for the same purpose used in previous versions of the Macintosh Finder, which would merely place a number of invisible files at the root of the volume being accessed (even on alien filesystems), always storing the settings and metadata for all of the folders in the entire volume within this single set of files. [...]

  16. Pac Mac Says:

    Thanks for the Info…

  17. Anuj Gakhar Says:

    I am a new MAC switcher from Windows and its really annoying that I cant have hidden files visible without spending money on some add-on software. I just want to open apache conf files and edit them and want to be able to browse to them in Finder. I could probably do this in some text editor but thats another story…no free text editor as well…atleast not to my knowledge. But obviously this should be part of the OS like others said.

Leave a Reply