26

I can see hidden files in Finder but when I search it doesn't find hidden files.

I have tried these two commands

defaults write com.apple.finder AppleShowAllFiles TRUE
killall Finder

I also change "File visibility" to "Invisible Items" when searching in Finder search

Can I make my searches easier than this?

1
  • 1
    It does not seem possible right now in High Sierra. Setting "Visibility" to "Invisible" would still not show hidden files in the search results. Quite possibly, the search does find them but then would not display them since they are ... invisible. Anyway, the only "workaround" (because it is not even that) is to create an alias to a hidden file, make it visible and then this alias will show up in the search results.
    – ruslaniv
    Apr 10, 2018 at 10:50

2 Answers 2

15

Sadly, I never found a solution to this either. According to LifeHacker there is actually no way to do it except using comercial software. So the only other possible answer your question is 'use the Terminal'

  1. Open a terminal
  2. Enter this command:

    cd <your_directory_of_interest>

  3. Find the files with a name starting with a 'dot'.

    find . -name ".*"

  4. You can redirect the resulting list to a textfile by adding > textfilename to the last command. Then use that file to do whatever you need to do with the files.
8

In pre-2015 macs only:


There is a way to search also within hidden files:

  1. Open Finder
  2. Fill search box with searched text
  3. Click "+" button.
  4. Choose "File visibility" and your option.

enter image description here

9
  • 9
    Unfortunately it does not work. I have tried that before.
    – PJ_
    Feb 18, 2013 at 15:09
  • 1
    Do as maseth says, but instead of "File visibility" you want "System files". Or rather, do both to be able to search everything.
    – Mark
    Mar 22, 2014 at 14:49
  • 5
    Also try "System files" "are included"
    – Don Gavel
    Jul 15, 2018 at 17:19
  • 4
    neither does work to me
    – DrGC
    May 3, 2019 at 19:40
  • 3
    @DonGavel addition does work. Would warrant a separate answer :-)
    – Ray Oei
    Jul 16, 2019 at 21:01

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .