Disclosure: This site contains affiliate links. We may earn a commission when you sign up through our links at no extra cost to you.
Performance

WordPress Search Performance: Why the Default Search Is Slow and How to Fix It

By speedysite.net 8 min read

WordPress's built-in search uses slow LIKE queries that don't scale. Learn why default search struggles on larger sites and which solutions — from free plugins to Elasticsearch — actually work.

Want the fastest WordPress hosting?

Rocket.net delivers 83ms average TTFB - up to 153% faster than competitors. Try it risk-free.

If your WordPress site has grown past a few hundred posts, you’ve probably noticed that the built-in search starts to drag. Visitors type a query, wait a moment longer than expected, and sometimes get back results that don’t match what they were looking for. This isn’t a configuration problem — it’s a fundamental limitation of how WordPress search works by default.

How WordPress Default Search Works

WordPress ships with a search system built directly on MySQL LIKE queries. When a visitor searches your site, WordPress runs a query that looks roughly like this:

SELECT * FROM wp_posts
WHERE post_status = 'publish'
AND (
  post_title LIKE '%keyword%'
  OR post_content LIKE '%keyword%'
)

The %keyword% pattern — with wildcards on both sides — forces MySQL to scan every row in the wp_posts table. It cannot use an index because the wildcard at the beginning of the string makes index use impossible. This is called a full table scan, and it gets slower as your post count grows.

On a site with a few dozen posts, this is imperceptible. On a site with thousands of posts, products, or custom post type entries, it becomes a measurable bottleneck.

What Makes Default Search Worse

Beyond the query structure, several factors compound the performance problem:

Wide columns: post_content stores the full HTML of every post. Scanning that column for every search query is expensive. A long post with embedded blocks, shortcodes, and metadata can run to tens of thousands of characters — all of which must be examined on every search request.

No relevance ranking: The default query returns any post where the keyword appears anywhere in the title or content. Results are ordered by date, not by relevance. A post where your keyword appears in passing ranks the same as one dedicated to the topic.

Custom post types and fields: Default search only looks at post_title and post_content. If you have custom post types — products, events, team members, portfolio items — or custom fields (ACF, Meta Box, Pods), none of that data is included in search results unless you write custom SQL to include it.

Taxonomy data excluded: Tags and categories are not searched. A visitor searching for a tag name won’t find posts with that tag unless those words also appear in the post title or body.

How to Measure Your Search Speed

Before optimizing, get a baseline. The Query Monitor plugin (free in the WordPress plugin repository) adds a toolbar to your admin that shows database query counts and timing for every page load, including search results pages.

Run a few searches on your live site with Query Monitor active, note the total query time and the number of queries triggered by the search, and check whether any individual queries stand out as slow.

You can also use the slow_query_log feature in MySQL if you have server access, which logs any query taking longer than a configurable threshold (often 1 second by default).

Option 1: Relevanssi (Free and Premium)

Relevanssi is a free WordPress plugin that replaces the default search with a custom full-text indexing system built on top of your existing database.

After installing and indexing your content, Relevanssi:

  • Searches post titles, content, excerpts, and optionally custom fields and taxonomy terms
  • Returns results ranked by relevance, not date
  • Highlights matching terms in search result excerpts
  • Supports fuzzy matching (finds “optimization” when someone types “optmization”)
  • Works with WooCommerce products and custom post types

Relevanssi stores a custom index in your database, which it updates whenever posts are published or modified. The index adds read overhead (more database rows) but makes searches dramatically faster because queries hit indexed columns rather than doing a full table scan on wp_posts.

The free version covers most use cases. The premium version adds multi-site support, user and taxonomy search, AND/OR/NOT search operators, and more granular relevance weighting controls.

Installation is straightforward: install the plugin, run the initial index build from the Relevanssi settings page, and your search results improve immediately without any code changes.

Option 2: SearchWP (Premium)

SearchWP is a premium search plugin that also replaces WordPress’s default search engine with a custom indexer. It’s particularly well-suited for WooCommerce stores and sites with complex custom field setups.

SearchWP’s strengths:

  • Fine-grained control over what content is indexed and how much each field is weighted in relevance scoring
  • Support for PDFs, custom post types, and any custom fields with the right extensions
  • Integration with WooCommerce product attributes, SKUs, and product metadata
  • Shortcode and block support for custom search forms

