A question often raised that causes much confusion is how we add a Search Refiner to search documents or files by a certain Content Types in SharePoint Online
From the get go adding a refiner isn’t as easy as it possibly could be, OOTB your site collections default search page (yourtenant.sharepoint.com/_layouts/15/osssearchresults.aspx) is locked down in what I imagine is in place to protect those from themselves, so while we can’t edit the default osssearchresults we can create a new search results page, add the refiners and set it as the search default. Cool – so how do I do that?
There are a few options to how we can create a page to update the refiners, in this example I will be creating a Search Center and utilizing its results page.
Creating the new Search Center
- Click Settings > Site contents
You will be taken to the A list of all Apps, scroll down to the bottom of the page and click new subsite
The New SharePoint Site page will load, you will be required to fill out the new sites parameters, the key here is to make sure you choose the Enterprise site template ‘Enterprise Search Center’
Please note: The Enterprise Features will need to be enabled on the Site Collection in order to use this template
- Once the new Search Center has been created you will be presented with a search bar, do a test search
Modifying the Search page
Now we are on our newly created search results page we can start editing the page
Settings > Edit Page
On the left hand side navigation you will see the Refinement WebPart – Select the drop down menu and Click Edit Web Part
The Page will load with a Refinement Web Part Panel on the right hand side of the page
- Click Choose Refiners
On the available refiners choose ContentType and click Add.
once added Click OK
You will now see Content Type as an available Refiner, you can now publish your page
Make your new Search Results Page the default.
Navigate back to the root of your site collection and click Settings > Site Settings
Under the Site Collection Administration category, choose Search Settings
Enter in both the Search Center URL & Which search results page should queries be sent to like the following
Click OK and your done your content types are now available to your users as a refiner