I always forget how to do this because I toggle this rather sporadically so I’m adding it to the public record.
To show hidden files in Finder pop open your terminal and type the text shown in the screen grab below.

To go back to hiding files we obviously just flip the AppleShowAllFiles flag to FALSE.

*Update*
As noted in the comments its nice to have the text available for easy copy and paste into your terminal.
Show:
defaults write com.apple.finder AppleShowAllFiles TRUE
killall Finder
Hide:
defaults write com.apple.finder AppleShowAllFiles FALSE
killall Finder
*Update 2*
You can use this script toggle between states:
# check if hidden files are visible and store result in a variable
isVisible=”$(defaults read com.apple.finder AppleShowAllFiles)”
# toggle visibility based on variables value
if [ "$isVisible" = FALSE ]
then
defaults write com.apple.finder AppleShowAllFiles TRUE
else
defaults write com.apple.finder AppleShowAllFiles FALSE
fi
# force changes by restarting Finder
killall Finder
You can also download an Automator application which will toggle hidden file visibility here:
Many, many thanks. Very useful to know
Great app. Thank you very much.
Scotty
Great post man!! Many thanks!!
Thanks for the excellent post. It was just what I was looking for.
I got it what i want.
Thanks.
Very helpful, thanks!
Cheers!
Many years later, new to OS X, thanks for showing this. I have a feeling I’m going to forget too (especially if I need to do it on a fresh install or someone else’s machine) so I’m going to make a “OSX tweaks” folder.
Thanks. =)
That little toggle app is awesome, just what I was hoping to find. Thanks!
Awesome: just what I needed. New to Mac; learning new stuff. ;O)
hi,
i tried automator application but unfortunately don’t know how to hide hidden folders again. :(
Thanks a million for this post. New to Mac’s and more than a little miffed to be honest
That was very helpful! I was neophyte in MAC OS X and I don’t know much of it. Thanks for this, I truly appreciate it.
Also, you can adjust visibility of individual files with:
chflags nohidden filenamehere
or for all the files, recursively, in the current directory:
chflags -R nohidden *
Danke!
Thank you! Usefull post!
[...] Mac OS X – Show / Hide Hidden Files in Finder LD_AddCustomAttr("AdOpt", "1"); LD_AddCustomAttr("Origin", "other"); LD_AddCustomAttr("LangId", [...]
[...] Mac OS X – Show / Hide Hidden Files in Finder LD_AddCustomAttr("AdOpt", "1"); LD_AddCustomAttr("Origin", "other"); LD_AddCustomAttr("LangId", [...]
Hi,
When I tried to hide,
the terminal shows,
‘Could not write domain /Users/Library/Preferences/com.apple.finder.plist; exiting’
Thanks! I never seem to be able to remember what to write in Terminal :-)
Nice post, good to jog the memory. But trying your toggle script, it was misfiring, so adding some “echo” lines, I see that isVisible is printing ” ÓTRUEÓ” which never matches … is this a Mac misfeature I’ve forgotten or ??
Thanks in advance!
Thank you!
Thank you!!!!
Thanks. :)