How to solve the Elasticsearch not working in Magento 2 issue?
How to deal with the Elasticsearch no results in Magento 2 error?
If Magento 2 Elasticsearch shows no results or the 404 Not Found page, you can fix this by double-checking some settings and enabling redirection to another page. To do this, follow these 12 steps described below.
Step 1. Install the Elastic Search extension and make a general configuration of the module by setting up the connection and setting Autocomplete suggestions & Spelling correction.
Step 2. After that, you need to configure Advanced Search to solve the topics issue.
Step 3. Navigate to Admin Panel > Stores > Configuration > Advanced Search and open the General Settings window to start the Advanced Search configuration:
Step 4. Specify the autocomplete's Popup width (px), choose the Search Field Width in the dropdown, and set the Min Characters parameter to define the number of characters to start the search process (3 by default).
Step 5. The next step is to choose whether you want to Enable Redirect from 404 to Search Results or not.
Step 6. After that, you can choose whether to enable using the SEO-friendly Custom URL Key for Default Search Results Page.
Step 7. The next step is to set the Search Results Page URL Key (don’t use the ‘catalogsearch’ option).
Step 8. After that, choose whether to Enable Tabs on the Search Result Page, which will sort search results by Category, CMS, and Landing on the SERP.
Step 9. Set the Enable Indexing for AutoComplete Popup option to Yes to speed up the autocomplete popup (in this case, reindexing will take longer).
Step 10. After that, choose one of the 3 options in the Show Related Search Queries in Search Results dropdown:
Step 11. Choose whether to Show Related Search Queries Result Numbers or not.
Step 12. The last general setting is Replace Empty Search Result Message with CMS Block. Choose the needed option in the dropdown. Set No if you want the zero search results page to remain empty or choose one of the shown blocks.
The general search setup is complete. If you want to know more settings for the module and search engine, in particular, check out the user guide.