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

# Recently viewed

> Automatically track and display products your customers have viewed.

The recently viewed feature keeps a running list of products each customer has looked at. It appears as a section inside the Swish drawer, giving shoppers a quick way to revisit items without searching again.

## How it works

1. When a customer opens a product detail page, the SDK records that product in a **smart list** called `recently-viewed`.
2. The most recent 8 items are displayed in the drawer under a "Recently viewed" section.
3. Clicking a product in the list opens its product detail view inside the drawer.

Tracking happens automatically -- there is no extra code to add on product detail pages.

> [!NOTE]
>
> Recently viewed data is tied to the current customer session. Logged-in
> customers see their history across devices, while guest visitors see history
> for the current browser only.

## Enabling or disabling

The feature is **enabled by default**. To hide the recently viewed section from the home view, set `hidden: true` on the `recently-viewed` section:

```js theme={null}
window.SwishOptions = {
  ui: {
    home: {
      sections: [
        { type: "sign-in" },
        { type: "notifications" },
        { type: "recently-viewed", hidden: true },
        { type: "saved-from-cart" },
        { type: "saved-items" },
        { type: "lists" },
      ],
    },
  },
};
```

See the [Home view guide](https://swish.app/docs/guides/customize/views/home.md) for the full home section configuration.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.