Skip to main content


SP2013 Search Quickie – Query Rule By Folder

Quick and dirty, without any manipulation of managed properties. This can be handy for file share crawling where SharePoint will index the physical folders of the file share.

To get to your query rules, go to Site Settings –> Query Rules (Under Search).

Configure a rule for Local SharePoint Results:


Click “New Query Rule”:

– Create a Name for the rule, Folders seems sufficient

– Set Query Conditions to “Query Contains Action Term” –> Action Terms being “Folder; Folders” (semi-colon delimited)



Click “Add Result Block” and on the next screen “Launch Query Builder”:

Set Select a query to the “Query’s original source”

– Keyword filter to {subjectTerms} –> Add that to the Query text

– Property Filter: Select IsContainer from the managed properties, set the Manual value to true –> Add that property filter

From here you can test your query to make sure that it returns what you’re looking for. In this case, folders.



Save your work, and folders should now show up as a promoted result block for your users!

Leave a Reply

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

This site uses Akismet to reduce spam. Learn how your comment data is processed.