Customize the search "No Results" message

By default, searches that return no results display the text, "No results found":

You can customize the text in that message using this script.


Go to Settings > Style, click on Custom HTML and select Body.

Copy the script text below and paste it into the Body window.

//customize the "no results" text on search results screen
  if($('.hg-search-page') && $('.hg-search-page').length > 0){
    $('.no-results-msg').html('<p>Replace this with the custom search text of your choice. You can style it using standard html</p>');

This script will replace the "No results found" text in the screenshot above with the text between the <p> </p> tags. Update the text by editing the highlighted text above.

You can style the text in the script using html.


Not sure what to include? Some ideas include:

  • A link to your contact form
  • The email address of your support team
  • If you have a guide on how to use the knowledge base or specific guided search instructions, include a link to those

Here's a sample script:

And the output it produces: