---
sourceDocument: Zurich ServiceNow AI Platform user interface
sourceDocumentLink: https://www.servicenow.com/docs/r/zurich/platform-user-interface

 Release :

    - zurich

ft:locale :

    - en-US

ft:publication_title :

    - Zurich ServiceNow AI Platform user interface

ft:clusterId :

    - platux

bundleId :

    - platux

workflow :

    - Platform


---

# Define a search source

# Define a search source {#ariaid-title1}

* Release version: Zurich
* 
* Updated August 11, 2026
* 
* ![](https://www.servicenow.com/docs/portal-asset/ico-clock) 3 minutes to read

Configure a basic search source to query data from an instance table, or configure an
advanced data fetch script to query data across multiple tables and data sources, or to pull
data from anywhere on the web.

## Before you begin

Role required: admin

## Procedure

1. In the platform UI, navigate to Service PortalPortals and select the portal you want to add search sources to.
2. From the Search Sources related list, click New to add a search source.
3. Define the fields on the Search Source form.  
   {#add-table-search-source__table_zxx_n3b_qz__entry__2}

   | Field | Description |
   |-|-|
   | Name | The display value for the search category. |
   | ID | The record ID. The value should be unique, and should not include any spaces or special characters. |
   | Application | The scope of the search source. |
   | Roles | If the Service Portal User Criteria Support plugin is not enabled, define user roles to access this search source. |
   | Search page template | The HTML template that displays the search results. If defining a basic search source, you do not need to change the default template. For an example of a modified template, see [Tutorial: set up an external knowledge base search source](https://www.servicenow.com/docs/QxNYTNxQPQZtked9S4YT0w "Define an advanced search source to return data from any source on the Internet. To understand the power of search sources, follow this tutorial to set up an external knowledge base search source."). |
   [Table 1. Search Source form]

   {#add-table-search-source__table_zxx_n3b_qz}
4. Complete the fields on the Data Source tab.  
   {#add-table-search-source__table_fl5_dc5_nx__entry__2}

   | Field | Description |
   |-|-|
   | Is scripted source | Adds an advanced data fetch script. If configuring an instance table as the data source, do not check this option. |
   | Data fetch script | Script defining the endpoint and API calls to fetch data. This field is only visible when Is scripted source is selected. For an example of a data fetch script, see [Tutorial: set up an external knowledge base search source](https://www.servicenow.com/docs/QxNYTNxQPQZtked9S4YT0w "Define an advanced search source to return data from any source on the Internet. To understand the power of search sources, follow this tutorial to set up an external knowledge base search source."). Note: If defining a facet generation script, inject the facets object into the data fetch script and update the script to generate data for each facet item. For an example, see the Knowledge Base and Service Catalog search sources. Search facets may not behave as expected if integrated into an advanced search source that queries data from a non- ServiceNow site. |
   | Facet generation script | Script defining search facets for a scripted search source. Enable your end users to filter search results for a more meaningful result set. This field is only visible when Is scripted source is selected. Note: If defining a facet generation script, inject the facets object into the data fetch script and update the script to generate data for each facet item. For an example, see the Knowledge Base and Service Catalog search sources. Search facets may not behave as expected if integrated into an advanced search source that queries data from a non- ServiceNow site. |
   | Table | Select a table from the list that you want to draw your results from. You can select any table in the platform. For example, User \[sys_user\] or Knowledge \[kb_knowledge\]. Note: Only indexed tables return search results. Learn more: [Configure a table for indexing and searching](https://www.servicenow.com/docs/access?context=configure-single-table-for-indexing&version=zurich&pubname=zurich-platform-administration&ft:locale=en-US). |
   | Conditions | Filters results based on defined conditions. For example, Active is True. |
   | Primary display field | Select which field you want to display on the search results page. For example, Name. |
   | Display fields | Select additional fields to display on the search results page. For example, User ID, Email, and City. |
   | Paginate results | Paginates search results. True by default. If Is scripted source is selected, the value updates to false. To enable pagination for a scripted search source, see [Paginate search source results](https://www.servicenow.com/docs/Wet3tLvQLJGmTcoVJ3p1OQ "Limit the number of results that a search source displays at one time to improve performance. End users can load more results as needed."). Define the maximum number of results per query for the search source in the Search Page widget or Faceted Search widget instance options. |
   [ ]

   {#add-table-search-source__table_fl5_dc5_nx}
5. Configure Typeahead settings to allow search results to populate the search field based on user input.  
   {#add-table-search-source__table_txl_hmb_qz__entry__2}

   | Field | Description |
   |-|-|
   | Enable typeahead | Allows typeahead functionality. If you do not want to integrate typeahead into your search source, clear the check box. |
   | Advanced typeahead config | Optionally add an advanced typeahead script to configure the way search results display. For more information, see [Create an advanced typeahead template](https://www.servicenow.com/docs/TmndG8xBr6paIwwFw6JXQg "Configure the way typeahead results display with an advanced template."). |
   | Typeahead glyph | Adds an icon beside each typeahead result. |
   | Page | Defines a service portal page to display the selected result. For example, if form is configured, a selected typeahead result opens in a form. |
   [ ]

   {#add-table-search-source__table_txl_hmb_qz}

6. Click Submit.

## What to do next

To enable end users to refine search results, [Add facets to a simple search source](https://www.servicenow.com/docs/R6GjIzQXmAjMBi_80n~fWA "Enable end users to refine search results for a simple search source. You can create facets for a table search source that return results based on field values or query conditions.").
* **[Paginate search source results](https://www.servicenow.com/docs/Wet3tLvQLJGmTcoVJ3p1OQ)**   
  Limit the number of results that a search source displays at one time to improve performance. End users can load more results as needed.
* **[Create an advanced typeahead template](https://www.servicenow.com/docs/TmndG8xBr6paIwwFw6JXQg)**   
  Configure the way typeahead results display with an advanced template.
* **[Tutorial: set up an external knowledge base search source](https://www.servicenow.com/docs/QxNYTNxQPQZtked9S4YT0w)**   
  Define an advanced search source to return data from any source on the Internet. To understand the power of search sources, follow this tutorial to set up an external knowledge base search source.
* **[Example: set up a GitHub search source](https://www.servicenow.com/docs/n~K_6V_97eoD4ILOzAghQQ)**   
  Set up an advanced search source that queries data from an external website.

*[\>]: and then


