Magento 1.8 – How to Fix Random Search Results

catalogsearchce-1.8.1.0ce-1.9.0.1magento-1.8

Here is a major problem we've had from Magento 1.4 that is still a problem in Magento CE 1.8.1.

If you search for a product the results that come back are not what you'd expect.

For example if I search for Canon 6D then the top search result is Canon EOS Rebel SL1 (Body Only), even though there is a product whose title is exactly "Canon 6D".

Then if I search for only 6D then the top search result is Nikon AF Nikkor 70-300 f/4-5.6D ED Telephoto Zoom Lens… because, I guess, it has the two characters "6D" next to each other somewhere in the title? Below that is Nikon D800 36.3 MP CMOS FX-Format Digital SLR Camera (Body Only) which doesn't even have the characters "6D" found together anywhere in the title at all.

When I have done some research into this, I keep finding people who are saying that it's just how Magento is, and the only way to fix it is either override the core code with some hack or another, or, use an extension.

I found a free extension that uses Apache SOLR, but it requires the installation of SOLR first, which is fairly complicated, and I'm not even sure our hosting provider would allow that, since it runs in Java and I don't know if our server has the right version of JRE etc. So this solution is very much not ideal.

Then there are some very expensive paid extensions, and I'm sure I can't get approval for that.

It just makes me wonder if there might be something corrupt about our particular Magento installation, and if so, what might it be? What would cause this? Maybe we have some old extension hidden somewhere, screwing things up, or maybe our database is corrupted. What do you think?

I'm don't want to believe that this is just how Magento is, even though I've seen plenty of posts on the Magento forums that complain of this same issue. I know there are several old bugs that keep not getting fixed in Magento CE, but surely the developers of Magento would fix search if it was broken, since it's arguably the most important feature of an e-commerce site.

So what's the deal? Please help. Thanks.

Best Answer

In super-short: see Search Type: Like, Full Text or Combined?

In short, Magento's default search is not great.

That said, all I can really recommend is tweaking/configuring to improve the search behavior. Some things to consider (if you have not already):

  • Tweak product attributes to limit which attributes are being searched - if all you care about is the product name and description, considering setting the "searchable" field to false for other fields. This may not meet your requirements, but it might be worth experimenting with
  • Use the "search terms" feature of Magento (Catalog -> Search Terms). If you want "6D" to always bring customers to the 6D body (or kit, etc) product page, you can do that with the search terms feature. This is perhaps not a solution the bad search, but at least can help triage some of the more important search terms and fix the most common problem terms.
  • Consider tweaking the Search Type (System -> Configuration -> Catalog (left) -> Catalog Search) and again, read more here

In my experience with search in Magento, no search is going to be absolutely perfect out of the box. I think that Search Terms is actually a great tool for helping you get a handle on major problem areas, and some tweaking of Magento search options/attributes can make the default search at least workable. Magento's SOLR implementation is notoriously bad (and in my experience, that's relatively accurate). There are great third party modules out there (my company is actually developing one), but as you said they do require a bit more setup, and again, even still you're going to need to tweak things.

Related Topic