> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stackfront.digital/llms.txt
> Use this file to discover all available pages before exploring further.

# Products & Search Overview

# Products & Search

The SDK provides hooks and services for browsing your Shopify catalog — product listing, single product detail, collections, and full-text search. All queries go through the Shopify Storefront GraphQL API via the `ProductService`.

## Quick Reference

| Hook                 | Returns                | Purpose               |
| -------------------- | ---------------------- | --------------------- |
| `useProducts()`      | Paginated product list | Infinite-scroll grids |
| `useProduct(handle)` | Single product         | Product detail screen |
| `useCollections()`   | Collection list        | Collection browser    |
| `useSearch()`        | Search results         | Search input UI       |

## Service Methods

All hooks wrap the `ProductService`, which is also accessible directly from `useStackfront()`:

```ts theme={null}
const { products } = useStackfront();
await products.getProducts(20, afterCursor);
await products.getProduct('cool-shirt');
await products.getProductById('gid://shopify/Product/123');
await products.getCollections(10, afterCursor);
await products.getCollection('summer-collection');
await products.searchProducts('red shoes', 20);
```

## Response Shape

All product queries return Shopify's standard GraphQL product shape via the Storefront API. See [Types Reference](/docs/types-reference) for the full type details.
