Manage result sources
Result sources limit searches to certain content or to a subset of search results. You can also use result sources to send queries to external providers such as Bing.
A global or SharePoint admin can manage result sources for all site collections and sites in the tenant. A site collection administrator or a site owner can manage result sources for a site collection or a site, respectively.
SharePoint Online has both a classic and a modern search experience. The modern search experience gets results from the default result source. If you change the default result source, this impacts both the classic and modern search experiences. Learn more about the differences between the classic and modern search experiences in SharePoint Online.
For the classic search experience, you can create your own result sources, or use the predefined result sources. After you create a result source, you configure Search Web Parts and query-rule actions to use it.
Create a new result source
- Go to the Manage Result Sources page for the tenant, for a site collection, or a site:
For the tenant: In the classic SharePoint admin center, in the left pane select search, and then on the search administration page, select Manage Result Sources.
For a site collection, in your site collection, select Settings , and then select Site settings. If you don't see Site settings, select Site information, and then select View all site settings. Under Site Collection Administration, select Search Result Sources.
For a site, select Settings , and then select Site settings. If you don't see Site settings, select Site information, and then select View all site settings. Under Search, select Result Sources.
On the Manage Result Sources page, select New Result Source.
In the General Information section, type a name and a description for the new result source.
In the Protocol section, select one of the following protocols for retrieving search results:
Local SharePoint, the default protocol, provides results from the search index of this tenant (Search Service).
Remote SharePoint provides results from the index of a search service in a different farm (external source). In the Remote Service URL box, type the address of the root site collection of the remote SharePoint farm.
OpenSearch 1.0/1.1 provides results from a search engine that uses the OpenSearch 1.0/1.1 protocol.
Exchange provides results from Microsoft Exchange Server. Select Use AutoDiscover to have the search system find an Exchange Server endpoint automatically, or type the URL of the Exchange web service to retrieve results from — for example, https://contoso.com/ews/exchange.asmx
The Exchange Web Services Managed API must be installed on the computer where the search service is running.
- If you choose Local SharePoint or Remote SharePoint for protocol, choose a Type:
SharePoint Search Results to search the whole index.
People Search Results to search in people profiles and enable query processing that is specific to people search, such as phonetic name matching or nickname matching.
In the Query Transform section, you can change incoming queries to use a new query text instead. Choose one of these options:
Leave the default query transform ( searchTerms) as is. The query will be unchanged since the previous transform.
Type a different query transform in the box. See Understanding query transforms.
Build your own query. Select Launch Query Builder and build your query by specifying filters on the BASICS, sorting on the SORTING tab, and then testing the query on the TEST tab. Each of these tabs are described in the following sections.
In the Credentials Information section, choose an authentication type for users to connect to the result source.
The BASICS tab
|Choose this option||To do this|
||Use keyword filters to add predefined query variables to the query transform. Select query variables from the list, and add them to the query by clicking Add keyword filter.
||Use property filters to query the content of managed properties that are set to queryable in the search schema.
Select managed properties from the Property filter list. Click Add property filter to add the filter to the query. NOTE: Custom managed properties are not shown in the Property filter list. To add a custom managed property to your query, in the Query text box, enter the name of your custom managed property followed by the query condition, for example MyCustomColorProperty:Green
The SORTING tab
|Choose this option||To do this|
||Define sorting for results. The Sort by list contains managed properties that are set as sortable in the search schema.
Select a property to sort by, and then select Descending or Ascending. To sort by relevance, select Rank.
Click Add sort level if you want to specify more levels of sorting.
||If you selected Rank from the Sort by list, choose the ranking model to use for sorting.
||Click Add dynamic ordering rule to specify additional ranking by adding rules that change the order of results within the result block when certain conditions are met. You can add conditions by choosing from the lists that appears.
The TEST tab
|Choose this option||To do this|
||See the final query text, which is based on the original query template, the applicable query rules, and the variable values.
||Click the link to show more options.
||See the query as it is defined in the BASICS tab or in the text box in the Query transform section on the Add Result Source page.
|Query template variables
||Test the query template by specifying values for the query variables. Click Test query to see the results.
Set a result source as default
The default result source is Local SharePoint Results, but you can choose to set a different one as the default. By doing this, it will be easier to edit the query in Search Web Parts. For example, when you add a Content Search Web Part to a page, the Web Part automatically uses the default result source.
Go to the Manage Result Sources page for the tenant, for a site collection, or a site:
For the tenant: In the classic SharePoint admin center, in the left pane, select search, and then on the search administration page, select Manage Result Sources.
For a site collection: In your site collection, go to Settings, select Site settings and then under Site Collection Administration, select Search Result Sources.
For a site: On your site, go to Settings, select Site settings, and then under Search, select Result Sources.
On the Manage Result Sources page, point to the result source that you want to set as the default, select the arrow that appears, and then select Set as Default.
Send feedback about: