{"id":126204,"date":"2014-03-06T08:00:00","date_gmt":"2014-03-06T13:00:00","guid":{"rendered":"http:\/\/premium.wpmudev.org\/blog\/?p=126204"},"modified":"2014-03-06T06:54:28","modified_gmt":"2014-03-06T11:54:28","slug":"dont-waste-time-improving-your-wordpress-site-search","status":"publish","type":"post","link":"https:\/\/wpmudev.com\/blog\/dont-waste-time-improving-your-wordpress-site-search\/","title":{"rendered":"Don&#8217;t Waste Time Improving Your WordPress Site Search"},"content":{"rendered":"<p>You&#8217;ll often find articles that start with how bad the built-in WordPress search function is (it&#8217;s not actually <em>that<\/em> bad) and then go on to explain how you can upgrade it.<\/p>\n<p>While there are truly excellent search plugins out there that add a plethora of new features, you need to make sure you know why you are upgrading because it&#8217;s quite possible that you might just be wasting your time, effort, and money.<\/p>\n<figure id=\"attachment_126845\" class=\"wp-caption aligncenter\" data-caption=\"true\"><img loading=\"lazy\" decoding=\"async\" class=\"size-ratio-large wp-image-126845\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2014\/03\/search-featured-700x295.jpg\" alt=\"Magnifying glass on top of euros\" width=\"700\" height=\"295\" \/><figcaption class=\"wp-caption-text\">Think carefully before spending time and money improving your WordPress search function<\/figcaption><\/figure>\n\n<p>There is no shortage of truly excellent search plugins both free and premium that bring considerable additional features and sophistication to the WordPress search function. But whilst you can boost the efficacy of your search quite easily, you first need to ask yourself whether adding that plugin is adding real value for the majority of your visitors or whether you&#8217;re simply adding to your WordPress maintenance burden.<\/p>\n<h2>Why Improving General Site Search Might Be A Waste Of Time<\/h2>\n<p>Before you embark on any updates to your WordPress site you need to assess whether they are going to give you a reasonable return on investment &#8211; not just any costs involved but also your time and effort.\u00a0And you need to be sure that you are applying the fix in the right place and that visitor usage of your site search is not just a symptom of some other problem.<\/p>\n<p>Before you do anything, you need to ask yourself the following questions.<\/p>\n<h3>Does My Site Search Have Room For Improvement?<\/h3>\n<p>On the face of it, site search seems like a function ripe for improvement but your analytics might say otherwise. For example, over the last twelve months for WPMU DEV, only 3.1% of visits involved a site search. More interestingly, despite 30% of those searches resulting in a subsequent search, the exit rate from the search results page is only 13%.<\/p>\n<p>Based on these stats, it&#8217;s highly doubtful whether there&#8217;s a need to spend any time or effort trying to reduce what is already a low exit rate for a mere 3% of visits.<\/p>\n<p>You should certainly look to your own analytics and see just how much traffic your site search is getting and what the exit rate is so that you can not only determine if you have a problem that needs fixing but also how much time and resources you should put into that fix.<\/p>\n<figure id=\"attachment_126843\" class=\"wp-caption aligncenter\" data-caption=\"true\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-126843\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2014\/03\/search-analytics.gif\" alt=\"Analytics from WPMU DEV search pages\" width=\"700\" height=\"207\" \/><figcaption class=\"wp-caption-text\">Does traffic to your search pages justify spending time trying to improve it?<\/figcaption><\/figure>\n<h3>Am I Forcing Visitors To Use Site Search?<\/h3>\n<p>For most sites, the use of site search is often the last resort by visitors because they have been unable to find the content they were looking for, in which case it may well be your information architecture that is at fault.<\/p>\n<p>You need to check that your navigation:<\/p>\n<ul>\n<li>Is logically grouped<\/li>\n<li>Labels are clear and unambiguous<\/li>\n<li>Terms are simple and not technical or jargon<\/li>\n<li>Provides context<\/li>\n<\/ul>\n<p>How can you check if your navigation is forcing your visitors to turn to search? Well, you can&#8217;t definitively but you can get some idea again by looking at the analytics and, in particular, the search terms. Look at what your visitors have been searching for and working out:<\/p>\n<ol>\n<li>Does relevant content exist? If not, then create it.<\/li>\n<li>Can you navigate to it? Why not? Is a case of mislabelling or is the content simply not hooked up to the navigation?<\/li>\n<li>Is it linked to <a href=\"https:\/\/wpmudev.com\/blog\/improving-wordpress-search\/\" target=\"_blank\" rel=\"noopener\">other related content<\/a>? If not, then add some; no content should be completely orphaned<\/li>\n<\/ol>\n<p>These issues can, and should, all be sorted without the need to look at search. Indeed, orphan content is worth checking on a regular basis as content should never exist in isolation.<\/p>\n<h3>Your Time Is Likely Better Spent Elsewhere<\/h3>\n<p>We&#8217;ve all got a finite amount of time we can spend on our sites and many of us have limited resources (financial and technical) so we need to make sure that we are always focussing on updates that will provide the most benefit.<\/p>\n<p>If visitors are searching for content that does exist on your site then it may be that your site structure and labeling that&#8217;s at fault and improving those aspects of your site will improve the experience for <em>all<\/em> your visitors not just those using the site search function.<\/p>\n<p>If your search analytics are anything like WPMU DEV&#8217;s then the argument for improving site search is fairly weak and your time might be better spent on the search function that has the biggest impact on your site: Google.<\/p>\n<figure id=\"attachment_126844\" class=\"wp-caption aligncenter\" data-caption=\"true\"><img loading=\"lazy\" decoding=\"async\" class=\"size-full wp-image-126844\" src=\"https:\/\/wpmudev.com\/blog\/wp-content\/uploads\/2014\/03\/search-google.gif\" alt=\"Results page for a search on Google for WPMU DEV\" width=\"700\" height=\"402\" \/><figcaption class=\"wp-caption-text\">Want to spend time improving search? Perhaps this is where you should spend it<\/figcaption><\/figure>\n\n<h2>So Improving Site Search Is A Waste Of Time Then?<\/h2>\n<p>Despite the above, there are four situations where improving your site search makes sense:<\/p>\n<h3>1. You have a large site, with significant traffic to the search function which has a high exit rate<\/h3>\n<p>In this situation then you are probably best advised to start looking at the off-site search providers.\u00a0Remember, searching, especially full-text searching, is a database-intensive activity and so is particularly sensitive to the volume of content and the use of the search function.<\/p>\n<p>While you will get a much wider range of functionality such as results sorted by relevance, Did You Mean suggestions, and PDF indexing, the primary reason for an off-site solution is taking the load off your hosting environment.<\/p>\n<p>Shifting your search to a third-party is usually a simple process. Generally, you&#8217;ll sign-up for an account, the service will crawl and index your site and you&#8217;ll install a plugin that will link your site with your account and will handle the search requests and the returning of the results.<\/p>\n<p>A couple of off-site search providers include <a title=\"Read more about Google Custom Search Engine\" href=\"https:\/\/www.google.com\/cse\/\" rel=\"noopener\" target=\"_blank\">Google<\/a> and\u00a0<a title=\"Read more about Swiftype\" href=\"https:\/\/swiftype.com\" rel=\"noopener\" target=\"_blank\">Swiftype.<\/a><\/p>\n<h3>2. You want to provide a specific search function (e.g. product search)<\/h3>\n<p>Again, while you can do this yourself, if you want to start searching using a custom field or restrict the search to a particular content type, taxonomy or category then it&#8217;s probably better to use one of the reputable search engines that are available.<\/p>\n<p>These will provide all that functionality and more, along with ordering by relevance and weighting with little to no coding with extensive configuration available via their settings panels.<\/p>\n<p>If you are prepared to get your hands dirty with a bit of template building then the SearchWP plugin actually provides a &#8220;supplementary search engine&#8221; feature which allows the building of multiple search functions all from the one index. For example, this would allow the main engine to exist alongside an engine that only gave results from the product&#8217;s custom post type with its own settings for weightings.<\/p>\n<p>Plugins to consider in this scenario:<\/p>\n<ul>\n<li><a title=\"Learn more about Relevanssi\" href=\"http:\/\/www.relevanssi.com\/\" rel=\"noopener\" target=\"_blank\">Relevanssi<\/a> (Annual $99, Permanent $349)<\/li>\n<li><a title=\"Learn more about SearchWP\" href=\"https:\/\/searchwp.com\/\" rel=\"noopener\" target=\"_blank\">SearchWP<\/a> (Standard $99, Pro $149, Agency $299)<\/li>\n<li><a title=\"Learn more about Better Search\" href=\"http:\/\/wordpress.org\/plugins\/better-search\/\" rel=\"noopener\" target=\"_blank\">Better Search<\/a>\u00a0(Free, weighting of title and content only)<\/li>\n<li><a title=\"Learn more about WP Advanced Search\" href=\"http:\/\/wordpress.org\/plugins\/wp-advanced-search\/\" rel=\"noopener\" target=\"_blank\">WP Advanced Search<\/a> (Free, requires its own PHP function to produce the search form\/results)<\/li>\n<\/ul>\n<h3>3. You want to index PDFs<\/h3>\n<p>As we know, the built-in WordPress search function only searches the post table so attachments and uploads are not going to be indexed.<\/p>\n<p>If you have a library of PDF documents (perhaps back issues) then you may want to be able to index the text in the PDFs (you won&#8217;t get far with any search engine if your PDF doesn&#8217;t contain actual text) so that the documents themselves can be returned in search results on your site.<\/p>\n<p>As far as I know, there&#8217;s only one plugin that will index PDFs:\u00a0<a title=\"Learn more about SearchWP\" href=\"http:\/\/searchwp.com\" rel=\"noopener\" target=\"_blank\">SearchWP<\/a>.<\/p>\n<h3>4. You want more control over how results are ordered<\/h3>\n<p>The built-in WordPress search is actually a lot more flexible than it is given credit for. As it uses <a title=\"Learn more about WP_Query\" href=\"http:\/\/codex.wordpress.org\/Class_Reference\/WP_Query\" rel=\"noopener\" target=\"_blank\">WP_Query<\/a>, it is possible to manipulate the results in all manner of ways including restricting the search to a particular content type, searching a custom field, and searching by taxonomy and so some pretty sophisticated searching can be achieved without needing to reach for a plugin.<\/p>\n<p>However, if you want to go beyond what WP_Query can offer and utilize <em>relevance<\/em> and <em>weighting<\/em> then you&#8217;ll have to get some third-party help. Relevance is a score for how closely the result matches the search term and so the aim is to have those items that are the closest matches (or have multiple matches) at the top of the results.<\/p>\n<p>Weighting allows manipulation of the relevance calculation by being able to say that a match in a title, for example, is more important than a match in the content. The more sophisticated plugins such as SearchWP and Relevanssi will allow weighting to be applied to virtually all fields including custom fields allowing for incredibly fine-grained control.<\/p>\n<p>Usually these plugins &#8220;replace&#8221; the built-in search function altogether rather than just manipulating the results:<\/p>\n<ul>\n<li><a title=\"Learn more about Relevanssi\" href=\"http:\/\/www.relevanssi.com\/\" target=\"_blank\">Relevanssi<\/a> (Free, $39)<\/li>\n<li><a title=\"Learn more about SearchWP\" href=\"https:\/\/searchwp.com\/\" rel=\"noopener\" target=\"_blank\">SearchWP<\/a> ($20)<\/li>\n<li><a title=\"Learn more about Better Search\" href=\"http:\/\/wordpress.org\/plugins\/better-search\/\" rel=\"noopener\" target=\"_blank\">Better Search<\/a> (Free, the weighting of title and content only)<\/li>\n<li><a title=\"Learn more about WP Advanced Search\" href=\"http:\/\/wordpress.org\/plugins\/wp-advanced-search\/\" rel=\"noopener\" target=\"_blank\">WP Advanced Search<\/a> (Free)<\/li>\n<\/ul>\n<p>This scenario is pretty tenuous though. Whilst the results will likely be improved if traffic to your site search is low and \/ or the site exit percentage is also low then there may not be any benefit in adding yet another plugin to your installation.<\/p>\n\n<h2>Final Thoughts<\/h2>\n<p>The WordPress search is much maligned but it&#8217;s probably not justified and the importance of a search function is often overstated.<\/p>\n<p>Often the use of search is a sign that something is not quite right with your site and the fix is not to improve your search but to improve your site&#8217;s content, structure, or navigation or all three. And of course, you need to be across the analytics and critically assess whether the traffic to the search pages really warrants spending time trying to improve it.<\/p>\n<p>That said, there are scenarios where more sophistication is required and there are a number of really excellent plugins and off-site services that can help you. As is always the case, though, you need to carefully think through what your requirements are and then find the plugin that best matches.<\/p>\n<p>Photo Credit: <a title=\"View this photo on flickr\" href=\"http:\/\/www.flickr.com\/photos\/59937401@N07\/5858002158\/\" rel=\"noopener\" target=\"_blank\">Images Money<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>There are many excellent WordPress search plugins that can greatly enhance the WordPress search form and search results. But trying to improve your search may just be a waste of time.<\/p>\n","protected":false},"author":262394,"featured_media":192476,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"blog_reading_time":"","wds_primary_category":0,"wds_primary_tutorials_categories":0,"footnotes":""},"categories":[263],"tags":[186],"tutorials_categories":[],"class_list":["post-126204","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-tutorials","tag-search"],"_links":{"self":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/126204","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/users\/262394"}],"replies":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/comments?post=126204"}],"version-history":[{"count":3,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/126204\/revisions"}],"predecessor-version":[{"id":192475,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/posts\/126204\/revisions\/192475"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/media\/192476"}],"wp:attachment":[{"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/media?parent=126204"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/categories?post=126204"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/tags?post=126204"},{"taxonomy":"tutorials_categories","embeddable":true,"href":"https:\/\/wpmudev.com\/blog\/wp-json\/wp\/v2\/tutorials_categories?post=126204"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}