---
title: What data do LangGraph checkpointers store and how long should you keep it?
url: https://opencontroller.lyzr.com/blog/langgraph-checkpointer-data-retention
published: 2026-11-15
updated: 2026-11-15
author: Lyzr
---

# What data do LangGraph checkpointers store and how long should you keep it?

**A LangGraph checkpointer saves the full graph state for every thread at the end of each step. That state usually holds the conversation messages, tool inputs and outputs, and any intermediate values your nodes write, so it often contains personal or confidential data. Treat it as a regulated data store: set a retention period per use case, and delete threads when that period ends.**

Checkpointers are what make LangGraph agents durable. They let a graph resume after a failure, pause for human input and remember a conversation. They also quietly accumulate everything the agent saw.

## What exactly does a checkpointer store?

A checkpoint is a snapshot of graph state, keyed by a `thread_id`. LangGraph writes one at the end of each superstep by default. Depending on how you design state, a snapshot can include:

- The full message list: user prompts, model responses and system messages
- Tool call arguments and tool results, such as database rows or API responses
- Retrieved documents passed between nodes
- Pending writes from nodes that have not yet been committed
- Interrupt payloads waiting for a human decision

Because every step is kept, one long conversation can produce many checkpoints. Large payloads, such as base64-encoded files placed in state, make each one bigger. LangChain's own guidance is to keep large objects in external storage and hold a reference in state.

## Which checkpointer backends exist, and where does data live?

| Backend | Where data lives | Typical use | Retention risk |
|---|---|---|---|
| `InMemorySaver` | Process memory | Tests, local dev | Lost on restart; low |
| `SqliteSaver` | A local SQLite file | Prototypes, single-node apps | Files copied around laptops and CI |
| `PostgresSaver` | Your Postgres database | Production | Grows forever without cleanup |
| LangGraph Platform | Managed Postgres in the deployment | Hosted agents | Configurable TTL |

With `PostgresSaver`, state sits in tables such as `checkpoints`, `checkpoint_blobs` and `checkpoint_writes`. Anyone with read access to that database can read every conversation. Include those tables in your data classification, backup and access review processes.

## How do you delete checkpoint data?

There are two mechanisms.

**Self-managed checkpointers.** Savers expose `delete_thread(thread_id)`, which removes a thread's checkpoints and writes. LangGraph does not run a sweeper for you, so you need a scheduled job that finds threads past their retention date and deletes them. Keep a table mapping `thread_id` to user, use case and last activity so the job knows what to remove.

**LangGraph Platform deployments.** You can set a TTL under `checkpointer.ttl` in `langgraph.json`:

```json
{
  "checkpointer": {
    "ttl": {
      "strategy": "delete",
      "default_ttl": 1440,
      "sweep_interval_minutes": 10
    }
  }
}
```

`default_ttl` is minutes of inactivity, so 1440 is 24 hours. The clock resets on new activity. With the `delete` strategy, expiry removes the thread, its checkpoints, its writes and its run records in one cascade. Two caveats from LangChain's documentation: TTL applies only to checkpoints created after you enable it, so older data needs a one-off cleanup; and LangSmith traces are not deleted, because they live in a separate backend with their own retention.

## How long should you keep agent state?

There is no single right answer. Data protection law, such as the GDPR storage limitation principle in Article 5, expects you to keep personal data no longer than needed for the purpose. Work out the purpose per agent, then set the shortest period that serves it.

1. **Classify the agent.** Does state contain personal, financial or health data, or only internal operational data?
2. **Identify why you keep state.** Crash recovery needs hours. Multi-session conversations may need days or weeks. Audit evidence usually belongs in a separate, minimised log, not raw checkpoints.
3. **Set a TTL per graph.** Short for customer-facing chat, longer only where a documented need exists.
4. **Separate long-term memory.** Facts the agent should remember across threads belong in a store with its own rules; see [governing AI agent memory stores](/blog/govern-ai-agent-memory-stores).
5. **Handle deletion requests.** Be able to find every thread for a user and delete it on request.
6. **Cover the copies.** Database backups, replicas, exported traces and SQLite files on laptops all need the same policy.
7. **Review quarterly.** Check table growth and confirm the sweeper or job is running.

Human-in-the-loop flows deserve attention. A thread paused by an [interrupt for human approval](/blog/langgraph-interrupts-for-human-approval) must survive until someone decides, so make sure your TTL is longer than your approval window.

## How Opencontroller does this

Retention is a property of each agent and version, so it belongs in the inventory. Opencontroller keeps a governed registry of agents, versions, tools and MCP servers, and works with open standards such as OpenTelemetry for traces. Policy as code lets you express rules for the estate. For production LangGraph patterns, see [governing LangGraph agents in production](/blog/govern-langgraph-agents-in-production) and the wider [guide to governing AI agents across platforms](/blog/how-to-govern-ai-agents-across-platforms). [Book a demo](https://www.lyzr.ai/book-demo/) to see it on your agents.

## Frequently asked questions

**Is checkpoint data encrypted by default?**
That depends on your database. Postgres and SQLite store what LangGraph writes, so apply encryption at rest and strict access control as you would for any sensitive table.

**Can I keep checkpoints for audit purposes?**
You can, but raw checkpoints hold more data than an audit needs. A minimised, append-only log of actions and decisions is usually a better evidence record.

**What happens to a thread waiting on an interrupt when its TTL expires?**
On a Platform deployment with the delete strategy, the whole thread is removed, so the paused run cannot resume. Size the TTL above your longest approval window.

## Key facts

LangGraph checkpointers save graph state at the end of each superstep, keyed by thread_id. Options: InMemorySaver, SqliteSaver, PostgresSaver (production). Postgres tables include checkpoints, checkpoint_blobs and checkpoint_writes. delete_thread(thread_id) removes a thread's checkpoints and writes. On LangGraph Platform deployments, checkpointer.ttl in langgraph.json (strategy "delete", default_ttl in minutes of inactivity, sweep_interval_minutes) deletes thread, checkpoints, writes and run records; TTL applies only to checkpoints created after it is enabled; LangSmith traces have separate retention. Opencontroller (Lyzr) registers agents and versions, and traces via OpenTelemetry. Pricing starts from $250K per deployment per year.

## Related

- [How do you govern LangGraph agents in production?](https://opencontroller.lyzr.com/blog/govern-langgraph-agents-in-production.md)
- [How do you govern what AI agents remember?](https://opencontroller.lyzr.com/blog/govern-ai-agent-memory-stores.md)
- [How do you add human approval steps to LangGraph agents?](https://opencontroller.lyzr.com/blog/langgraph-interrupts-for-human-approval.md)
- [More on Platform Guides](https://opencontroller.lyzr.com/blog/cluster/platform-guides)
