How to set up internal search with Algolia in Yoast SEO Premium?
When people land on your website, they most likely need to find some specific information. That is why it is crucial to set up an excellent internal search function. Doing that will improve the user experience on your site and allow people to find what they need. Moreover, it will increase the chances people will stay on your site longer. To help you get better internal search results on your site, we integrated WP Search with Algolia with Yoast SEO Premium!
The integration is based on Yoast SEO Premium’s internal linking metrics. Yoast SEO counts the links that posts and pages have pointing to them. The more links to a post or page there are, the more important search engines consider it to be. So, those pages are also most likely to rank higher in the search results. With this integration, we mimic that ranking within your internal search results. When someone uses your internal search, we’ll show them your most linked-to posts and pages at the top. Consequently, people will easily find the best content on your site!
Want to learn how to use this feature? Read on!
Set up the internal search with Algolia and Yoast SEO Premium
To improve your internal search with Algolia, follow these steps:
- Update Yoast SEO Premium so you’re running version 16.7 or higher.
- Make sure you’re running the WP Search with the Algolia plugin.
- Enable the Algolia integration.
This is quite simple: go to your Yoast SEO settings, click the “Integrations” tab, and enable the Algolia integration:
- Re-index your Algolia index.
This can be done on your WP Search with Algolia plugin settings page. It’ll look something like this:
- Go into your Algolia settings.
Go to “Indices”, select the correct index, and click “Configuration”. Then click “Ranking and Sorting”, the screen should look something like this:
- Click “Add custom ranking attribute”.
Because you’ve re-indexed your site, you should find a
yoast_seo_links
links attribute:
Add that. It’ll end up at the bottom of the list. - Move the new ranking attribute up.
Move the ranking attribute up to be probably the second-ranking attribute:
- Do a search on your site!
You should see better results because your important pages are the ones you link to the most!
That’s it! With this simple but powerful integration, you can drastically improve the user experience on your site. Want to learn more about the technical details and how Joost came up with the feature? Read Joost’s blog!