Shopify predictive search doesn't give results for articles at all

Bug on shopify predictive search that doesn’t give results for articles at all.

articles with similar word is available in blog posts, but always 0 on result :joy:

Can you please share store url and which term you are searching so that i can check ?

sorry, can’t share the url but i believe if this is on my store , its everywhere and obvious. everything is fine in code.

It shows everything correctly on normal search “/search”.

but issue is on Predictive Search “/search/suggest?q=”

YKWM.

try searching on a store if you have available, search form must be predictive one.

Please try this /search/suggest.json?q=m&resources[type]=article to fetch articles and it should work.
You have add resources[type] to fetch particular type
Thanks!

I can totally understand how you feel. Currently, the search function within most Shopify themes show a mix of result (product, article, collection) - usually dominated by product result.

There is a need for content aka blog post oriented search, so I end up created an app for it.

It’s called Blog Articles Filter & Search PRO, a 3-in-1 blog article discovery tool:

  • Blog keyword search - Specific to blog
  • Blog filter - Setup and customize your own filters with blog article tags
  • Featured articles - Show 3 articles as featured at the search panel

You can try it out for free here (5 days free trial).

I’d love to know what you think.


Choong_HueApps_0-1675867988727.jpeg


Choong_HueApps_1-1675867994460.jpeg

yes, that route gives the result.
https://example.myshopify.com/search/suggest.json?q=w&resources[type]=article

but this route doesn’t but suppose to be:
https://example.myshopify.com/search/suggest.json?q=w

it gives products, collections and pages but not articles.

Its because its default value is “query,product,collection,page”
See shopify doc: https://shopify.dev/docs/api/ajax/reference/predictive-search#get-locale-search-suggest
So, to return article as well you can do like this:
https://example.myshopify.com/search/suggest.json?q=w&resources[type]=query,product,collection,page,article

Thanks!

Hey, sorry for my delay. it worked!

Thank for your help..

not sure why shopify would exclude that by default, doesn’t make sense.