Shopify Builds>Primitives>Storefront search

Storefront search

Definition

Storefront search is Shopify's full search endpoint. A theme submits a query to /search with optional type and filter parameters, and the platform returns matching products, articles and pages as a paginated result set the search template renders. Unlike the predictive endpoint, it is a real page at a real URL, and it accepts the same facets a collection does.

Documented at https://shopify.dev/docs/storefronts/themes/navigation-search/search.

How we've used it

The stock results page is a list; what merchants want is a merchandised one. On one storefront the template gained AJAX submission and pagination that appends the next page instead of reloading, plus promo tiles a merchandiser targets at specific keywords — so a search for a discontinued line surfaces its replacement rather than nothing. On another it became tabbed: products, articles and pages as separate panels over the same query, with Shopify's facets on the product tab. Both carry the same unglamorous piece of logic underneath. Search reaches products no collection links to, so hidden and staff-only SKUs have to be suppressed from results explicitly, in both the server-rendered pass and the appended one.

Builds using it

One further gated build uses it; its page follows.

Related entities

Predictive Search API · Storefront filtering · Liquid pagination · Section Rendering API

Builds