Would you like to show certain blog posts or products at the top of the search results for certain keywords in WordPress?
The default search doesn’t allow you to control the search results order. As a result, when someone searches for your main services, they might have to scroll past old blog posts and random pages to find what they need.
By changing the results order, you can deliver more relevant search results to your visitors and improve their user experience.
In this step-by-step guide, we’ll show you the easiest way to change the order of search results on your site.
Why Change the Search Results Order in WordPress?
Customizing the order of search results on your site can be useful for several reasons.
First, by default, WordPress sorts search results not by relevance but by publication date.
As a result, the newest posts rank higher than the older ones. It makes no sense, since a fresher publication date doesn’t mean higher post relevance.
By manually changing the order of the search results, you can tackle this issue and deliver the most relevant matches to your visitors.
Secondly, reordering search results come in handy when you want to promote a specific page or product on your site.
You can put it at the top of your search results so that it gets more views. That’s a quick and free way to improve visibility of your content and increase your profits.
That said, let’s look at how you can easily change the search results order in WordPress.
Change the Search Results Order on Your Site
The fastest and easiest way to change the order of search results with no coding is to use a plugin like SearchWP.
This is the best WordPress search plugin that comes with tons of useful features to improve your website search.
Customizing the order of search results is just one of them. You can also use SearchWP to track your visitors’ searches, add search by categories, and many more.
Even though it’s a powerful tool, it’s also beginner-friendly. With SearchWP, you can get full control over how search works on your site regardless of your WordPress experience.
More than 50,000 site owners around the globe already use it to help their visitors find the right content faster.
Here are some other SearchWP features that’ll help you boost your search:
- Automatic theme integration: Like when everything works out of the box? SearchWP seamlessly integrates with existing search forms on your site, whatever theme you use.
- Searchable custom fields: Want your search to display more relevant content? Make WordPress consider the content of custom fields when performing searches with SearchWP.
- PDFs and documents indexing: Uploading PDF files or office documents to your site? With SearchWP, you can include them in search results, making it easier for your visitors to find them.
- Multiple search engines support: Looking for a way to create a custom search form? Using SearchWP, you can add a supplemental search engine, customize it, and link to a specific search form on your site.
With that, let’s take a look at the step-by-step process of customizing the search results order with SearchWP.
Step 1: Install and Activate SearchWP
First, you’ll need to get your copy of SearchWP by visiting the website and creating a new account.
Next, you can sign in to your SearchWP account and go to the Downloads tab.
Once there, simply click Download SearchWP and save the plugin files on your computer.
When you’re done, you should also copy the plugin’s license key on the same tab.
Next, you’ll need to upload the SearchWP plugin’s ZIP file to your site. You can follow this guide on how to install a WordPress plugin if you need help.
Once the plugin is active, you’ll see the SearchWP welcome screen and setup wizard. Go ahead and click the ‘Start Onboarding Wizard’ button and follow the onscreen instructions.
Now that SearchWP is up and running on your site, the next step is to install the Custom Results Order extension.
Step 2: Install the Custom Results Order Extension
The SearchWP Custom Results Order extension allows you to affect the order of the search results and customize it to fit your needs.
To get started, you’ll need to head to SearchWP » Extensions from your WordPress dashboard.
From here, you can navigate to the Custom Results Order extension and then click the ‘Install’ button.
The extension will then automatically install and activate on your site.
Now, you’re ready to start customizing the order of search results.
Step 3: Change the Order of Search Results on Your Site
First, you will need to go to SearchWP » Algorithm from your WordPress dashboard and then switch to the ‘Custom Results Order’ tab.
Here you can specify search queries for which you want to have a custom search result order.
To add a new search query, enter it in the Enter search query field and click Add Search Query.
For example, let’s say we want to adjust the order of search results for the ‘wordpress’ search query for the default engine on our site.
Here’s how the search query settings would look:
After you’ve added a search query, SearchWP will offer you to set your own order of search results for this query.
You can simply click the ‘Promote to Top’ button for the posts that you’d like to appear at the top of the search results.
Let’s say we want the “TOP-3 WordPress eCommerce plugins” post to appear on the top of search results.
To do that, we’ll press the Promote to Top button next to it.
That’s it. The post you chose now appears at the top of search results.
If you want to undo the results order, then simply click the ‘Remove Promotion’ button.
You can also change the position of several posts in the search results.
To do that, simply click the Promote to Top button next to each of them in the order you want them to appear in the search results.
For instance, let’s move the “TOP-3 WordPress eCommerce plugins” post to second place and put the “What is the Best CMS” post first.
This is what the final result looks like on our test site:
Now, let’s also make sure that we can see these changes on the site itself.
Step 4: Check Out Your Customized Search Results
To do that, simply visit your website and head to the search form.
From here, enter in the search box the search query for which you changed the search results order.
As you can see, the order of search results we got is exactly the same as the one we customized with SearchWP.
This shows that the custom results order feature is working perfectly.
FAQs about Changing Search Results Order
Here are some common question users have about altering the search results order in WordPress.
1. How do you sort search results in WordPress?
By default, WordPress sorts search results by publication date, displaying the most recent posts first. To sort search results differently, you can use a plugin like SearchWP. This plugin allows you to sort search results based on criteria such as relevance, custom post types, or specific keywords.
2. Why should I change the search results order in WordPress?
Changing the search results order can help:
- Improve relevance: WordPress, by default, sorts results by publication date, which may not reflect content relevance.
- Highlight important content: Promote specific posts, pages, or products to improve visibility and user experience.
3. Can I reverse the changes if needed?
Yes, you can undo changes by clicking the ‘Remove Promotion’ button next to the post you want to demote in the search results.
What’s Next…
By promoting certain topics to the top, you make it easier for your visitors to find the content they’re looking for.
We hope this article helped you learn how to change the search results order in WordPress. You may also want to see our guide on how to search posts by tags in WordPress and how to exclude category from WordPress search.
If you’re ready to start customizing the order of search results on your site, you can grab your copy of SearchWP here.