SearchWP starts at $99/year for a single site license. For content-heavy or e-commerce sites where search is a primary navigation path, the relevance improvements typically justify the cost.

Option 3: ElasticPress with Elasticsearch

For high-traffic sites with large content libraries, the most scalable solution is replacing the MySQL-based search entirely with a dedicated search engine: Elasticsearch.

ElasticPress is an open-source WordPress plugin that syncs your content to an Elasticsearch cluster and routes all WordPress searches through the Elasticsearch index instead of MySQL.

Elasticsearch is designed specifically for full-text search. It uses inverted indexes — the same structure that powers searches at large scale — and returns results significantly faster than MySQL LIKE queries on large datasets. It also handles relevance scoring, fuzzy matching, synonym support, and faceted filtering out of the box.

The tradeoff is operational complexity. You need:

  • A running Elasticsearch or OpenSearch instance (can be hosted via Elastic Cloud, Amazon OpenSearch, or a self-managed server)
  • The ElasticPress plugin configured to point to that instance
  • Ongoing maintenance of the cluster

Some managed WordPress hosts offer Elasticsearch as a bundled feature. If your host doesn’t, hosting an Elasticsearch cluster separately adds cost and infrastructure to manage.

For sites with tens of thousands of posts or product catalogs, or sites where search is a primary discovery mechanism (media publishers, documentation sites, large stores), ElasticPress is worth the added complexity.

Option 4: Algolia

Algolia is a hosted search-as-a-service platform with a WordPress plugin. Instead of running search on your own server, you sync your content to Algolia’s infrastructure and search requests are handled by their API.

Algolia is extremely fast because searches run on purpose-built infrastructure with a globally distributed edge network. The WordPress plugin handles indexing automatically when content is published or updated.

The main limitation is cost. Algolia’s free plan covers 10,000 records and 10,000 search operations per month, which is adequate for small sites. Traffic beyond that moves to paid tiers that can become significant for large or high-traffic sites.

Algolia makes sense for sites with a strong emphasis on search UX — instant search with autocomplete, faceted filtering, personalized results — where search quality is a competitive differentiator.

Many themes implement “live” search that returns results as the user types, using JavaScript to fetch results in the background via the WordPress REST API or admin-ajax.php.

These implementations depend on the same underlying search query. Replacing the search engine with Relevanssi, SearchWP, or Elasticsearch improves live search results automatically, since those plugins hook into WordPress’s native search functions.

If your live search is slow specifically because of frequent small queries, server-side caching of search results (using object caching or a transient layer) can help reduce the database load, but it’s a secondary optimization — fixing the underlying query first is more impactful.

Practical Guidance by Site Size

Site typeRecommended approach
Blog, <500 postsRelevanssi free
Content site, 500–5,000 postsRelevanssi premium or SearchWP
WooCommerce storeSearchWP with WooCommerce extension
High-traffic or 10,000+ postsElasticPress with hosted Elasticsearch
UX-critical or autocomplete searchAlgolia

The Hosting Layer Matters

Even with a better search plugin installed, search performance is shaped by available server resources. Each search request still runs PHP and hits your database (or an external search index). Sites on shared hosting are subject to resource throttling that can make any search solution feel sluggish during traffic spikes.

Managed WordPress hosting isolates your site’s PHP and database processes from other tenants. When a search request comes in, your PHP processes aren’t competing with other sites for CPU time, and your database connections aren’t queued behind unrelated workloads.


Rocket.net is managed WordPress hosting built on enterprise infrastructure, with isolated resources per site and a global CDN. If your site has outgrown shared hosting — or if search latency is only one symptom of a broader performance ceiling — it’s worth comparing what managed hosting makes possible.

Performance tip: Your hosting provider has a bigger impact on WordPress speed than any plugin or optimization. We've tested dozens of hosts - Rocket.net consistently delivers the best results.

View Rocket.net Pricing →
WordPress search performanceWordPress search slowWordPress search optimizationRelevanssi WordPressSearchWPElasticPress WordPressWordPress LIKE queryimprove WordPress searchWordPress full-text search

Ready to switch to faster WordPress hosting?

Join thousands who've made the switch to Rocket.net. Try any plan for just $1.

Start Your $1 Trial

30-day money-back guarantee • Free migrations • No contracts

Related Articles