# Chat history

> Persistent threads with a checkpointer and a threadStore, and the History button in the chat.

Source: https://sideagent.dev/docs/history

`AgentChat` has a History button (list, open, delete), reopens the last conversation after a refresh, and restores a pending approval.

Messages live in your LangGraph `checkpointer`. The list of threads lives in a `threadStore`, in memory by default. Both must be persistent in production:

```ts
createAgent({ /* ... */ checkpointer: new PostgresSaver(/* ... */), threadStore: myThreadStore });
```

A `ThreadStore` implements `list`, `has`, `touch` and `delete`. History is only shown from the user's own index.
