Skip to content
Salesforce Dictionary - Free Salesforce GlossarySalesforce Dictionary
DictionarySSearch Highlight
AdministrationBeginner

Search Highlight

A Search Highlight is the bolded fragment of matched text that Salesforce shows under a search result to give the user context for why the record matched.

§ 01

Definition

A Search Highlight is the bolded fragment of matched text that Salesforce shows under a search result to give the user context for why the record matched. The feature pulls a short snippet from a searchable text field on the record, places the matched terms in bold, and displays the snippet directly under the record's name and key fields in the global search results page.

Search Highlights apply automatically to a small set of objects with rich text content: Cases, Salesforce Knowledge articles, Feed posts, Files, Tasks, and custom objects with searchable Long Text Area or Rich Text Area fields. Standard objects like Account and Opportunity do not get snippet highlights because their searchable fields are short labels, not narrative text. Where snippets do appear, they reduce the click-through time to the right record by letting users skim matches in the results page itself.

§ 02

How Salesforce highlights matched terms in search results

What appears in a search highlight and where

Search highlights appear under the matched record's primary fields on the global search results page. The snippet is a short slice of text, usually two lines, taken from a searchable rich-text or long-text field on the record. The matched search terms inside the snippet are wrapped in bold so the user can see why the record matched at a glance. The highlight is read-only and clickable as part of the record name link; there is no separate UI control for the snippet itself, and the snippet does not appear if there is no matching field with narrative content on the record.

Which objects get search highlights

Search highlights are available on a defined list of objects: Cases, Salesforce Knowledge articles, Files, Feed Items, Tasks, and custom objects with searchable Long Text Area or Rich Text Area fields. Standard objects like Account, Contact, Lead, and Opportunity do not get snippet highlights because their searchable fields are short labels rather than narrative text. The feature is enabled by default for the supported objects; there is no admin toggle to turn it on or off per object, only the upstream choice of which fields are searchable.

How field searchability controls what can be highlighted

A field can only contribute to a search highlight if it is configured as searchable. For standard fields, searchability is fixed by the platform. For custom fields, the Searchable checkbox on the field definition determines whether the field's content is indexed for search and therefore eligible for highlighting. Long Text Area and Rich Text Area fields default to searchable on creation. Plain Text fields and Picklist values do not generate snippets even when matched; only narrative text fields produce highlight content because the snippet logic needs more than a label to slice from.

Search highlights vs Search Layouts vs Lookup Filters

Search Highlights are the snippet shown under a match in the global search results. Search Layouts are the admin-controlled configuration that decides which fields appear in the columns of the search results table per object. Lookup Filters constrain which records appear in a lookup dropdown. The three are independent features that solve different parts of the search experience. Confusing them is common: admins sometimes try to make a field appear in highlights by adding it to the Search Layout, which only affects the column list and not the snippet content.

The role of SOSL and the search index

Global search runs on SOSL (Salesforce Object Search Language) against the platform's search index, not on SOQL against the live tables. The index is rebuilt asynchronously after a record changes, so a freshly edited Knowledge article may not produce a snippet for the new text until the index refreshes. The refresh is usually within seconds, sometimes minutes for very large orgs. Search Highlights pull from the indexed content, so any field that is not in the search index produces no snippet even if the field is searchable in principle on the field definition.

Where highlights show: global search vs lookup, list view, and console search

Highlights show on the global search results page and in some list view-style results. They do not show in lookup field dropdowns (the small popovers when typing into an Account lookup), which display only the configured Search Layout columns. They also do not show inside list views, because list views run against indexed object data without the SOSL snippet step. In Salesforce Console search, highlights appear in the main results pane but are abbreviated in the navigation history items so they do not consume too much space in the navigation chrome.

Accessibility and localisation behaviour

The bolded fragments in a search highlight are produced with semantic HTML markup so screen readers announce them as emphasised text. The snippet text itself is in the record's original language; Salesforce does not translate snippet text for localised users. The Translation Workbench can translate the surrounding field labels and metadata but the snippet content is verbatim. For multi-language orgs, this means a Knowledge article in English produces an English snippet even when the user's display language is French. The search query is matched against the indexed content in whatever language the field was authored in.

§ 03

Tune which fields produce search highlights

Search Highlights are turned on automatically for the supported objects, so there is nothing to enable. The configuration work is upstream: making sure the right fields are searchable and the right object types are searched.

  1. Confirm the object type is eligible

    Search Highlights apply to Cases, Knowledge articles, Files, Feed Items, Tasks, and custom objects with rich-text or long-text content. Confirm your object is in the list before tuning fields; standard objects like Account do not produce highlights regardless of field setup.

  2. Check field searchability on the object

    For each text field that should contribute to highlights, open the field definition and verify the Searchable checkbox is on. Long Text Area and Rich Text Area fields default to searchable; review them after creation if you want to make sure.

  3. Use a global search query to verify

    Search for a known phrase in the field content from the global search bar. The record should appear with a snippet under it, with the matched phrase bolded. Try variants and partial matches to confirm the field is participating in the search.

  4. Wait for the search index after edits

    After editing rich-text content, wait at least a minute and rerun the search before assuming the field is not searchable. The search index is rebuilt asynchronously; very large orgs may take a few minutes for new content to appear.

  5. Review the Search Layout for column context

    The Search Layout decides which fields appear as columns in the search results table next to the snippet. Adjust it for context fields like Status or Owner so the user can decide whether to click without opening the record.

Searchable field flagremember

Per-field setting that decides whether a custom field is indexed for SOSL queries and eligible to produce highlights.

Search Layoutsremember

Per-object admin setting that decides which fields appear as columns in search results next to the highlight snippet.

Object inclusion in global searchremember

Standard and custom objects are included automatically when at least one searchable field exists; there is no per-object toggle to exclude an object from search entirely.

Gotchas
  • Search Highlights do not appear in lookup dropdowns or list views. They only appear on the global search results page and the Lightning Console search. If a user expects a snippet in a lookup, no configuration will produce one.
  • Edits to rich-text fields do not produce highlights immediately. The platform search index is rebuilt asynchronously and may take seconds to minutes to reflect the new content in a snippet.
  • Plain Text fields do not produce snippets even when matched. Only Long Text Area, Rich Text Area, and certain platform fields like Knowledge article body produce snippet text.
§

Trust & references

Sources

Cross-checked against the following references.

Official documentation

Straight from the source - Salesforce's reference material on Search Highlight.

Keep learning

Hands-on resources to go deeper on Search Highlight.

Was this entry helpful?
Help us write better definitions. Quick reactions or detailed edit suggestions.

About the Author

Dipojjal Chakrabarti is a B2C Solution Architect with 29 Salesforce certifications and over 13 years in the Salesforce ecosystem. He runs salesforcedictionary.com to help admins, developers, architects, and cert/interview candidates sharpen their fundamentals. More about Dipojjal.

§

Test your knowledge

Q1. What is Search Highlight?

Q2. Why is highlighting useful?

Q3. Is it a standard search pattern?

§

Discussion

Loading…

Loading discussion…