White Label Coders  /  Blog  /  Algolia. Modern alternative to WordPress search

Category: E-Commerce / WooCommerce / WordPress

Algolia. Modern alternative to WordPress search

WordPress and Algolia modern search
25.04.2022
4 min read

WordPress built in search system

When it comes to WordPress search, both developers and users are not big fans of the built-in search system. The former finds it hard to customize and make it suitable for their specific needs, whilst the latter tend to complain about overall slow performance when searching for specific word, especially when the number of posts present in the database is large.

Unfortunately, WordPress search is slow by its nature since it can only use SQL queries and it is not designed for full-text searches.

Search customization

On top of this, the built-in search system is very limited from a functional point of view. It just literally searches in the database and returns results, adding anything other than this to your site, for example filtering system, which requires extra development effort. WordPress offers some hooks which let you modify the default search query. It also gives you control over basic parameters such as post type in which you want to search etc.

Fortunately, as usually in WordPress, we can make use of one of many WordPress plugins out there. These customize default WordPress search behaviour, make it configurable and make search results more relevant. Some of the plugin incorporate AJAX which improves user experience to some extent and boost perception of speed, as page reload is no longer the case. With the aim of custom code and search plugins you can make more out of WordPress search.

You will hit the limit

For small brochure sites, when you need to help your users navigate through a dozen or so pages, the built-in search system is enough.

At a certain point though, WordPress search plugins and your MySQL database will not be able to handle it anymore. Remember that the bigger your database is, the more time it will take to execute your search queries. With tens of thousands of posts or products in the database, it is a matter of time when your client or your users will start complaining that search is not good enough and you need to do better. It is not surprising, as with such a high volume of content in database, the importance of well performing search is much bigger.

What then?

When you need more than MySQL powered search. You should start looking for alternative search engines known for their speed, scalability, and stability. One of the most well-known alternatives is “Elasticsearch”, a service from AWS. You can integrate it with WordPress thanks to the “Elasticpress” plugin. I used to work with “Elasticpress” on a few occasions and I found it pretty hard to customize. Especially when a client required to customize a relevance algorithm, which isn’t something that can be controlled in the plugin settings page. Using this stack also involves certain amount of DevOps work which can sometimes be a challenge as well.

During one of my recent projects, I had an opportunity to work with just another alternative search engine that you can integrate with WordPress. This was a huge and astonishing discovery!

Search with Algolia

“Algolia” is a powerful, hosted search API that helps to create fast and relevant search experiences in your application. When it comes to WordPress, it can be integrated with your sites by using a plugin called “WP Search with Algolia”. Indexing your content is fast and easy (an index is the place where the data used by a search engine is stored). However, might require some preparation work, e.g., you might want to just synchronize specific post types. Plugin comes with a bunch of hooks which are there to make this happen.

When it comes to mentioned project, main assumptions of the project were as follows:

  • it must work in WordPress multisite install (separate content indexes for each site)
  • support for auto-complete feature (also known as auto-suggest)
  • instant search experience (search results should reload as you type in)
  • searching two independent sources of data at the same time (federated search)
  • filtering by various taxonomies
  • sort by date (and date ranges), relevance, alphabetically
  • support for pagination and infinite scroll
  • support for highlighting
  • full control over feel & look
  • admin should be able to manage relevance and other settings in Algolia dashboard (rather than let the controll be in WordPress or within code)

Plugin “WP Search with Algolia” offers two modes: Use of Algolia in backend and use of Algolia with InstantSearch.js. The latter option is where all the magic happens, and it allows to achieve all the goals outlined above.

InstantSearch.js is an open-source UI library for Vanilla JavaScript. It lets you quickly build a search interface in your front-end application. An important part of this goal is achieved by providing front-end widgets that you can assemble into unique search interfaces. “WP Search with Algolia” provides templates which can be overwritten in your theme and will be the base for further development work. Ultimately, the JavaScript application will replace the body of your WordPress search page, providing an extremely fast (most of search queries take from 1 to 20 milliseconds to process) and highly configurable search interface.

Apart from all mentioned features, Algolia offers much more. One of the things I like a lot about Algolia is that you can manage all these amazing and robust features within the Algolia dashboard.

Other features worth mentioning are:

  • Analytic tools to understand your user behaviour
  • A/B testing
  • Custom ranking which helps in building your own search algorithm
  • Synonyms support and dynamic synonyms suggestion
  • Users’ personalization
  • It is language-agnostic

Live demo together with some code samples of the search application built with Algolia and InstantSearch.js can be seen here.

WordPress and Algolia summary

When it comes to fast and reliable search solution for your WordPress site, Algolia is the software that I would highly recommend. Building a search interface with InstantSearch.js is relatively simple. However it requires a skilled JavaScript developer though. It is pretty fast and the final user experience is just amazing.

WordPress Developer / Team Leader

Marcin is a highly experienced professional in front-end and WordPress web development. His competences include building web applications, websites, integrations, strengths such as business analysis. His interpersonal skills led him to be involved in project management. He has very good command of English language and many years of experience working in the international environment.

Related Articles
SEE OUR BLOG
Check related articles
What are must-have features for iGaming sites
What are must-have features for iGaming sites?

Read more
What SEO factors matter most for comparison websites
What SEO factors matter most for comparison websites?

Comparison websites face unique SEO challenges that standard optimization techniques can't solve. From managing database-driven content and real-time updates to balancing conversion optimization with search visibility, comparison platforms need specialized strategies. This comprehensive guide explores the critical SEO factors that determine success for comparison and affiliate websites, including Core Web Vitals optimization, structured data implementation, content architecture, duplicate content handling, and E-E-A-T signals. Whether you're running a trading affiliate site or any comparison platform, discover how to maintain strong rankings while delivering genuine value to users and maximizing commission potential.

Read more
What is hreflang and when do I need it
What is hreflang and when do I need it?

The hreflang attribute tells search engines which language version of your page to show users based on their location and preferences. If you're running a multilingual or multi-regional website, hreflang prevents duplicate content issues and ensures visitors see content in their language. This guide explains when you actually need hreflang, how to implement it correctly in WordPress, common mistakes to avoid, and testing methods to verify it's working properly for your international SEO strategy.

Read more
How important are Core Web Vitals for SEO in 2026
How important are Core Web Vitals for SEO in 2026?

Core Web Vitals have evolved from a novel ranking factor to an essential SEO baseline by 2026. These performance metrics—LCP, INP, and CLS—measure real user experience and directly influence search rankings, especially in competitive niches. WordPress sites are uniquely positioned to excel with modern themes, efficient plugins, and proper hosting. While not the only ranking factor, Core Web Vitals act as crucial tiebreakers when content quality is comparable. Poor scores won't destroy strong content, but they'll cap your ranking potential. This comprehensive guide explores what's changed since 2023, how to measure and improve these metrics, and why performance optimization delivers compounding returns through better rankings and higher conversion rates.

Read more
How can I launch campaigns faster without developers
How can I launch campaigns faster without developers?

Marketing teams can launch campaigns in minutes instead of weeks by using modern WordPress block editors with custom component libraries and centralized data management. This comprehensive guide reveals how trading affiliates eliminate developer bottlenecks through self-service campaign creation. Discover the technical foundations, implementation timelines, and skills needed to transform your team from dependent on developers to independently deploying professional landing pages, comparison tables, and broker reviews that respond immediately to market opportunities.

Read more
delighted programmer with glasses using computer
Let’s talk about your WordPress project!

Do you have an exciting strategic project coming up that you would like to talk about?

wp
woo
php
node
nest
js
angular-2