Computers, Laptops & Tablets > Apple 56 56 people found this article helpful How to Show Hidden Files and Folders on Mac Critical system files may need to be revealed to fix virus damage By Mary Landesman Mary Landesman Writer Brevard College Mary Landesman is a former freelance contributor to Lifewire and a security expert. She was named as one of the women to watch in IT security. lifewire's editorial guidelines Updated on September 11, 2020 Tweet Share Email Tweet Share Email Apple Macs iPad What to Know At the terminal command line prompt, enter defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder. By default, macOS hides critical system files and folders to prevent accidental deletion or alteration. This article covers how to show those hidden files as well as how to hide them again. Information in this article applies to Macs running macOS Catalina (10.15) through OS X Lion (10.7). How to Show Hidden Files in macOS To show hidden files on a Mac, use the Terminal application. Most hidden files are operating system and configuration files. These should not be deleted or modified unless you are absolutely certain what they do. Open the Terminal app. You can do this by opening Spotlight and entering the word "terminal" in the search field. You can also access Terminal by opening a Finder window and navigating to Applications > Utilities > Terminal. Enter the following command into the terminal command line prompt: defaults write com.apple.finder AppleShowAllFiles -boolean true ; killall Finder If you use OS X 10.8 or earlier, enter this command instead: defaults write com.apple.finder AppleShowAllFiles TRUE ; killall Finder The command lines accomplish two goals. The first part changes the file setting to show hidden files. The second part restarts the Finder so the files show up. Most of the time, you want to keep these hidden files and folders out of view, but there are circumstances where you may want to see them. For example, malware and viruses can cause problems by altering system files or renaming important folders. In such cases, you need to manually change those files back, and you can't do that if they are invisible. Keep in mind there are lots of hidden files and folders. If you show hidden files and browse through your files in a Finder window, the file list landscape look quite different. How to Hide Files in macOS When you're finished with the hidden files and folders, it is a good idea to return those files to their hidden state. Open the Terminal app. You can do this by opening Spotlight and entering the word "terminal" in the search field or by opening a Finder window and navigating to Applications > Utilities > Terminal. Enter the following command into the terminal command line prompt: defaults write com.apple.finder AppleShowAllFiles -boolean false ; killall Finder If you're using OS X 10.8 or earlier, enter this command instead: defaults write com.apple.finder AppleShowAllFiles FALSE ; killall Finder Reversing the process of revealing hidden files, returns the files to a hidden state, and the Finder restarts to reflect the change. A Word About the Terminal App Using Terminal is like peeking behind the windows and menus of the graphical user interface you're accustomed to. When you open an application, format a USB flash drive, or search your computer using Spotlight, you are essentially executing Terminal commands; the difference is that the commands have been automated and given a graphical presentation to make their operation more user-friendly. Was this page helpful? Thanks for letting us know! Get the Latest Tech News Delivered Every Day Subscribe Tell us why! Other Not enough details Hard to understand Submit