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

# Recently viewed

> Show Shoppers the products they viewed recently in a horizontal carousel, tracked per browser and per Customer.

<Warning>
  **Experimental.** This Module has no test or production evidence recorded yet. Read it, run it locally, and hold off on real Orders. See [maturity levels](/docs/resources/versioning).
</Warning>

The Recently Viewed [Module](/docs/concepts/modules) records every product detail page a [Shopper](/docs/resources/glossary#shopper) visits and shows those products in a carousel. State is stored per browser for [Guests](/docs/resources/glossary#guest) and merged into the [Customer](/docs/resources/glossary#customer) record on sign-in.

**Source:** [`modules/recently-viewed`](https://github.com/86d-store/86d/tree/main/modules/recently-viewed) · **npm:** [`@86d-store/recently-viewed`](https://www.npmjs.com/package/@86d-store/recently-viewed)

## Installation

```sh theme={null}
86d module add recently-viewed
```

## Configuration

```ts theme={null}
recentlyViewed({
  maxItems: "20",
  retentionDays: "30",
});
```

## Store endpoints

| Method | Path                     | Description                    |
| ------ | ------------------------ | ------------------------------ |
| `POST` | `/recently-viewed/track` | Record a view                  |
| `GET`  | `/recently-viewed/me`    | Get the current Shopper's list |

## Components

* `<RecentlyViewed />`: horizontal carousel; fetches its own data.

## Related pages

* [Recommendations](/docs/modules/recommendations)
* [Products](/docs/modules/products)
* [Versioning and maturity](/docs/resources/versioning)
* [Glossary](/docs/resources/glossary)
