Coda 2 – Searching multiple files

I have seen a few people post in the Coda Users discussion group and had a friend of mine recently mention that they did not know how to search multiple files in Coda 2. Here is how to do it. You can either use the keyboard shortcut for Find in Files, Shift-Command-F, or select the menu option under Edit > Find:

Find in Files


This will open up the Find in Files interface within the Sidebar. Here you can enter terms to search for and you can also do a replace across files. At the top of the sidebar, you can choose to search the entire site, open files or, you can choose a specific folder (there will be a little triangle to the right of the last folder used – in my example, “templates”).

Find in Files interface


When clicking the triangle, you can use the Open/Save dialog box to choose another folder and you’ll also see a history of recent folders you have searched in.

Finally, the magnifying glass under the “Replace” text field with give you some more options such as using regular expressions for search and ignoring case. It will also give you recent searches you performed.

After searching, you will be presented with a list of matching files and the number of occurrences in each file. To see the actual matches within each file, click the arrow and you will see a list of the matches. Then, click on any of the lines to open the file and jump to the match.

search results

One thing that I would *really* like to see added to Coda’s searching is the ability to filter the files being searched. It searches all files. I would like to be able to, say, just search .php file, for example. I think that is its biggest weakness. The performance of the search is actually pretty zippy and I like the interface showing the collapsed file results and being able to drill down to the specific matches.



  1. I would love to search my entire site, but unfortunately the site search is disabled. Any ideas on how to enable it? I have the website open in Coda that I would like to search. Thanks in advance.

    1. Hello Brian,

      Hmmmm… the only time I have seen this happen is when I have not opened up a site from the sites tab. For example, if I just go directly to a folder using the Files tab, site search is grayed out for me. Is it possible you do not have a site open?

  2. Hi,

    same issue as BrianR. My site is open, I edit online, but the “Site” option is greyed out, I can’t click it at all.
    Is it because there’re many sites on this server ? Maybe a configuration problem ?

    Best regards,


    1. Jonathan,

      The only idea I have is that the site is not open or, perhaps, the Local Root isn’t set for the site? Have you verified the Local Root setting for the opened site?

      Local Root setting

      1. your correct! it was the local root, I work online most of the time. I just added the local root like you said and everything works. Do you know if the files that I change locally will automatically update on the server.

        1. Jonathan,

          I don’t think you can set it up to automatically save changes to the server. If you set up the FTP settings for the site you should be able to use the commands under File > Publish to upload your changes to the site. You can set “Use Publishing” for the site and all of your changes will show up in the Publish sidebar. It is a little more work, but I find it quicker to work locally and then publish to the server once I have made all changes needed. I would recommend using something like MAMP to view your site locally. There are also free alternatives like XAMPP.

          You can even use the Preview function in Coda to see changes you make refresh as you make them.

  3. Thanks! You have to be in file browser view for this to happen. It’s far from intuitive for a programmer’s text editor…

  4. I also have the site search greyed out but my site doesn’t have a local root – everything is hosted. Does it work the same to set a remote root?

    1. Hello Damian,

      I do not believe that it is possible to search remotely, unfortunately. I think that doing so would probably be very slow if possible. Do you know if you have SSH access to the site? If so, it might be better to connect via Coda’s built-in terminal and run a grep command on your files. Much more complicated but I believe the performance would be a LOT better!

  5. This is pretty slick — but I did struggle with a bit.

    1) You need to have your local root defined
    2) You need to copy the files you want to search to your local root
    3) Upload your files after you make made any changes.

    If you do that this is crazy fast! 🙂

Leave a comment

Your email address will not be published. Required fields are marked *